예제 #1
0
파일: x3dNurbs.cpp 프로젝트: lpsoares/jinx
NurbsCurve *NurbsCurve::get(DOMNode *node) {
	
	NurbsCurve *nurbsCurve;
	
	unsigned int i; 				// variable to counter
	DOMNamedNodeMap *attributes;	// variable to hold the node attributes
	
	attributes = node->getAttributes();
	for (i = 0; i < attributes->getLength(); i++) {
		if (!strcmp(XMLString::transcode(attributes->item(i)->getNodeName()) , "USE")) {
			return((NurbsCurve *)getLink(XMLString::transcode(attributes->item(i)->getNodeValue())));
		} 
	}
	
	nurbsCurve = new NurbsCurve();
	nurbsCurve->read(node);
	
	
	return nurbsCurve;
	
}
예제 #2
0
void NurbsCurve<float,2>::drawAaImg(Image_Color& Img, const Color& color, int precision, int alpha){
  NurbsCurve<float,3> C ;
  to3D(*this,C) ; 
  C.drawAaImg(Img,color,precision,alpha) ;
}
예제 #3
0
int NurbsCurve<float,2>::writeVRML97(ostream& fout,float radius,int K, const Color& color,int Nu,int Nv, float u_s, float u_e) const{
  NurbsCurve<float,3> C ;
  to3D(*this,C) ; 
  return C.writeVRML97(fout,radius,K,color,Nu,Nv,u_s,u_e) ;
}
예제 #4
0
int NurbsCurve<float,2>::writeVRML97(const char* filename,float radius,int K, const Color& color,int Nu,int Nv, float u_s, float u_e) const{
  NurbsCurve<float,3> C ;
  to3D(*this,C) ; 
  return C.writeVRML97(filename,radius,K,color,Nu,Nv,u_s,u_e) ;
}
예제 #5
0
int NurbsCurve<double,2>::writeVRML97(ostream& fout,double radius,int K, const Color& color,int Nu,int Nv, double u_s, double u_e) const{
  NurbsCurve<double,3> C ;
  to3D(*this,C) ; 
  return C.writeVRML97(fout,radius,K,color,Nu,Nv,u_s,u_e) ;
}
예제 #6
0
int NurbsCurve<double,2>::writeVRML97(const char* filename,double radius,int K, const Color& color,int Nu,int Nv, double u_s, double u_e) const{
  NurbsCurve<double,3> C ;
  to3D(*this,C) ; 
  return C.writeVRML97(filename,radius,K,color,Nu,Nv,u_s,u_e) ;
}