Create HouseLightingModel
This commit is contained in:
1 parent
52570a9a0b
commit
9f322bccba
67 files changed
+4536
No files matched your search
@@ -0,0 +1,45 @@
|
||||
// Face.cpp: implementation of the CFace class.
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "Test.h"
|
||||
#include "Face.h"
|
||||
|
||||
#ifdef _DEBUG
|
||||
#undef THIS_FILE
|
||||
static char THIS_FILE[]=__FILE__;
|
||||
#define new DEBUG_NEW
|
||||
#endif
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
// Construction/Destruction
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
||||
CFace::CFace()
|
||||
{
|
||||
vI=NULL;
|
||||
fNormal=CVector(CP3(0.0,0.0,1.0));
|
||||
}
|
||||
|
||||
CFace::~CFace()
|
||||
{
|
||||
if(vI!=NULL)
|
||||
{
|
||||
delete []vI;
|
||||
vI=NULL;
|
||||
}
|
||||
}
|
||||
|
||||
void CFace::SetNum(int n)
|
||||
{
|
||||
vN=n;
|
||||
vI=new int[n];
|
||||
}
|
||||
|
||||
void CFace::SetFaceNormal(CP3 pt0,CP3 pt1,CP3 pt2)//¼ÆËãÐ¡Ãæ·¨Ê¸Á¿
|
||||
{
|
||||
CVector V01(pt0,pt1);
|
||||
CVector V02(pt0,pt2);
|
||||
fNormal=Cross(V01,V02);
|
||||
}
|
||||
Reference in new issue
Block a user