登录
首页 » OpenGL图像 » MFC Opengl三维控件

MFC Opengl三维控件

于 2023-04-10 发布 文件大小:391.22 kB
0 182
下载积分: 2 下载次数: 1

代码说明:

应用背景 1当二维自定义控件的绘制效果无法满足图形需求时,需要考虑三维控件的可行性; 2在三维控件中,可绘制立体的效果; 3 可在二维图形程序中,绘制三维的图表,如饼图。曼哈顿图等; 关键技术 1 mfc自绘制控件的技术实现; 2 opengl基本绘制图形 3 opengl图形框架,包括编辑,旋转,视图缩放等 4 提供了三维投影,拾取基础类的代码;  5 自定义控件派生自static控件; void COpenglWnd::Paint() { InitOpengl(); glMatrixMode(GL_MODELVIEW); glLoadIdentity(); ////////////////////////////////////////////////////////////////////////// glPushMatrix(); glTranslated(0,0, -m_OpenglSize.GetEyeDistance() ); RenderOpengl(); glPopMatrix(); HDC m_hgldc = ::GetDC(m_hWnd); ::SwapBuffers(m_hgldc); }

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • openGL做出来的飞机螺旋桨模拟 可以运行
    openGL做出来的飞机螺旋桨模拟 可以运行-the Aircraft Propeller made by openGL it running very well
    2023-01-20 03:15:04下载
    积分:1
  • opengl 描述地形
    适合于初学者刚接触opengl 简单的地形图表面
    2023-04-29 17:25:03下载
    积分:1
  • image processing to the needs and would like to achieve th ree
    本人为了图像处理的需要,很想实现二维图像的三维显示,于是写了本代码,希望与此有兴趣的读者共享。图像的获取一是bmp图像文件,二是来自剪贴板。本代码在MFC中调用OpenGL库函数来实现二维图像的三维显示,图像的宽度、高度和象素的亮度分别为三维空间的x,z,y坐标。程序主要有初始化、绘图、资源释放和操作部分,这些功能在OGL_MFCView.cpp文件中实现。OpenGL库的初始化在该文件中的OnCreate,InitScene和DrawScene函数中实现,主要初始化OpenGL运行时的环境变量,三维物体的光照,材质等,由于介绍OpenGL库的初始化的文档很多,在这里我就不多说了,感兴趣的读者可以参考有关的文档。在DrawScene函数中调用全局函数GLDraw3DBMP完成绘图部分。 编译源代码时,必须把opengl32.lib glu32.lib链到工程中。 可以通过对话框改变材质。按上下箭头键可以实现三维图像的绕x轴旋转,按左右箭头键可以实现三维图像绕z轴旋转。 本代码在Windows2000下编译通过。-image processing to the needs and would like to achieve th ree-dimensional two-dimensional images, then wrote the code, with the readers are interested in sharing. Image Access First bmp image files, two from the clipboard. The MFC code Calling OpenGL library functions to achieve the three-dimensional two-dimensional image display, image width, height and pixel brightness of the three-dimensional space x, z, y coordinates. Main initialization procedures, mapping, the release of resources and operation, the function of these documen
    2023-02-17 05:45:03下载
    积分:1
  • 用OPENGL写的3D的形,立体的蜡烛形可以动态的旋转.
    用OPENGL写的3D的图形,立体的蜡烛图形可以动态的旋转.-write with OpenGL 3D graphics, three-dimensional graphics can be candles dynamic rotation.
    2022-09-01 02:00:04下载
    积分:1
  • OPENGL的学习源代码,很容易上手的
    OPENGL的学习源代码,很容易上手的-OpenGL study the source code, it is easy to get started with the
    2022-07-09 18:38:18下载
    积分:1
  • OpenGL模型视矩阵变换例程
    向量类, 向量的叉乘、点乘运算矩阵类, 矩阵类包括矩阵的相乘、转置、求逆、求行列式等功能,添加OpenGL中可用的旋转、缩放和平移等矩阵运算 可实现类似于MATLAB的矩阵运算功能形象化展示模型视图矩阵变换, 分别管理模型矩阵、视图矩阵,
    2022-07-10 00:13:05下载
    积分:1
  • VC and OpenGL book, "3ds animation document readers" source code, Deve...
    用VC++和OpenGL写的《3ds动画文件阅读器》源代码,对于使用OpenGL开发3d程序的初学者有很好的参考价值。-VC and OpenGL book, "3ds animation document readers" source code, Development for the use of OpenGL 3 d procedures beginners have a good reference value.
    2023-08-24 07:45:03下载
    积分:1
  • 利用VC++和OpenGL开发的模拟雨滴效果。雨滴落在…
    利用vc++和openGL开发的模拟雨滴效果。雨滴落入一个池塘中。-Use vc++ And openGL simulation developed raindrop effect. Raindrops falling into a pond.
    2023-01-31 00:50:03下载
    积分:1
  • mapping Icosahedral, making eight feet out with a graphic, such as Prism, wirefr...
    绘制二十面体,使得八个脚个有一个图形,有棱柱之类,是线框图。-mapping Icosahedral, making eight feet out with a graphic, such as Prism, wireframe.
    2022-01-25 17:04:54下载
    积分:1
  • openGL之摄漫游天空盒
    VC6.0,中opengl环境中,关于摄像漫游和天空盒的代码,备注非常详细,简单易懂。
    2022-04-26 17:14:36下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载