使用OpenGL绘制曲面图(一)
1. 环境
- Windows10, Visual Studio 2015
- OpenGL, 版本4.5
- GLFW, 提供窗口支持
- GLAD,方便OpenGL函数调用
- glm, 提供矩阵向量等运算
2.项目参考和环境配置教程
项目参考:https://github.com/cindyli-13/3D-Surface-Plotter
环境配置:https://learnopgl.cn
3.项目运行演示
- z = sin(t) * 8*sin(sqrt(pow(x, 2) + pow(y, 2))) / sqrt(pow(x, 2) + pow(y, 2));
- z = sin(pow(x/2.5, 2) + pow(y/2.5, 2));
- z = (pow(x/1.5,2) + pow(y/1.5,2)) * 0.3;
4.后续
后面将尝试在Qt环境中编译出来,并能正常运行出来。