POV-Ray : Newsgroups : povray.animations : java spewing pov-source Server Time
23 Apr 2024 15:16:42 EDT (-0400)
  java spewing pov-source (Message 1 to 2 of 2)  
From: Dick Balaska
Subject: java spewing pov-source
Date: 10 Dec 2002 11:59:17
Message: <3DF61D9C.4407AAD7@buckosoft.com>
This is in the "I feel like sharing what i'm up to" category.

[ I have this renderfarm controller i use to manage my 7 boxen (9 cpus)
There is a project file on the client which declares all the files 
that must be transferred to each server.  After insuring the files
are up-to-date, the server spawns povdos (or povunix) to render frames.
The whole thing is http based. ]

---
So in one of my scenes i have this little volcano that spews spheres.
For a year or so, each sphere moved along his own parabola happily
ignoring The World around it.

I decided it was time to add some physics.
1620 spheres.  Calculate position and velocity, suddenly, it's 10 minutes
to parse the volcano.  Bounce off the floor... 15 minutes (in the later frames).
So i parse it once and write a big #switch (frame) file with the positions.
Back to 2 seconds to parse (whew).

Add bounce off each other... i killed it after 40 hours of parsing, (30% done)
thinking even if i parse it once and write the file, i'll never want to change
it.

So i wrote the physics in java[1] and output my Big Switch pov source from that.

Bummer, The size of the parsed file: 150MB.  This is a pain in the
patuti to slough between my machines.

So i thought, how about if my render-server recognized this as a needed file:
http://sean.buckosoft.com:8088/Volcano/servlet/VolcanoServlet?2320
and fetched just the little piece it actually needs?
(Actually, the server knows VolcanoServlet?%f and %f gets replaced
by the current frame number).

This command fetches the initial values for the spheres.
http://sean.buckosoft.com:8088/Volcano/servlet/VolcanoServlet?global

and then in my POV-Ray source, i have
------------------------------------------------------
  // Include the generated volcano file
  #if (VolcanoUseFile)                
    #include "VolcanoGen/_volcano.inc"
    #if (VolcanoDevel)
      #include "VolcanoGen/_volc0.inc"
    #else
      #declare vinc = concat("VolcanoGen/_volc", str(_frame,0,0), ".inc")
      #include vinc
    #end
  #end
------------------------------------------------------

The java jar file has a main, so i can still output the monster 150MB file
for developing the rest of my scene (and debugging the spheres).
That is the _volc0.inc noted.

The MPGs are 62MB (VCD) and 207MB (DVD) so far, so they are too big to share
until i find a place faster than my 64Kb line. [2]

I still have an issue with: the rest of my world is calculated in POV-Ray,
like the position of the train the camera is riding.  I am going to have to
either recreate, or somehow transfer, the train's position to the java so that
the spheres bounce off the train.

dik

--
[1] I rather would write math in C++, but i need to practice my java.
    Math in java, sucks.

[2] You can see the individual frames:
    http://frank.buckosoft.com:2270/_frd?project=tteo-dev&Frame=2906
    or better yet
    http://frank.buckosoft.com:2270/
    click "Status"
    click "Framelist" next to tteo-dev (352x240) or tteo-dvd (720x480)
    click on frame 2906 (any frame > 2311)


Post a reply to this message

From: Fidel viegas
Subject: Re: java spewing pov-source
Date: 10 Dec 2002 23:33:50
Message: <BA1C6F52.7F6A%fidel.viegas@artrecognition.co.uk>
in article 3DF61D9C.4407AAD7@buckosoft.com, Dick Balaska at
dik### [at] buckosoftcom wrote on 10/12/02 5:00 pm:


> [1] I rather would write math in C++, but i need to practice my java.
> Math in java, sucks.

Are you referring to lack of operator overloading in Java? I think there is
an extension of the language that supports that.

All the best

Fidel.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.