dl
Public 类型 | Public 成员函数 | 所有成员列表
dl::System类 参考

#include <dl_system.h>

Public 类型

enum class  CursorMode { NORMAL , HIDE , DISABLE }
 
using Func = void(*)(void)
 

Public 成员函数

 System ()
 
 ~System ()
 
void Start (std::string_view json_window, std::string_view json_path="")
 进入 游戏循环 更多...
 
void Start (const ParamWindow &param={})
 创建窗口 并进入 游戏循环 更多...
 
void SetFuncInit (Func func)
 设置 初始化函数 更多...
 
void SetFuncRun (Func func)
 设置 帧函数 更多...
 
void SetCursorPosition (Point xy)
 设置鼠标位置,不用此来实现摄像机 更多...
 
Size GetWindowSize ()
 返回窗口大小 更多...
 
Size GetWorkArea ()
 获取桌面大小,不包含任务栏 更多...
 
void SetWindowPoint (const Point &xy)
 设置窗口位置 更多...
 
void SetWindowCenter ()
 设置窗口居中(以工作区大小) 更多...
 
const RenderInfo2D & GetRenderInfo2D ()
 返回上一帧绘图信息 更多...
 
const RenderInfo3D & GetRenderInfo3D ()
 
void ScreenShot (std::string_view path_name)
 截屏 更多...
 
void SetCursorMode (CursorMode mode)
 设置光标模式 更多...
 
SystemImp * GetImp ()
 

详细描述

在文件 dl_system.h 第 34 行定义.

成员类型定义说明

◆ Func

using dl::System::Func = void (*)(void)

在文件 dl_system.h 第 37 行定义.

成员枚举类型说明

◆ CursorMode

enum class dl::System::CursorMode
strong
枚举值
NORMAL 
HIDE 
DISABLE 

在文件 dl_system.h 第 96 行定义.

构造及析构函数说明

◆ System()

dl::System::System ( )

◆ ~System()

dl::System::~System ( )

成员函数说明

◆ GetImp()

SystemImp * dl::System::GetImp ( )
inline

在文件 dl_system.h 第 108 行定义.

◆ GetRenderInfo2D()

const RenderInfo2D & dl::System::GetRenderInfo2D ( )

返回上一帧绘图信息

◆ GetRenderInfo3D()

const RenderInfo3D & dl::System::GetRenderInfo3D ( )

◆ GetWindowSize()

Size dl::System::GetWindowSize ( )

返回窗口大小

◆ GetWorkArea()

Size dl::System::GetWorkArea ( )

获取桌面大小,不包含任务栏

◆ ScreenShot()

void dl::System::ScreenShot ( std::string_view  path_name)

截屏

◆ SetCursorMode()

void dl::System::SetCursorMode ( CursorMode  mode)

设置光标模式

注解
调用后,会触发光标移动事件,会强制鼠标两帧间隔归0s

◆ SetCursorPosition()

void dl::System::SetCursorPosition ( Point  xy)

设置鼠标位置,不用此来实现摄像机

参数
[in]xy位置
注解
使用g_input获得鼠标位置

◆ SetFuncInit()

void dl::System::SetFuncInit ( Func  func)
inline

设置 初始化函数

在文件 dl_system.h 第 56 行定义.

◆ SetFuncRun()

void dl::System::SetFuncRun ( Func  func)
inline

设置 帧函数

在文件 dl_system.h 第 60 行定义.

◆ SetWindowCenter()

void dl::System::SetWindowCenter ( )

设置窗口居中(以工作区大小)

◆ SetWindowPoint()

void dl::System::SetWindowPoint ( const Point &  xy)

设置窗口位置

◆ Start() [1/2]

void dl::System::Start ( const ParamWindow &  param = {})

创建窗口 并进入 游戏循环

◆ Start() [2/2]

void dl::System::Start ( std::string_view  json_window,
std::string_view  json_path = "" 
)

进入 游戏循环

参数
[in]json_window窗口配置
[in]json_path资源路径配置

该类的文档由以下文件生成: