d3d_transform_stack_push

Pushes the current transformation onto the stack.

Syntax:

d3d_transform_stack_push()


Returns: Boolean


Description

Pushes the current transformation onto the stack, and returns whether there was room on the stack (true) to push it there or not (false).

Note: If you forget to "pop" transformations you will at some moment run out of room on the stack.


Example:

d3d_transform_stack_pop();
d3d_transform_add_rotation_axis(1, 0, 0, 5);
d3d_transform_stack_push();
d3d_transform_set_identity();

The above code will pop the previous transformation from the stack, then add a rotation over the x axis, before finally pushing the final transform back onto the stack again.


Back: 3D Drawing
Next: d3d_transform_stack_pop
© Copyright YoYo Games Ltd. 2018 All Rights Reserved