POV-Ray : Newsgroups : povray.general : Ingenious snow placement? : Re: Ingenious snow placement? Server Time
2 Aug 2024 08:14:11 EDT (-0400)
  Re: Ingenious snow placement?  
From: Gena
Date: 8 Dec 2004 02:21:27
Message: <41b6ab77$1@news.povray.org>
Couple months ago I had the same task. I wanted to place
snow either on blob trees generated by TOMTREE or on mesh
trees generated by POV-Tree. I tried many solutions and came
up with a custom POV-Tree program which generates two blobs:
tree model and snow which has the same geometry as a tree but
each blob was vertically shifted. The value of each shift equals
to blob radius but it's customizable. It works fine. Maybe snow
looks too smooth. Probably I will work a little bit more on it and 
release that POV-Tree version in the future. Though don't ask
me when :)

Gena.


Tim Nikias wrote:
> So, what I have: two meshes of the same tree. One is with all the tiny
> branches, the other with just the big ones. What I want to do is place
> spheres for a blob onto the less intricate tree, and then use it in
> conjunction with the detailed tree. Thus, I get snow on the bigger branches
> for the detailed tree.
> 
> Now, does anyone have any ingenious SDL-Code which would place the spheres
> on the tree via trace()? I could go about, generate a field with millions of
> particles and then just drop them, those that stick will stay, the rest will
> get deleted, but I'd rather use a more sophisticated approach, which should
> be faster. My initial idea was to generate a top-down image of the tree,
> white=tree and black=empty space, and before actually shooting trace(), I
> check this image if there's any tree beneath it. With an even distribution I
> could thus quickly generate all the spots on the tree, but I'd have to
> generate thousands of starting points of which again thousands will get
> discarded once I test them against the image.
> 
> Anyone have any ideas or suggestions? I don't mind scripting the thing
> myself, I just need a good algorithm which will work faster than
> brute-force.
> 
> Regards,
> Tim
>


Post a reply to this message

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