» Back To Index
The <skybox> node
Function
The skybox node allows to create a skybox. A skybox is a cube made up of 6 images (textures) of which
the 6 internal faces are displayed behind all the other objects of the 3d scene, thus giving the illusion
of a realistic 3d environment. The center of the skybox is aligned on the position of the camera making
it impossible to reach the edges of the skybox.
General syntax
<skybox
name=""
render="TRUE" >
<xneg_face
filename=""
uv_map_op="NO_SWAP" />
<xpos_face
filename=""
uv_map_op="NO_SWAP" />
<yneg_face
filename=""
uv_map_op="NO_SWAP" />
<ypos_face
filename=""
uv_map_op="NO_SWAP" />
<zneg_face
filename=""
uv_map_op="NO_SWAP" />
<zpos_face
filename=""
uv_map_op="NO_SWAP" />
</skybox>
skybox element
skybox is the xml tag that defines a skybox node.
Attributes:
- name - [STR127] - name of the node. This name will make it possible to refer this node throughout
the XML script.
- render - [BOOLEAN] - displays (TRUE) or hides (FALSE) the skybox - default value: TRUE
- group - [STR127] - name of the group in which to add the current node. A group makes it possible to control
the behavior of several objects in a single way.
xpos_face element
xpos_face specifies the texture (image) located on the right (along the x axis in the positive direction).
This tag has only xml attributes.
Attributes:
- filename - [STR255] - location of the texture file of the cubemap face. The path is relating to the xml script.
- uv_map_op - [ENUM] - specifies the operation to be performed on the texture coordinates in order to correct the texture direction:
- NO_SWAP: operation without effect: leave the textures coordinates unchanged - default value
- SWAP_U: inverts the U coordinates: texture is reversed in relation to the axis of the Y.
- SWAP_V: inverts the V coordinates: texture is reversed in relation to the x axis.
- SWAP_UV: inverts the U and V coordinates: texture is reversed in relation to the Y and X axis.
xneg_face element
xneg_face specifies the texture (image) located on the left (along the x axis in the negative direction).
This tag has only xml attributes:
Attributes:
- filename - [STR255] - location of the texture file of the cubemap face. The path is relating to the xml script.
- uv_map_op - [ENUM] - specifies the operation to be performed on the texture coordinates in order to correct the texture direction:
- NO_SWAP: operation without effect: leave the textures coordinates unchanged - default value
- SWAP_U: inverts the U coordinates: texture is reversed in relation to the axis of the Y.
- SWAP_V: inverts the V coordinates: texture is reversed in relation to the x axis.
- SWAP_UV: inverts the U and V coordinates: texture is reversed in relation to the Y and X axis.
ypos_face element
ypos_face specifies the texture (image) located in top (along the y axis in the positive direction).
This tag has only xml attributes:
Attributes:
- filename - [STR255] - location of the texture file of the cubemap face. The path is relating to the xml script.
- uv_map_op - [ENUM] - specifies the operation to be performed on the texture coordinates in order to correct the texture direction:
- NO_SWAP: operation without effect: leave the textures coordinates unchanged - default value
- SWAP_U: inverts the U coordinates: texture is reversed in relation to the axis of the Y.
- SWAP_V: inverts the V coordinates: texture is reversed in relation to the x axis.
- SWAP_UV: inverts the U and V coordinates: texture is reversed in relation to the Y and X axis.
yneg_face element
yneg_face specifies the texture (image) located in bottom (along the y axis in the negative direction).
This tag has only xml attributes:
Attributes:
- filename - [STR255] - location of the texture file of the cubemap face. The path is relating to the xml script.
- uv_map_op - [ENUM] - specifies the operation to be performed on the texture coordinates in order to correct the texture direction:
- NO_SWAP: operation without effect: leave the textures coordinates unchanged - default value
- SWAP_U: inverts the U coordinates: texture is reversed in relation to the axis of the Y.
- SWAP_V: inverts the V coordinates: texture is reversed in relation to the x axis.
- SWAP_UV: inverts the U and V coordinates: texture is reversed in relation to the Y and X axis.
zpos_face element
zpos_face specifies the texture (image) located behind the camera (face) - along the axis of Z in positive direction. This tag has only xml attributes:
Attributes:
- filename - [STR255] - location of the texture file of the cubemap face. The path is relating to the xml script.
- uv_map_op - [ENUM] - specifies the operation to be performed on the texture coordinates in order to correct the texture direction:
- NO_SWAP: operation without effect: leave the textures coordinates unchanged - default value
- SWAP_U: inverts the U coordinates: texture is reversed in relation to the axis of the Y.
- SWAP_V: inverts the V coordinates: texture is reversed in relation to the x axis.
- SWAP_UV: inverts the U and V coordinates: texture is reversed in relation to the Y and X axis.
zneg_face element
zneg_face specifies the texture (image) located in front of the camera (back) - along the axis of Z in the negative direction. This tag has only xml attributes:
Attributes:
- filename - [STR255] - location of the texture file of the cubemap face. The path is relating to the xml script.
- uv_map_op - [ENUM] - specifies the operation to be performed on the texture coordinates in order to correct the texture direction:
- NO_SWAP: operation without effect: leave the textures coordinates unchanged - default value
- SWAP_U: inverts the U coordinates: texture is reversed in relation to the axis of the Y.
- SWAP_V: inverts the V coordinates: texture is reversed in relation to the x axis.
- SWAP_UV: inverts the U and V coordinates: texture is reversed in relation to the Y and X axis.