Utils/CloudView/main.cpp
杰仔 9bcdc61c5a 初始提交:Utils 工具库模块
包含以下子模块:
- VrCommon: 核心接口和数据结构
- VrUtils: 工具类库(JSON、log4cpp、tinyxml2、INI、MD5、CRC)
- CloudUtils: 点云工具
- DataUtils: 数据处理工具(CloudMathClac、CoordinateTransform)
- CloudView: 点云查看工具

功能说明:
- 提供项目通用的基础工具类和实用功能
- 支持 Windows (MSVC/MinGW) 和 Linux (ARM/x86_64) 平台
- 使用 Qt qmake 构建系统
- 所有模块编译为静态库
2026-02-18 16:00:16 +08:00

36 lines
1007 B
C++

#include <QApplication>
#include <QSurfaceFormat>
#include <QIcon>
#include "CloudViewMainWindow.h"
#define APP_VERSION "1.1.0"
int main(int argc, char* argv[])
{
QApplication app(argc, argv);
// 设置 OpenGL 格式 - 使用 2.1 版本以确保固定管线兼容
QSurfaceFormat format;
format.setDepthBufferSize(24);
format.setStencilBufferSize(8);
format.setVersion(2, 1); // 使用 OpenGL 2.1 以确保固定管线函数可用
format.setSamples(4); // 抗锯齿
QSurfaceFormat::setDefaultFormat(format);
// 设置应用信息
app.setApplicationName("CloudView");
app.setOrganizationName("CloudView");
app.setApplicationVersion(APP_VERSION);
// 设置应用程序图标
app.setWindowIcon(QIcon(":/logo.png"));
// 创建并显示主窗口
CloudViewMainWindow mainWindow;
mainWindow.setWindowTitle(QString("点云查看器 v%1").arg(APP_VERSION));
mainWindow.resize(1280, 720);
mainWindow.show();
return app.exec();
}