Macro conversion API

Defines

#define MTOI(val)   ((val)>>1)
 Convert scol machine value to int.
#define MTOP(val)   ((val)>>1)
 Convert scol machine value to system handle.
#define ITOM(val)   ((val)<<1)
 Convert int to scol machine value.
#define PTOM(val)   (((val)<<1)+1)
 Convert system handle to scol machine value.
#define INVERT(m, a, b)   {tmp_res=MMget(m,a);MMset(m,a,MMget(m,b));MMset(m,b,tmp_res);}
 Invert 2 stack positions in scol machine
need a int tmp_res local variable to work.
#define SEDROP(m, n)   ((m)->pp += (n))
 Move the scol machine stack of n positions.

Functions

_inline float MTOF (int val)
 Convert scol machine value to float.
_inline int FTOM (float val)
 Convert float to scol machine value.

Detailed Description

User Scol machine Macro conversion API


Define Documentation

#define INVERT ( m,
a,
 )     {tmp_res=MMget(m,a);MMset(m,a,MMget(m,b));MMset(m,b,tmp_res);}

Invert 2 stack positions in scol machine
need a int tmp_res local variable to work.

Parameters:
Mmachine : the scol machine structure pointer
int : first position in stack
int : second position in stack
#define ITOM ( val   )     ((val)<<1)

Convert int to scol machine value.

Parameters:
int : system int value
Returns:
int : scol machine value
#define MTOI ( val   )     ((val)>>1)

Convert scol machine value to int.

Parameters:
int : scol machine value
Returns:
int : system int value
#define MTOP ( val   )     ((val)>>1)

Convert scol machine value to system handle.

Parameters:
int : scol machine value
Returns:
int : system handle
#define PTOM ( val   )     (((val)<<1)+1)

Convert system handle to scol machine value.

Parameters:
int : system int value
Returns:
int : scol machine value
#define SEDROP ( m,
 )     ((m)->pp += (n))

Move the scol machine stack of n positions.

Parameters:
Mmachine : the scol machine structure pointer
int : number of pull in stack

Function Documentation

_inline int FTOM ( float  val  ) 

Convert float to scol machine value.

Parameters:
float : system float value
Returns:
int : scol machine value
_inline float MTOF ( int  val  ) 

Convert scol machine value to float.

Parameters:
int : scol machine value
Returns:
float : system float value
 All Data Structures Files Functions Defines

Generated by  doxygen 1.6.2