Dandelion 2.0.0
A light-weight 3D builder for educational usage
载入中...
搜索中...
未找到
menubar.h
浏览该文件的文档.
1#ifndef DANDELION_UI_MENUBAR_H
2#define DANDELION_UI_MENUBAR_H
3
4#include <functional>
5
6#include "../scene/scene.h"
8
9/*!
10 * \file ui/menubar.h
11 * \ingroup ui
12 */
13
14namespace UI {
15
16/*!
17 * \ingroup ui
18 * \~chinese
19 * \brief 菜单栏提供加载文件操作、调整日志级别等调试选项和一些帮助页面。
20 */
22{
23public:
24
25 /*! \~chinese 菜单栏持有对调试选项的引用,构造时需要传递。 */
27 ~Menubar();
28 /*! \~chinese 显示菜单栏。 */
29 void render(Scene& scene);
30 /*! \~chinese 当前菜单栏高度。 */
31 float height() const;
32 std::function<void()> reset_ui;
33
34private:
35
36 /*! \~chinese 调整全局日志输出级别的菜单。 */
38 /*! \~chinese 显示 GUI 操作帮助的弹出窗口。 */
39 void usage();
40 /*! \~chinese 显示开发者信息的弹出窗口。 */
41 void about();
42 /*! \~chinese 控制调试选项的面板。 */
44 /*! \~chinese 当前菜单栏高度,每一帧调用 `render` 时更新。 */
46 /*! \~chinese 对调试选项的引用。 */
48 /*! \~chinese 用于在开发者信息页面显示 Logo 的 OpenGL 纹理描述符。 */
49 unsigned int gl_icon_texture;
50};
51
52} // namespace UI
53
54#endif // DANDELION_UI_MENUBAR_H
表示一个包含相机、光源、物体等对象的完整场景。
定义 scene.h:57
float height() const
定义 menubar.cpp:147
Menubar(DebugOptions &debug_options)
定义 menubar.cpp:30
float menubar_height
定义 menubar.h:45
void logging_levels_menu()
定义 menubar.cpp:152
void render(Scene &scene)
定义 menubar.cpp:50
void about()
定义 menubar.cpp:191
void usage()
定义 menubar.cpp:175
void debug_options_panel()
定义 menubar.cpp:208
DebugOptions & debug_options
定义 menubar.h:47
unsigned int gl_icon_texture
定义 menubar.h:49
这个文件定义了一些和渲染(离线渲染或场景预览)相关的常量、枚举等。
包含场景的类。
辅助调试的 GUI 选项。
定义 rendering.hpp:94