GEMLIB  0.44.0
Functions
VDI utility functions

some usefull utilities function. This library doesn't contain any VDI call. More...

Functions

void vdi_array2str (const short *src, char *des, short len)
 
short vdi_str2array (const char *src, short *des)
 
short vdi_str2array_n (const char *src, short *des, int nmax)
 
short vdi_wstrlen (const short *wstr)
 

Detailed Description

some usefull utilities function. This library doesn't contain any VDI call.

Function Documentation

void vdi_array2str ( const short *  src,
char *  des,
short  len 
)

transform VDI-string (each character is 16-bit wide, the string is not null-terminated and len is in another parameter) to standard C-string.

Parameters
srcinput str, each char is 16-bit wide. (src[0] is the 1st character, src[1] is the 2nd char, etc...)
desoutput string, each char is 8-bit wide (standard NULL-terminated C-string)
lenis the len of the input string.

Referenced by udef_vqt_fontheader(), udef_vqt_name_and_id(), udef_vrq_string(), udef_vsm_string(), udef_vst_name(), vqp_filmname(), vqt_ext_name(), vqt_fontheader(), vqt_name_and_id(), vrq_string(), vsm_string(), and vst_name().

short vdi_str2array ( const char *  src,
short *  des 
)
Parameters
srcinput string (standard null-terminated C-string)
desoutput string (VDI format, each char occupied 16 bits)
Returns
the len of the string
short vdi_str2array_n ( const char *  src,
short *  des,
int  nmax 
)
short vdi_wstrlen ( const short *  wstr)

return the length of a w-string

Parameters
wstra string with 16 bits per character, null-terminated.
Returns
the length of the string

Referenced by udef_v_ftext_offset16(), v_ftext16(), v_ftext_offset16(), v_gtext16(), vqt_extent16(), and vqt_f_extent16().