Public Member Functions | |
| bool | Init (IND_Render *pRender) |
| void | End () |
| bool | Add (IND_Light *pNewLight, IND_LightType pLightType) |
| bool | Delete (IND_Light *pLight) |
| bool | Enable (IND_Light *pLight) |
| bool | Disable (IND_Light *pLight) |
| void | Update () |
See all the methods of IND_Light in order to check which attributes you can change in each light. The maximun number of allowed enabled lights at the same time is 8, but can can create as many as you want and disable / enable them.
There are several types of lights, see IND_LightType for more details.
| bool IND_LightManager::Init | ( | IND_Render * | pRender | ) |
parameters:
This function returns 1 (true) if the adminstrator is successfully initialized. Must be called before using any method.
| void IND_LightManager::End | ( | ) |
Operation:
This function frees the manager and all the objects that it contains.
| bool IND_LightManager::Add | ( | IND_Light * | pNewLight, | |
| IND_LightType | pLightType | |||
| ) |
Parameters:
This function returns 1 (true) if the light object passed as a parameter exists and is added successfully to the manager. See IND_LightType to see the different type of lights you can use.
Using this method, IndieLib will try to enable the light automatically. You can only have 8 ligths enabled at the same time (not including ambient light), but you can add to the manager as many as you want.
If you add a light to the manager and there are already 8 lights enabled, it will be automatically disabled. You can disable other lights in the scene and then you will be able to enable this light.
Use the IND_Light methods in order to change the attributes of the light.
| bool IND_LightManager::Delete | ( | IND_Light * | pLight | ) |
Parameters:
This function returns 1(true) if the light object passed as parameter exists and it is deleted from the manager successfully.
| bool IND_LightManager::Enable | ( | IND_Light * | pLight | ) |
Parameters:
This function returns 1 (true) if the light object passed as a parameter exists and the light is enable.
You can only have 8 ligths enabled at the same time (not including ambient light). This method will return 0 if there are already 8 lights enabled.
Use the IND_LightManager::GetNumLightsEnabled() method in order to know how many lights are enable.
| bool IND_LightManager::Disable | ( | IND_Light * | pLight | ) |
Parameters:
This function returns 1 (true) if the light object passed as a parameter exists and the light is disabled.
Use the IND_LightManager::GetNumLightsEnabled() method in order to know how many lights are enable.
| void IND_LightManager::Update | ( | ) |
Parameters:
Operation:
This method must be called always before the IND_Entity3dManager::RenderEntities3d() method. It will update all the lights attributes.
1.5.4