Lights Table class, handles loading the light type table default files and keeping track of all the custom light point types that are added when an osgSim light point is replaced with a DtLightPoint.
More...
Public Member Functions |
| | DtLightPointTable () |
| | CTOR.
|
| virtual | ~DtLightPointTable () |
| | Destructor h.
|
| virtual bool | addLight (DtLightPointType *lightPointType, const std::string &codeStr) |
| | add a light type to the table returns true if the light was added or false if it was not added because it is a duplicate if it is a duplicate the hierarchy is added to the hierarchy to type map
|
| virtual DtLightPointType * | getLight (unsigned int code) |
| | return a pointer to the light associated to the light code (could be null)
|
| virtual DtLightPointType * | getLight (const std::string &type) |
| | return a pointer to the light associated to the light type (could be null)
|
| virtual void | loadLightTableFromXML (const std::string &fileName) |
| | Load the Light.xml file This file follows the CDB standard for defining the hierarchy of light point types.
|
| virtual void | saveDefaultLightValuesToCSV (const std::string &filename) |
| | Save the current light type values to a CSV file.
|
| virtual void | loadDefaultLightValuesFromCSV (const std::string &filename) |
| | Load light type values from a CSV file loads a CSV file which contains the same parameters defined in the Default Values xml file.
|
| virtual void | loadDefaultLightValuesFromXML (const std::string &fileName) |
| | Load default values for light type from the Light_DefaultValuesXX.xml follows the CDB standard for the light point values file.
|
| virtual void | loadTunningLightValuesFromXML (const std::string &fileName) |
| | Load tunning values for light type from the Lights_xxx.xml follows the CDB standard for tunning light point tables.
|
| virtual bool | isDirty () |
| | dirty flag to know if the table has changed since the last time clean has been called
|
| virtual void | clean () |
| | reset the dirty flag
|
| virtual int | maxCode () |
| | get the highest light type value
|
| virtual void | updateLightPointTypeMap () |
| | Create entries in the light point type map for all the light point types that have been added.
|
| int | getOrCreateLightTypeCode (const DtLightPointType &lp) |
| | See if there is a type code for this light point type and assign it one if there is not one yet.
|
Lights Table class, handles loading the light type table default files and keeping track of all the custom light point types that are added when an osgSim light point is replaced with a DtLightPoint.
It can load both xml and csv files for the main light point type table.
| virtual void makVrv::DtLightPointTable::saveDefaultLightValuesToCSV |
( |
const std::string & |
filename | ) |
|
|
virtual |
Save the current light type values to a CSV file.
saves a CSV file which contains the same parameters defined in the Default Values xml file. Format is: Code, Intensity, Red, Green, Blue, Directionality, Horizontal Lobe, Vertical Lobe, Residual Intensity, Frequency, Duty Cycle, Min Pixel Size, Max Pixel Size, Max Visible Distance one light point type per line and all values are separated by commas.
| virtual void makVrv::DtLightPointTable::loadDefaultLightValuesFromCSV |
( |
const std::string & |
filename | ) |
|
|
virtual |
Load light type values from a CSV file loads a CSV file which contains the same parameters defined in the Default Values xml file.
Format is: Code, Intensity, Red, Green, Blue, Directionality, Horizontal Lobe, Vertical Lobe, Residual Intensity, Frequency, Duty Cycle, Min Pixel Size, Max Pixel Size, Max Visible Distance one light point type per line and all values are separated by commas.