freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

c課程設(shè)計3d模型管理系統(tǒng)-資料下載頁

2025-02-10 07:42本頁面

【導(dǎo)讀】課程設(shè)計題目:簡單3D建模系統(tǒng)。時時間間::2021年年12月月

  

【正文】 *opx+yyy*opy+yyz*opz)/(float)sqrt(yyx*yyx+yyy*yyy+yyz*yyz)/opr。 sina=(float)sqrt(1cosa*cosa)。 sinb=(float)sqrt(1cosb*cosb)。 if(cosa0)sign=1。else sign=1。 xp=opr*sinb*sign。 //第一點在視野中的 x 坐標(biāo) if(cosb0)sign=1。else sign=1。 yp=opr*sina*sign。 //第一點在視野中的 y 坐標(biāo) *(pShodowX+j21)=360+int(xp)。 *(pShodowY+j21)=260int(yp)。 (pPoints+j21)mark=true。 //標(biāo)明此點已作了投影 } } bkk=*((pPlanes+N1)pBn+i1)。 //獲取此邊編號 if((pBorders+bkk1)mark==false){ //如果此邊沒有繪制過 (*(pShodowX+j11),*(pShodowY+j11))。 (*(pShodowX+j21),*(pShodowY+j21))。 //繪制此面外環(huán)中的第 i 條邊 (pBorders+bkk1)mark=true。 //標(biāo)明此邊已繪制 } }/////////////////////////////////////////內(nèi)邊繪制完畢 } //////////////////////////////////////////////////// void ThreeD::show(CClientDC amp。dc,TDPoint amp。viewPoint,TDPoint amp。viewAngle,float L) { for(int i=1。i=bNpN+2。i++) paintPlane(i,viewPoint,viewAngle,dc,L)。 } //////////////////////////////////////////////////// 4. 5 TdNode 類的實現(xiàn) include include class TdNode :public CCmdTarget { private: 24 ThreeD *m_3d。 TdNode *pM。 public: TdNode(int n,int m){ pM=NULL。 m_3d=new ThreeD(n,m)。 } TdNode(ThreeD *t){ pM=NULL。 m_3d=t。 } virtual ~TdNode(){} friend class List_3D。 }。 //////////////////////////////////////////////////// 4. 6 List_3D 類的實現(xiàn) include class List_3D { private: int length。 //鏈表長度 int step。 //視點移動步長 float L。 //眼睛到屏幕的距離 float rollingAngle。 //翻轉(zhuǎn)角度 TdNode *head。 //頭節(jié)點指針 CWnd *pWnd。 //窗口對象指針 TDPoint centre。 //所有物體的幾何中心 TDPoint viewPoint。 //視點坐標(biāo) TDPoint viewAngle。 //視角向量 單位向量 public: List_3D(CWnd *pWnd1=NULL)。 virtual ~List_3D()。 int GetLength(){return length。} ThreeD* NewNode(int n,int m)。//新建一個節(jié)點,物體的點數(shù) n,邊數(shù) m ThreeD* AddNode(ThreeD *t)。 ThreeD* Get_3D(int n)。 //獲取第 n 個節(jié) 點中的 3D 物體 bool DeleteNode(int n)。 //刪除第 n 個節(jié)點 void Get_Spin_Step_L(float amp。spin,int amp。step1,float amp。L1)。 void Set_Spin_Step_L(float spin,int step1,float L1)。 void RefreshCentre()。 void SetViewPoint(float x1=0,float y1=0,float z1=0)。 //設(shè)置視點坐標(biāo) void SetViewPoint(TDPoint amp。p){viewPoint=p。}//設(shè)置視點坐標(biāo) void SetViewAngle(float a,float b,float r)。 //設(shè)置視角坐標(biāo) 25 void SetViewAngle(TDPoint amp。p)。 //設(shè)置視角坐標(biāo) void SetWnd(CWnd *pWnd1){pWnd=pWnd1。} //設(shè)置窗體指針 void GetViewPointAndAndle(CString amp。s0)。 //獲取視點和實線向量 void caculatePlaneNormalVerctor()。 //計算節(jié)點中各物體各面的法向量 void ViewPointMove(int direction)。 void RollingOver(int direction)。 bool show()。 }。 //////////////////////////////////////////////////////////// List_3D::List_3D(CWnd *pWnd1) { length=0。 head=NULL。 pWnd=pWnd1。 L=500。 step=3。 rollingAngle=。 =500。 =500。 =500。 float r=1/(float)sqrt(3)。 =r。 =r。 =r。 =0。 =0。 =0。 } //////////////////////////////////////////////////// include include include List_3D::~List_3D() { TdNode *p=head,*q。 while(p) { q=ppM。 delete p。 p=q。 } } //////////////////////////////////////////////////// 26 void List_3D::Get_Spin_Step_L(float amp。spin,int amp。step1,float amp。L1) { spin=rollingAngle。 step1=step。 L1=L。 } //////////////////////////////////////////////////// void List_3D::Set_Spin_Step_L(float spin,int step1,float L1) { rollingAngle=spin。 step=step1。 L=L1。 } //////////////////////////////////////////////////// ThreeD* List_3D::NewNode(int n,int m) { if(n4||m6)return NULL。 TdNode *p=head。 if(!p){ head=new TdNode(n,m)。 length++。 return headm_3d。 } while(ppM)p=ppM。 ppM=new TdNode(n,m)。 length++。 return ppMm_3d。 } //////////////////////////////////////////////////// ThreeD* List_3D::AddNode(ThreeD *t) { TdNode *p=head。 if(!p){ head=new TdNode(t)。 length++。 return headm_3d。 } while(ppM)p=ppM。 ppM=new TdNode(t)。 length++。 return ppMm_3d。 } //////////////////////////////////////////////////// bool List_3D::DeleteNode(int n) 27 { if(n1||nlength)return false。 TdNode *p=head。 if(n==1){ head=ppM。 delete p。 length。 return true。 } TdNode *q。 for(int i=1。in。i++){ q=p。 p=ppM。 } qpM=ppM。 length。 delete p。 return true。 } //////////////////////////////////////////////////// ThreeD* List_3D::Get_3D(int n) { if(n1||nlength)return NULL。 TdNode *p=head。 for(int i=1。in。i++)p=ppM。 return pm_3d。 } //////////////////////////////////////////////////// void List_3D::RefreshCentre() { if(length==0)return。 int i,nbefore=0。 TdNode *p=head。 for(i=1。ilength。i++){ nbefore+=pm_3dGetpN()。 p=ppM。 } //p 指向最后一個節(jié)點 float xc=0,yc=0,zc=0。 TDPoint point。 for(i=1。i=pm_3dGetpN()。i++){ if(pm_3dGetPoint(i,point)){ xc+=。 yc+=。 zc+=。 28 } } =(nbefore*+xc)/(nbefore+pm_3dGetpN())。 =(nbefore*+yc)/(nbefore+pm_3dGetpN())。 =(nbefore*+zc)/(nbefore+pm_3dGetpN())。 } //////////////////////////////////////////////////// void List_3D::SetViewPoint(float x1,float y1,float z1) { =x1。 =y1。 =z1。 } //////////////////////////////////////////////////// void List_3D::SetViewAngle(float a,float b,float r) { float mo=(float)sqrt(a*a+b*b+r*r)。 =a/mo。 =b/mo。 //單位化 =r/mo。 TdNode *q=head。 while(q){ (qm_3d)MarkPlane(viewAngle)。 q=qpM。 } } //////////////////////////////////////////////////// void List_3D::SetViewAngle(TDPoint amp。p) { f
點擊復(fù)制文檔內(nèi)容
教學(xué)課件相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1