FDOSTUI
FreeDOS Text User Interface
Classes | Functions | Variables
matrix.h File Reference

Simple transformation matrix (translate only) More...

Go to the source code of this file.

Classes

struct  matrix
 matrix More...
 

Functions

void matrix_cleanup ()
 release resources held by the global matrix object More...
 
void matrix_push ()
 pushes the current transformation matrix onto the stack More...
 
void matrix_pop ()
 restore the current transformation matrix More...
 
void matrix_translate (int const i_translate_x, int const i_translate_y)
 translate the current transformation matrix More...
 
void matrix_transform (int *const o_pos_x, int *const o_pos_y)
 apply the transformation matrix to the parameters More...
 

Variables

struct matrix _matrix
 current transformation matrix
 

Detailed Description

Simple transformation matrix (translate only)

Function Documentation

◆ matrix_cleanup()

void matrix_cleanup ( )

release resources held by the global matrix object

This routine should be called when the application exits to release resources created by the matrix routines.

◆ matrix_pop()

void matrix_pop ( )

restore the current transformation matrix

Returns
none

◆ matrix_push()

void matrix_push ( )

pushes the current transformation matrix onto the stack

Returns
none

◆ matrix_transform()

void matrix_transform ( int *const  o_pos_x,
int *const  o_pos_y 
)

apply the transformation matrix to the parameters

Parameters
[in,out]o_pos_xx position to transform
[in,out]o_pos_yy position to transform
Returns
none

◆ matrix_translate()

void matrix_translate ( int const  i_translate_x,
int const  i_translate_y 
)

translate the current transformation matrix

Parameters
[in]i_translate_xamount to translate in the X direction
[in]i_translate_yamount to translate in the Y direction
Returns
none

This operation is additive.