SKYENGINE API  参考手册返回目录  

 
int32 mr_platEx

(int32 code = 1309,
uint8* input,
int32 input_len,
uint8** output,
int32* output_len,
MR_PLAT_EX_CB* cb
)



Description
创建层。
Parameters

Name Description
input T_LAYER_CREATE数据结构指针
input_len T_LAYER_CREATE数据结构大小
output T_DSM_COMMON_RSP数据结构指针
output_len T_DSM_COMMON_RSP 数据结构大小
cb

Return Value

MR_SUCCESS                   成功
MR_FAILED                      失败
MR_IGNORE                     不支持该功能

Remarks

T_LAYER_CREATE数据结构:
typedef struct
{
    int32 x;
    int32 y;
    int32 w;
    int32 h;
    int32 size;
    char *buffer;
}T_LAYER_CREATE;

T_DSM_COMMON_RSP数据结构:
typedef struct
{
    int32 p1;          //层句柄 0是非法句柄
}T_DSM_COMMON_RSP;

Example

/*mrp code*/


T_LAYER_CREATE lCre;
int wBmp, hBmp;
int32 re, len;
T_DSM_COMMON_RSP *lhnd = NULL;

lCre.buffer = (char*)SGL_LoadBitmap( BMP_PLANE, &wBmp, &hBmp );
lCre.size = wBmp*hBmp*2;
lCre.w = wBmp;
lCre.h = hBmp;
lCre.x = 20;
lCre.y = 100;
re = mrc_platEx( 1309, (uint8*)&lCre, sizeof(T_LAYER_CREATE), (uint8**)&lhnd, (int32*)&len, NULL );
if (MR_SUCCESS== re)
{
     mrc_printf( "created layer handle:%d", lhnd->p1  );
}

See Also

 


Copyright ?2005-20010 SKY-MOBI

返回目录