Blender Git Loki

Git Commits -> Revision 9e3fa15

Revision 9e3fa15 by Lukas Toenne (master)
August 31, 2012, 19:38 (GMT)
Added a bunch of additional particle state attributes to the Cycles particle info node:

* Location: Basically the same as the location from Object Info node for object instances on particles, but in principle there could be additional offsets for dupli objects, so included for completeness.
* Size: Single float scale of the particle. Also directly translates to object scale for current dupli objects, but handy to have as a single float to start with instead of a scale vector (currently not even exposed in Object Info).
* Rotation: This is a quaternion, which are not yet supported by Cycles nodes. The float4 is copied to internal Cycles data and stored in the particles texture data, but the node doesn't have a socket for it yet and the data is not yet written to the stack. Code is just commented out so could be enabled quickly if/when rotation support is added to cycles.
* Velocity: Linear velocity vector of particles.
* Angular Velocity: Angular velocity around principle axes.

The texture data is currently packed tightly into the particles texture, which saves a few bytes, but requires an additional texture lookup for some vector attributes which spread over two float4s. Could also add another float4 to particle size to avoid this.

Commit Details:

Full Hash: 9e3fa15d4b3e22127471a7451a49b594cf6275a0
SVN Revision: 50295
Parent Commit: f0d2477
Lines Changed: +155, -14

10 Modified Paths:

/intern/cycles/blender/blender_particles.cpp (+5, -0) (Diff)
/intern/cycles/blender/blender_util.h (+5, -0) (Diff)
/intern/cycles/kernel/kernel_object.h (+40, -3) (Diff)
/intern/cycles/kernel/kernel_types.h (+1, -1) (Diff)
/intern/cycles/kernel/svm/svm_geometry.h (+30, -8) (Diff)
/intern/cycles/kernel/svm/svm_types.h (+6, -1) (Diff)
/intern/cycles/render/nodes.cpp (+51, -0) (Diff)
/intern/cycles/render/particles.cpp (+5, -1) (Diff)
/intern/cycles/render/particles.h (+5, -0) (Diff)
/source/blender/nodes/shader/nodes/node_shader_particle_info.c (+7, -0) (Diff)
Tehnyt: Miika HämäläinenViimeksi päivitetty: 07.11.2014 14:18MiikaH:n Sivut a.k.a. MiikaHweb | 2003-2021