Appgamekit常用指令1(c++版)

邮差的信 提交于 2020-02-27 20:14:10

1.void agk::Sync();
刷新屏幕。
2.int agk::GetDeviceHeight();
返回设备屏幕的高度。
3.int agk::GetDeviceWidth();
返回设备屏幕的宽度。
4.float ScreenFPS();
返回fps,即每秒平均帧数。
5.void agk::SetSyncRate( float fps, int mode=0 );
设置刷新模式。
参数:fps用来设置最大的每秒帧数。mode中0节省cpu电池,1的性能更好,消耗cpu较大。
6.void agk::SetWindowTitle( const char* szTitle );
设置窗口标题。
7.char* agk::Str( float value );
char* agk::Str( float value, UINT decimals );
char* agk::Str( int value )

三个重载函数。
将浮点型数据转换为字符串。
将浮点型数据转换为指定小数点位数的字符串。
将整型数据转换为字符串。
参数:decimals代表小数点后的位数
8.void agk::SetVirtualResolution( int iWidth, int iHeight );
设置虚拟分辨率为iWidth*iHeight
9.void agk::SetClearColor( UINT red, UINT green, UINT blue );
设置屏幕填充颜色,使用RGB颜色通道
10.char* agk::GetDeviceName();
返回设备名称

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!