3D_TRANSPARENT

3D_TRANSPARENT N,T

SET THE TRANSPARENCY OF THE 3D OBJECT NUMBER N

  • Type: Command
  • Parameters: 2
  • Group: 3D Objects

ACTION

The command 3D_TRANSPARENT N,T changes the transparency of the 3D object designated by its number. The value goes from 0 to 255, 0 for an opaque object and 255 for a transparent object.

Remark: a 3D object is opaque when created.

SYNTAX: 3D_TRANSPARENT N,T

  • N = 3D object number (integer or real). Must be greater than 0 and less than or equal to the allowed maximum number of 3D objects.
  • T = transparence value (integer or real) from 0 to 255.

USE

  • The command 3D_TRANSPARENT is used to make a 3D object more or less transparent.

ERROR

  • If number N is not a correct expression.
  • If number N exceeds the allowed maximum number of 3D objects.
  • If number N is not greater than 0.
  • If 3D object number N does not exist.
  • If T is not a correct expression.
  • If T is less than 0 or greater than 255.

EXAMPLE

rem create a 3D world

scene3d 1

rem create a cube (3D object number 1) with side length of 1.5

3d_cube 1,1.5

rem wait for 1 second

wait 1000

rem make it half-transparent

3d_transparent 1,128

SEE ALSO

-