RKP - Procedural Primitive Parameters
These are the primitive parameters that can be configured. If you do not include them, they will be reset to their default values.
Globals
-rfrk_renderType (integer, 0 as points, 1 as sprites and 2 as spheres)
-rfrk_percentTotalParticles (float: 100.0)
-rfrk_percentTotalParticles (float: 100.0)
Size
-rfrk_size (float: 0.1)
-rfrk_percentRandomSize (float: 100.0)
-rfrk_scaledByMagnitude (boolean: 0)
-rfrk_magnitude (integer: 0); 0 Velocity, 1 Normal, 2 Force, 3 Texture s, 4 Texture t, 5 Neighbors, 6 Age, 7 Isolation, 8 Viscosity, 9 Density, 10 Pressure, 11 Mass, 12 Temperature, 13 Vorticity
-rfrk_magControlPoint (float)
-rfrk_magControlValue (float)
-rfrk_magControlType (integer: 0); 0 Linear, 1 Smooth, 2 Spline
-rfrk_magMinValue (float)
-rfrk_magMaxValue (float)
-rfrk_scaledByCameraDistance (boolean: 0)
-rfrk_camControlPoint (float)
-rfrk_camControlValue (float)
-rfrk_camControlType (integer: 0); 0 Linear, 1 Smooth, 2 Spline
-rfrk_camMinDistance (float: 0.0)
-rfrk_camMaxDistance (float: 1000.0)
Sequences
-rfrk_fileSeq (string) between “ “
-rfrk_radius (float: 0.08) from 0
-rfrk_core (float: 0.0) from 0 to 1
-rfrk_splash (float: 0.0) from 0 to 1
-rfrk_velocity (float: 1000) from 0
-rfrk_wait (boolean: 0) -rfrk_axis
Camera
-rfrk_cameraPosition (float[3]: 0.0 0.0 -1.0 )
-rfrk_cameraTarget (float[3]: 0.0 0.0 0.0 ) this is the camera's target, not a direction
-rfrk_cameraUp (float[3]: 0.0 1.0 0.0)
-rfrk_nearPlane (float: 0.0)
-rfrk_farPlane (float: 1000.0)
-rfrk_fov (float: 35.0)
-rfrk_fovRatio (float: 1.3333)
-rfrk_fps (float: 25)
-rfrk_frame (integer)
-rfrk_motionBlur ()
-rfrk_motionBlurType (integer:2); 1 motion blur in seconds, 2 motion blur in frames
-rfrk_shutterOpen (float)
-rfrk_shutterClose (float)
-rfrk_shutterAngle (float)
MultiPoints
-rfrk_isMultiPoint (boolean: 0)
-rfrk_mpDensity (integer: 0)
-rfrk_mpDispersion (float: 0)
-rfrk_mpDeformation (float: 0)
-rfrk_mpSeed (integer: 1234)
Clipping
-rfrk_cameraClip (boolean: 0)
Magnitudes
“0” or “1” are used to determine which magnitudes you want to export. To activate motion blur it is necessary to export velocity.
-rfrk_magAge (boolean: 0)
-rfrk_magDensity (boolean: 0)
-rfrk_magForce (boolean: 0)
-rfrk_magIdentity (boolean: 0)
-rfrk_magIsolation (boolean: 0)
-rfrk_magMass (boolean: 0)
-rfrk_magNeighbors (boolean: 0)
-rfrk_magPressure (boolean: 0)
-rfrk_magTemperature (boolean: 0)
-rfrk_magVelocity (boolean: 0) 1 is recommended
-rfrk_magViscosity (boolean: 0)
-rfrk_magVorticity (boolean :0)
RFRK_Particler – Examples
RIB Call
Procedural “RunProgram“ [“rfrk2_runprogram“ “rfrk2_particler -rfrk_fileSeq \“/home/ user/scenes/test/particles/Circle0100049.bin\“ -rfrk_wait 0 -rfrk_size 0.05 -rfrk_ percentRandomSize 0 -rfrk_scaledByMagnitude 0 -rfrk_magnitude 6 -rfrk_magControlPoint 0 -rfrk_magControlValue 0 -rfrk_magControlType 1 -rfrk_magControlPoint 0.995049 -rfrk_ magControlValue 0 -rfrk_magControlType 1 -rfrk_magMinValue 0 -rfrk_magMaxValue 1 -rfrk_scaledByCameraDistance 0 -rfrk_camControlPoint 0 -rfrk_camControlValue 0 -rfrk_ camControlType 1 -rfrk_camControlPoint 1 -rfrk_camControlValue 0 -rfrk_camControlType 1 -rfrk_camMinDistance 0 -rfrk_camMaxDistance 1 -rfrk_renderType 0 -rfrk_core 0 -rfrk_ splash 0 -rfrk_maxVel 1000 -rfrk_percentTotalParticles 1 -rfrk_axis 2 -rfrk_isMultiPoint 1 -rfrk_mpDensity 50 -rfrk_mpDispersion 0.25 -rfrk_mpDeformation 0.4 -rfrk_mpSeed 12341 -rfrk_cameraClip 0 -rfrk_magAge 0 -rfrk_magDensity 0 -rfrk_magForce 0 -rfrk_magMass 0 -rfrk_magVelocity 1 -rfrk_magViscosity 0 -rfrk_magVorticity 0 -rfrk_magNeighbors 0 -rfrk_ magIsolation 0 -rfrk_magTemperature 0 -rfrk_magPressure 0 -rfrk_fps 25 -rfrk_nearPlane 0.1 -rfrk_farPlane 1000 -rfrk_fov 54.43213037 -rfrk_fovRatio 1.5 -rfrk_cameraPosition 8.034309451 8.245098912 6.961129989 -rfrk_cameraTarget -0.09360077762 1.723860411 -1.054078181 -rfrk_cameraUp -0.3531934021 0.868299669 -0.3482960026 -rfrk_shutterOpen 0 -rfrk_shutterClose 1 -rfrk_motionBlur 0 -rfrk_motionBlurType 2 -rfrk_ shutterAngle 80 -rfrk_frame 49“] [-100000 100000 -100000 100000 -100000 100000]
Reading Primitive Variables Inside A RenderMan Shader
• Points: the same as the RFRK mesher
• For “Sprites” and “Spheres” it's necessary to use uniform variables.
surface age( uniform float age = 0.0; )
{
//Here the age primitive variable (attached to the procedural primitive) can be read and used for shading.
}