资源简介
cd7b02a80b63de41fce63008c278aae1.rar

代码片段和文件信息
// DrawScene.cpp: implementation of the CDrawScene class.
//
//////////////////////////////////////////////////////////////////////
#include “stdafx.h“
#include “quhe3Dtrans.h“
#include “DrawScene.h“
#include “gl\gl.h“
#include “gl\glu.h“
#include “quhe3DtransDoc.h“
#include “quhe3DtransView.h“
#include “TransControl.h“
#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif
//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////
CDrawScene::CDrawScene()
{
}
CDrawScene::CDrawScene(Cquhe3DtransView *pView)
{
m_pView = pView;
}
CDrawScene::~CDrawScene()
{
}
void CDrawScene::DrawScene()
{
DrawBackground();
CaculateMatrix(); // Caculate the transing matrix.
DrawBall(); // Trans the ball and display.
pClipSpaceobject();
Projectobject();
DrawClipBall();
}
void CDrawScene::DrawBackground()
{
Cquhe3DtransDoc *pDoc = (Cquhe3DtransDoc *)m_pView->GetDocument();
/* Draw Space Axis */
glColor3f(1.0f 0.0f 0.0f);
glBegin(GL_LINES); // X Axis
glVertex3f( 3.0f 0.0f 0.0f);
glVertex3f(-6.0f 0.0f 0.0f);
glEnd();
glColor3f(0.0f 1.0f 0.f);
glBegin(GL_LINES); // Y Axis
glVertex3f( 0.0f 3.0f 0.0f);
glVertex3f( 0.0f -3.0f 0.0f);
glEnd();
glColor3f(0.0f 1.0f 1.0f);
glBegin(GL_LINES); // Z Axis
glVertex3f( 0.0f 0.0f 8.0f);
glVertex3f( 0.0f 0.0f -24.0f);
glEnd();
/* Draw window on YOZ Plane */
glColor3f(1.0f 1.0f 0.0f);
glBegin(GL_LINES);
glVertex3f(0.0 pDoc->winLypDoc->winLz);
glVertex3f(0.0 pDoc->winRypDoc->winLz);
glVertex3f(0.0 pDoc->winRypDoc->winLz);
glVertex3f(0.0 pDoc->winRypDoc->winRz);
glVertex3f(0.0 pDoc->winRypDoc->winRz);
glVertex3f(0.0 pDoc->winLypDoc->winRz);
glVertex3f(0.0 pDoc->winLypDoc->winRz);
glVertex3f(0.0 pDoc->winLypDoc->winLz);
glEnd();
// link eye and window to create space clip box
glColor3f(1.0f 1.0f 0.0f);
glBegin(GL_LINES);
float xyz;
glVertex3f(pDoc->eyeX pDoc->eyeYpDoc->eyeZ);
x = -pDoc->eyeX * 2.5 + pDoc->eyeX;
y = (pDoc->winLy - pDoc->eyeY) * 2.5 + pDoc->eyeY;
z = (pDoc->winLz - pDoc->eyeZ) * 2.5 + pDoc->eyeZ;
glVertex3f(x y z);
glVertex3f(pDoc->eyeX pDoc->eyeYpDoc->eyeZ);
x = -pDoc->eyeX * 2.5 + pDoc->eyeX;
y = (pDoc->winRy - pDoc->eyeY) * 2.5 + pDoc->eyeY;
z = (pDoc->winLz - pDoc->eyeZ) * 2.5 + pDoc->eyeZ;
glVertex3f(x y z);
glVertex3f(pDoc->eyeX pDoc->eyeYpDoc->eyeZ);
x = -pDoc->eyeX * 2.5 + pDoc->eyeX;
y = (pDoc->winRy - pDoc->eyeY) * 2.5 + pDoc->eyeY;
z = (pDoc->winRz - pDoc->eyeZ) * 2.5 + pDoc->eyeZ;
glVertex3f(x y z);
glVertex3f(pDoc->eyeX pDoc->eyeYpDoc->eyeZ);
x = -pDoc->eyeX *
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 1507 2008-12-09 17:35 quhe3Dtrans\DrawScene.h
文件 2224 2008-12-09 17:35 quhe3Dtrans\quhe3DtransVIEW.h
文件 2971 2008-12-12 17:24 quhe3Dtrans\quhe3Dtrans.clw
文件 4431 2008-12-09 17:35 quhe3Dtrans\ReadMe.txt
文件 1411 2008-12-09 17:35 quhe3Dtrans\quhe3Dtrans.h
文件 4299 2008-12-09 17:35 quhe3Dtrans\quhe3Dtrans.cpp
文件 1054 2008-12-09 17:35 quhe3Dtrans\StdAfx.h
文件 213 2008-12-09 17:35 quhe3Dtrans\StdAfx.cpp
文件 1104 2008-12-09 17:35 quhe3Dtrans\Resource.h
文件 2006 2008-12-09 17:35 quhe3Dtrans\TransControl.h
文件 7280 2008-12-09 17:35 quhe3Dtrans\quhe3DtransVIEW.cpp
文件 5042 2008-12-09 17:35 quhe3Dtrans\quhe3Dtrans.dsp
文件 545 2008-12-09 17:35 quhe3Dtrans\quhe3Dtrans.dsw
文件 839 2008-12-12 17:25 quhe3Dtrans\quhe3Dtrans.plg
文件 1713 2008-12-09 17:35 quhe3Dtrans\MainFrm.h
文件 3087 2008-12-09 17:35 quhe3Dtrans\MainFrm.cpp
文件 841 2008-12-09 17:35 quhe3Dtrans\TypeDefine.h
文件 167 2008-10-03 19:23 quhe3Dtrans\ClearProjec.bat
文件 29376 2008-12-12 16:54 quhe3Dtrans\quhe3Dtrans.aps
文件 12548 2008-12-09 17:35 quhe3Dtrans\quhe3Dtrans.rc
文件 272896 2008-12-09 17:33 quhe3Dtrans\cg3Dtrans.opt
文件 6884 2008-12-12 17:18 quhe3Dtrans\quhe3DtransDOC.cpp
文件 7482 2008-12-12 17:23 quhe3Dtrans\TransControl.cpp
文件 2561 2008-12-12 17:24 quhe3Dtrans\quhe3DtransDOC.h
文件 17303 2008-12-12 17:25 quhe3Dtrans\DrawScene.cpp
文件 54784 2008-12-12 17:26 quhe3Dtrans\quhe3Dtrans.opt
文件 151647 2008-12-12 17:25 quhe3Dtrans\Debug\quhe3Dtrans.exe
文件 403 2008-12-09 17:35 quhe3Dtrans\res\quhe3Dtrans.rc2
文件 1078 2008-12-09 17:35 quhe3Dtrans\res\quhe3DtransDOC.ico
文件 1078 2008-12-09 17:35 quhe3Dtrans\res\quhe3Dtrans.ico
............此处省略9个文件信息
相关资源
- 集客9341固件ap
- 遍历USB设备,获取USB序列号
- delphi源码-实现软件注册机
- Microservices_Designing_Deploying
-
Design for em
bedded Image Processing on FPG - GNU/Linux系统开发者需要从桌面突破
- Concurrency in Go(EarlyRelease) 无水印p
- cfx中ccl语言使用手册
- 单元测试一条龙1.50final
- 金丰300T级进冲床电气控制原理图1
- DSP实验(10次实验有详细步骤)
- HP Compaq 8200 Elite 系列商用台式机
- 2019年软考高级下半年信息系统项目管
- Assembly Language for x86 Processors (7th Ed
- Mule基础教程中文版
- 易语言凡哥记事本V1源码易语言凡哥记
- 易语言码表文本加解密模块源码
- DIR2病毒源代码(汇编语言编写)
- ADC0809的采样控制电路的实现.doc
- CRichEditView显示行号的代码
- STM8S代码例程
- 上海交大计算机图形学课程视频31集
- Source Insight 4.0.0080破解文件 替换lic
- Apk加固Demo
- VMware Workstation Pro 15 注册机
- HumanDet(公交车系统模式识别)
- 基于89C51的智能台灯
- 计算机数值分析.rar
- 水晶排课 11.53 破解版
- 51智能排课系统大课表版v5.1.3中文免费
评论
共有 条评论