![]() |
![]() |
![]() |
V_Sim API - Reference Manual | ![]() |
---|---|---|---|---|
Top | Description |
#define RESOURCES_CYLINDER_RADIUS_MIN #define RESOURCES_CYLINDER_RADIUS_MAX VisuPairExtension* cylinderGet_static (); VisuPairExtension* initPairsCylinder (); int cylinderSet_generalRadius (float val
); float cylinderGet_generalRadius (); int cylinderSet_radius (VisuPairData *data
,float val
); float cylinderGet_radius (VisuPairData *data
); int cylinderSet_colorType (int val
); int cylinderGet_colorType ();
The cylinders have two characteristics: their radius and their colour. Their radius are in the units of the rendered box. They can be specific to each kind of pairs (e.g. Si-Si) or they have a default value. Only the default value is stored in the resource file with the flag "pairCylinder_radius". Their color is herited by the colour of the pair. The lighting values (i.e. emi., shi., spe. ...) are not movable and are fixed to amb = 0.5, dif = 0.5, shi = 0, spe = 0, emi = 0.
#define RESOURCES_CYLINDER_RADIUS_MIN 0.01f
Minimum value for the radius of cylinder pairs.
#define RESOURCES_CYLINDER_RADIUS_MAX 3.f
Maximum value for the radius of cylinder pairs.
VisuPairExtension* cylinderGet_static ();
Internal use only to get the cylinder extension.
VisuPairExtension* initPairsCylinder ();
This method is used by V_Sim on startup, don't use it on your own.
Returns : |
the cylinder pair extension. |
int cylinderSet_generalRadius (float val
);
This method allows to change the default value of radius for cylinder pairs.
When a pair is rendered via a cylinder, it first checks if that pairs has
a specific radius value. If not, it uses the default value set by this method.
If the default value is indeed changed, the pairs OpenGl list is not
recreated automatically and the calling method should call the visu_pair_build()
method
according to the return value.
|
a float value. |
Returns : |
1 if the calling method should call the visu_pair_build() method, 0 if not.
|
float cylinderGet_generalRadius ();
Get the default value for cylinder radius.
Returns : |
the default value for cylinder radius. |
int cylinderSet_radius (VisuPairData *data
,float val
);
This method allows to change the radius value of a specific pair.
When a pair is rendered via a cylinder, it first checks if that pairs has
a specific radius value set by this method. If not, it uses the default value.
If the specific value is indeed changed, the pairs OpenGl list is not
recreated automatically and the calling method should call the visu_pair_build()
method
according to the return value.
|
a VisuPairData object ; |
|
a float value. |
Returns : |
1 if the calling method should call the visu_pair_build() method, 0 if not.
|
float cylinderGet_radius (VisuPairData *data
);
Get the radius value for the specified pair.
|
a VisuPairData object. |
Returns : |
the radius value. |
int cylinderSet_colorType (int val
);
It set the color scheme for cylinder pairs. It can be 0 or 1.
|
a integer that identify the color scheme. |
Returns : |
1 if the calling method should call visu_pair_build() and then
emit the redrawing signal, 0 if not.
|