登录
首页 » OpenGL图像 » Opengl绘制镜子效果

Opengl绘制镜子效果

于 2022-04-13 发布 文件大小:310.87 kB
0 216
下载积分: 2 下载次数: 1

代码说明:

应用背景混合是什么呢?混合就是把两种颜色混在一起。具体一点,就是把某一像素位置原来的颜色和将要画上去的颜色,通过某种方式混在一起,从而实现特殊的效果。 假设我们需要绘制这样一个场景:透过红色的玻璃去看绿色的物体,那么可以先绘制绿色的物体,再绘制红色玻璃。在绘制红色玻璃的时候,利用“混合”功能,把将要绘制上去的红色和原来的绿色进行混合,于是得到一种新的颜色,看上去就好像玻璃是半透明的。 要使用OpenGL的混合功能,只需要调用:glEnable(GL_BLEND);即可。 要关闭OpenGL的混合功能,只需要调用:glDisable(GL_BLEND);即可。 注意:只有在RGBA模式下,才可以使用混合功能,颜色索引模式下是无法使用混合功能的。关键技术 请点击左侧文件开始预览 !预览只提供20%的代码片段,完整代码需下载后查看 加载中 侵权举报

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

发表评论

0 个回复

  • Author : yulongsun penGL need to give Chinese exports, However, we did not find...
    作者: yulongsun 需要在penGL中作中文输出,但没发现何处有合适的,把一个叫zhaohui的人写的英文字符输出类改了一下,可以输出中文了,但却并没有解决我的问题。我感觉得应该使用wglUseFontBitmaps()函数使字体保持不变。但我对 OpenGL不熟,不知怎么用。不过我做的东西也许对别人有用,权且放在这儿。同时希望得到指教。 文件:CGLFont.c CGLFont.h env::windows2000, vc6.0 e-mail: yulongsun@163.com -Author : yulongsun penGL need to give Chinese exports, However, we did not find a suitable where, a person called zhaohui write English characters output category changed a bit, the Chinese can export, but not solve the problem. I feel that you should use wglUseFontBitmaps () function so that fonts remain unchanged. But I OpenGL well, I do not know how use. But I may do something useful for others, the time being here. Hope received the exhibitions. Documents : CGLFont.c CGLFont.h env : : Solaris, vc6.0 e-mail : yulongsun@163.com
    2022-02-25 06:21:46下载
    积分:1
  • mixed use OpenGL technology to create artistic effects of the source
    OpenGL中使用混合技术创造艺术效果的源程序-mixed use OpenGL technology to create artistic effects of the source
    2023-01-03 10:45:03下载
    积分:1
  • use the OpenGL a robot procedures. The robot can be achieved various moves.
    用OpenGL实现的一个机器人程序。 可以实现机器人的各种动作。-use the OpenGL a robot procedures. The robot can be achieved various moves.
    2022-02-14 17:58:45下载
    积分:1
  • OpengGL prepared by the mapping procedure, known image of spatial information, y...
    OpengGL编写的映射程序,已知图像的空间信息,就可以运行此程序,把图像绘制出来,并且在不同的单元赋予不同的颜色 -OpengGL prepared by the mapping procedure, known image of spatial information, you can run this program, the image is drawn out, and the different modules given different colors
    2022-08-25 02:41:10下载
    积分:1
  • light on the demonstration and tutorial materials, mouse movement to amend the p...
    关于光照和材质的演示教程,通过鼠标移动修改参数来显示不同的效果-light on the demonstration and tutorial materials, mouse movement to amend the parameters to show different results
    2023-04-15 00:00:04下载
    积分:1
  • 实现基本的几何三的使用
    利用OPENGL实现基本三维几何图像的绘制和显示,源代码。-OPENGL realize the use of basic geometric three-dimensional image rendering and display, the source code.
    2023-07-09 04:10:04下载
    积分:1
  • OpenGL foundation to the friend which begins studies OpenGL may have a look to s...
    OpenGL基础 对初学OpenGL的朋友可以看看 里面对于基本图形绘制说的很明白 是本不错的书-OpenGL foundation to the friend which begins studies OpenGL may have a look to say regarding the basic graph plan understood very much is this good book
    2022-02-03 21:19:17下载
    积分:1
  • opengl 描述地形
    适合于初学者刚接触opengl 简单的地形图表面
    2023-04-29 17:25:03下载
    积分:1
  • 水木清华的精华区OpenGL系列例程及教程,非常好,适合OpenGL初学者...
    水木清华的精华区OpenGL系列例程及教程,非常好,适合OpenGL初学者-SMTH, the focus of OpenGL series of routines and classes, is very good and is suitable for beginners OpenGL
    2022-04-15 23:43:04下载
    积分:1
  • escena OpenGL
    导入javax.media.opengl文件.德国劳埃德船级社;
    2022-07-05 03:49:59下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载