Safe Haskell | Safe-Infered |
---|
- new :: String -> IO HG3DClass
- delete :: HG3DClass -> IO ()
- setType :: HG3DClass -> EnumLightType -> IO ()
- getType :: HG3DClass -> IO EnumLightType
- setDiffuseColour :: HG3DClass -> Float -> Float -> Float -> IO ()
- setDiffuseColour2 :: HG3DClass -> Colour -> IO ()
- getDiffuseColour :: HG3DClass -> IO Colour
- setSpecularColour :: HG3DClass -> Float -> Float -> Float -> IO ()
- setSpecularColour2 :: HG3DClass -> Colour -> IO ()
- getSpecularColour :: HG3DClass -> IO Colour
- setAttenuation :: HG3DClass -> Float -> Float -> Float -> Float -> IO ()
- getAttenuationRange :: HG3DClass -> IO Float
- getAttenuationConstant :: HG3DClass -> IO Float
- getAttenuationLinear :: HG3DClass -> IO Float
- getAttenuationQuadric :: HG3DClass -> IO Float
- setPosition :: HG3DClass -> Float -> Float -> Float -> IO ()
- setPosition2 :: HG3DClass -> Vec3 -> IO ()
- getPosition :: HG3DClass -> IO Vec3
- setDirection :: HG3DClass -> Float -> Float -> Float -> IO ()
- setDirection2 :: HG3DClass -> Vec3 -> IO ()
- getDirection :: HG3DClass -> IO Vec3
- setSpotlightRange :: HG3DClass -> Radians -> Radians -> Float -> IO ()
- getSpotlightInnerAngle :: HG3DClass -> IO Radians
- getSpotlightOuterAngle :: HG3DClass -> IO Radians
- getSpotlightFalloff :: HG3DClass -> IO Float
- setSpotlightInnerAngle :: HG3DClass -> Radians -> IO ()
- setSpotlightOuterAngle :: HG3DClass -> Radians -> IO ()
- setSpotlightFalloff :: HG3DClass -> Float -> IO ()
- setPowerScale :: HG3DClass -> Float -> IO ()
- getPowerScale :: HG3DClass -> IO Float
- getMovableType :: HG3DClass -> IO String
- getDerivedPosition :: HG3DClass -> Bool -> IO Vec3
- getDerivedDirection :: HG3DClass -> IO Vec3
- setVisible :: HG3DClass -> Bool -> IO ()
- getBoundingRadius :: HG3DClass -> IO Float
- getTypeFlags :: HG3DClass -> IO Int
- resetCustomShadowCameraSetup :: HG3DClass -> IO ()
- setShadowFarDistance :: HG3DClass -> Float -> IO ()
- resetShadowFarDistance :: HG3DClass -> IO ()
- getShadowFarDistance :: HG3DClass -> IO Float
- getShadowFarDistanceSquared :: HG3DClass -> IO Float
- setShadowNearClipDistance :: HG3DClass -> Float -> IO ()
- getShadowNearClipDistance :: HG3DClass -> IO Float
- setShadowFarClipDistance :: HG3DClass -> Float -> IO ()
- getShadowFarClipDistance :: HG3DClass -> IO Float
- new'_ :: Ptr CChar -> HG3DClassPtr -> IO ()
- delete'_ :: HG3DClassPtr -> IO ()
- setType'_ :: HG3DClassPtr -> CInt -> IO ()
- getType'_ :: HG3DClassPtr -> Ptr CInt -> IO ()
- setDiffuseColour'_ :: HG3DClassPtr -> CFloat -> CFloat -> CFloat -> IO ()
- setDiffuseColour2'_ :: HG3DClassPtr -> ColourPtr -> IO ()
- getDiffuseColour'_ :: HG3DClassPtr -> ColourPtr -> IO ()
- setSpecularColour'_ :: HG3DClassPtr -> CFloat -> CFloat -> CFloat -> IO ()
- setSpecularColour2'_ :: HG3DClassPtr -> ColourPtr -> IO ()
- getSpecularColour'_ :: HG3DClassPtr -> ColourPtr -> IO ()
- setAttenuation'_ :: HG3DClassPtr -> CFloat -> CFloat -> CFloat -> CFloat -> IO ()
- getAttenuationRange'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
- getAttenuationConstant'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
- getAttenuationLinear'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
- getAttenuationQuadric'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
- setPosition'_ :: HG3DClassPtr -> CFloat -> CFloat -> CFloat -> IO ()
- setPosition2'_ :: HG3DClassPtr -> Vec3Ptr -> IO ()
- getPosition'_ :: HG3DClassPtr -> Vec3Ptr -> IO ()
- setDirection'_ :: HG3DClassPtr -> CFloat -> CFloat -> CFloat -> IO ()
- setDirection2'_ :: HG3DClassPtr -> Vec3Ptr -> IO ()
- getDirection'_ :: HG3DClassPtr -> Vec3Ptr -> IO ()
- setSpotlightRange'_ :: HG3DClassPtr -> RadiansPtr -> RadiansPtr -> CFloat -> IO ()
- getSpotlightInnerAngle'_ :: HG3DClassPtr -> RadiansPtr -> IO ()
- getSpotlightOuterAngle'_ :: HG3DClassPtr -> RadiansPtr -> IO ()
- getSpotlightFalloff'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
- setSpotlightInnerAngle'_ :: HG3DClassPtr -> RadiansPtr -> IO ()
- setSpotlightOuterAngle'_ :: HG3DClassPtr -> RadiansPtr -> IO ()
- setSpotlightFalloff'_ :: HG3DClassPtr -> CFloat -> IO ()
- setPowerScale'_ :: HG3DClassPtr -> CFloat -> IO ()
- getPowerScale'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
- getMovableType'_ :: HG3DClassPtr -> Ptr CChar -> IO ()
- getDerivedPosition'_ :: HG3DClassPtr -> CInt -> Vec3Ptr -> IO ()
- getDerivedDirection'_ :: HG3DClassPtr -> Vec3Ptr -> IO ()
- setVisible'_ :: HG3DClassPtr -> CInt -> IO ()
- getBoundingRadius'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
- getTypeFlags'_ :: HG3DClassPtr -> Ptr CUInt -> IO ()
- resetCustomShadowCameraSetup'_ :: HG3DClassPtr -> IO ()
- setShadowFarDistance'_ :: HG3DClassPtr -> CFloat -> IO ()
- resetShadowFarDistance'_ :: HG3DClassPtr -> IO ()
- getShadowFarDistance'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
- getShadowFarDistanceSquared'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
- setShadowNearClipDistance'_ :: HG3DClassPtr -> CFloat -> IO ()
- getShadowNearClipDistance'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
- setShadowFarClipDistance'_ :: HG3DClassPtr -> CFloat -> IO ()
- getShadowFarClipDistance'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
Documentation
Normal constructor. Should not be called directly, but rather the SceneManager::createLight
Sets the type of light - see LightTypes for more info.
Standard destructor.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> EnumLightType | type |
-> IO () |
Returns the light type.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> IO EnumLightType |
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Float | red |
-> Float | green |
-> Float | blue |
-> IO () |
Sets the colour of the diffuse light given off by this source. MaterialDiffuse light simulates the typical light emanating from light sources and affects the base colour of objects together with ambient light.
Sets the colour of the diffuse light given off by this source. MaterialDiffuse light simulates the typical light emanating from light sources and affects the base colour of objects together with ambient light.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Colour | colour |
-> IO () |
Returns the colour of the diffuse light given off by this light source (see setDiffuseColour for more info).
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Float | red |
-> Float | green |
-> Float | blue |
-> IO () |
Sets the colour of the specular light given off by this source. MaterialSpecular light affects the appearance of shiny highlights on objects, and is also dependent on the shininess
Material
Sets the colour of the specular light given off by this source. MaterialSpecular light affects the appearance of shiny highlights on objects, and is also dependent on the shininess
Material
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Colour | colour |
-> IO () |
Returns the colour of specular light given off by this light source.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Float | range - The absolute upper range of the light in world units |
-> Float | constant - The constant factor in the attenuation formula: 1.0 means never attenuate, 0.0 is complete attenuation |
-> Float | linear - The linear factor in the attenuation formula: 1 means attenuate evenly over the distance |
-> Float | quadratic - The quadratic factor in the attenuation formula: adds a curvature to the attenuation formula. |
-> IO () |
Returns the absolute upper range of the light.
Sets the attenuation parameters of the light source i.e. how it diminishes with distance. Lights normally get fainter the further they are away. Also, each light is given a maximum range beyond which it cannot affect any objects. LightThis follows a standard attenuation approach - see any good 3D text for the details of what they mean since i don't have room here!
Returns the constant factor in the attenuation formula.
Returns the linear factor in the attenuation formula.
Returns the quadric factor in the attenuation formula.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Float | x |
-> Float | y |
-> Float | z |
-> IO () |
Sets the position of the light. Applicable to point lights and spotlights only. This will be overridden if the light is attached to a SceneNode
Sets the position of the light. Applicable to point lights and spotlights only. This will be overridden if the light is attached to a SceneNode
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Vec3 | vec |
-> IO () |
Returns the position of the light. Applicable to point lights and spotlights only.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Float | x |
-> Float | y |
-> Float | z |
-> IO () |
Sets the direction in which a light points. Applicable only to the spotlight and directional light types. This will be overridden if the light is attached to a SceneNode
Sets the direction in which a light points. Applicable only to the spotlight and directional light types. This will be overridden if the light is attached to a SceneNode
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Vec3 | vec |
-> IO () |
Returns the light's direction. Applicable only to the spotlight and directional light types.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Radians | innerAngle - Angle covered by the bright inner cone The inner cone applicable only to Direct3D, it'll always treat as zero in OpenGL. |
-> Radians | outerAngle - Angle covered by the outer cone |
-> Float | falloff - The rate of falloff between the inner and outer cones. 1.0 means a linear falloff, less means slower falloff, higher means faster falloff. |
-> IO () |
Returns the angle covered by the spotlights inner cone.
Sets the range of a spotlight, i.e. the angle of the inner and outer cones and the rate of falloff between them.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> IO Radians |
Returns the angle covered by the spotlights outer cone.
Returns the falloff between the inner and outer cones of the spotlight.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Radians | val |
-> IO () |
Sets the angle covered by the spotlights outer cone.
Sets the angle covered by the spotlights inner cone.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Radians | val |
-> IO () |
Sets the falloff between the inner and outer cones of the spotlight.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Float | val |
-> IO () |
Set a scaling factor to indicate the relative power of a light. This factor is only useful in High Dynamic Range (HDR) rendering. You can bind it to a shader variable to take it into account, GpuProgramParameters
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Float | power - The power rating of this light, default is 1.0. |
-> IO () |
Set the scaling factor which indicates the relative power of a light.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> IO String |
Overridden from MovableObject
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Bool | cameraRelativeIfSet - If set to true, returns data in camera-relative units if that's been set up (render use) |
-> IO Vec3 |
Retrieves the position of the light including any transform from nodes it is attached to.
Retrieves the direction of the light including any transform from nodes it is attached to.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Bool | visible |
-> IO () |
Overridden from MovableObject
Overridden from MovableObjectAlthough lights themselves are not visible
, setting a light to invisible means it no longer affects the scene.
Override to return specific type flag.
resetCustomShadowCameraSetupSource
Sets the maximum distance away from the camera that shadows by this light will be visible. Shadow techniques can be expensive, therefore it is a good idea to limit them to being rendered close to the camera if possible, and to skip the expense of rendering shadows for distance objects. This method allows you to set the distance at which shadows will no longer be rendered. Each shadow technique can interpret this subtely differently. For example, one technique may use this to eliminate casters, another might use it to attenuate the shadows themselves. You should tweak this value to suit your chosen shadow technique and scene setup.
Reset the shadow camera setup to the default. ShadowCameraSetup
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Float | distance |
-> IO () |
Tells the light to use the shadow far distance of the SceneManager
Gets the maximum distance away from the camera that shadows by this light will be visible.
setShadowNearClipDistanceSource
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Float | nearClip |
-> IO () |
Get the near clip plane distance to be used by the shadow camera, if this light casts texture shadows. May be zero if the light doesn't have it's own near distance set; use _deriveShadowNearDistance for a version guaranteed to give a result.
Set the near clip plane distance to be used by the shadow camera, if this light casts texture shadows.
setShadowFarClipDistanceSource
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Float | farClip |
-> IO () |
Get the far clip plane distance to be used by the shadow camera, if this light casts texture shadows. May be zero if the light doesn't have it's own far distance set; use _deriveShadowfarDistance for a version guaranteed to give a result.
Set the far clip plane distance to be used by the shadow camera, if this light casts texture shadows. This is different from the 'shadow far distance', which is always measured from the main camera. This distance is the far clip plane of the light camera.
delete'_ :: HG3DClassPtr -> IO ()Source
setDiffuseColour'_ :: HG3DClassPtr -> CFloat -> CFloat -> CFloat -> IO ()Source
setDiffuseColour2'_ :: HG3DClassPtr -> ColourPtr -> IO ()Source
getDiffuseColour'_ :: HG3DClassPtr -> ColourPtr -> IO ()Source
setSpecularColour'_ :: HG3DClassPtr -> CFloat -> CFloat -> CFloat -> IO ()Source
setSpecularColour2'_ :: HG3DClassPtr -> ColourPtr -> IO ()Source
getSpecularColour'_ :: HG3DClassPtr -> ColourPtr -> IO ()Source
setAttenuation'_ :: HG3DClassPtr -> CFloat -> CFloat -> CFloat -> CFloat -> IO ()Source
getAttenuationRange'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()Source
getAttenuationConstant'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()Source
getAttenuationLinear'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()Source
getAttenuationQuadric'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()Source
setPosition'_ :: HG3DClassPtr -> CFloat -> CFloat -> CFloat -> IO ()Source
setPosition2'_ :: HG3DClassPtr -> Vec3Ptr -> IO ()Source
getPosition'_ :: HG3DClassPtr -> Vec3Ptr -> IO ()Source
setDirection'_ :: HG3DClassPtr -> CFloat -> CFloat -> CFloat -> IO ()Source
setDirection2'_ :: HG3DClassPtr -> Vec3Ptr -> IO ()Source
getDirection'_ :: HG3DClassPtr -> Vec3Ptr -> IO ()Source
setSpotlightRange'_ :: HG3DClassPtr -> RadiansPtr -> RadiansPtr -> CFloat -> IO ()Source
getSpotlightFalloff'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()Source
setSpotlightFalloff'_ :: HG3DClassPtr -> CFloat -> IO ()Source
setPowerScale'_ :: HG3DClassPtr -> CFloat -> IO ()Source
getPowerScale'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()Source
getMovableType'_ :: HG3DClassPtr -> Ptr CChar -> IO ()Source
getDerivedPosition'_ :: HG3DClassPtr -> CInt -> Vec3Ptr -> IO ()Source
getDerivedDirection'_ :: HG3DClassPtr -> Vec3Ptr -> IO ()Source
setVisible'_ :: HG3DClassPtr -> CInt -> IO ()Source
getBoundingRadius'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()Source
getTypeFlags'_ :: HG3DClassPtr -> Ptr CUInt -> IO ()Source
setShadowFarDistance'_ :: HG3DClassPtr -> CFloat -> IO ()Source
getShadowFarDistance'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()Source