-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feedback #2
Comments
Yes you can use the particle system we have developed as a starting point. However rather than emitting from a single point you will be emitting from different start positions in an area (rectangle is typically easiest). The update method will do the simulation (which at present is a projectile motion algorithm) so you need to change it. One method you can use is to generate a flow field for the particles to travel through which gives it the snow / flurry motion. There are quite a few other methods like https://history.siggraph.org/wp-content/uploads/2022/12/2004-Talks-Wang_Rendering-Falling-Rain-and-Snow.pdf To add it so maya / houdini you can just export the point positions to a text file and import with a simple python script. You could also write it out as a USD file and import that way (I can show you examples of this is you need it). |
Please try and upload some class designs asap so I can give you some feedback. It would also be good to get an idea of the simulation loop you are going to use. |
start to update your code to replace both the Random and Vec3 classes with the NGL ones as we did in the lab. I still think you need to generate some form of vector / flow field like this for the particles to fall into https://natureofcode.com/autonomous-agents/#flow-fields to get a better simulation. |
I have update my particle system. it now has a black background with white particle falling from the sky. I want to ask where should I implement my snow fall equation and how do I import a snow flake model so that it replaces the particles? also I wanted to try and make the snow pile up at the bottom, is that related to collision detection? how would that work? |
The snow fall elements should happen in the update method, typically this will call many other functions and perhaps classes (i.e. a vector field) to update things. For the snow flake model you can use a texture and use this to render the point (if you use a larger point say 16 - 24) this will take the texture. You will use the gl_PointCoord in the shader to get the UV's and ngl::Texture to load the texture. We will do an example of textures in the lab soon. I will leave this to the end if you can. For the snow pile this will be a little more complex, I would suggest generating a simple height map, where each time the snow hits the ground you increase a value in an array at that collision point. This will be the snow height, you then use this to determine how your snow accumulates (be it by generating new geo or just using some form of shading). The finer the map the more accurate you can make the mesh. |
the is beginning to work well, try and add some more features to it now to get the snow flakes moving for example add some wind and other forces. |
Please upload your ideas asap so I can give you some feedback.
The text was updated successfully, but these errors were encountered: