Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members   Examples  

/home/xchen/xia/src/glrender/demoSrfCmpletion_demo.cc

#include <View.H>
#include <TensorBlossom.H>

using namespace xchen;

void srf_cmpl(View* v)
{
  TensorBlossom<1,3> *boundary = new TensorBlossom<1,3>(3, 6);
  boundary->ControlMesh() =
    E3( -0.921053,  0.807566, 0 ),
    E3( -0.421053, -0.15625,  0 ),
    E3( -0.236842,  0.794408, 0 ),
    E3(  0.523026,  0.794408, 0 ),
    E3(  0.523026, -0.745066, 0 ),
    E3( -0.921053, -0.745066, 0 );
  
  boundary->SetPeriodicEnd();
  boundary->KnotVector() = 0.0, 1, 2, 3, 4, 5, 6;
    
  TensorBlossom<1,3> *maxis = new TensorBlossom<1,3>(1, 7);
  E3 
    mpoint0 = E3( -0.595395,  -0.429276, 0 ),
    mpoint1 = E3(  0.0460526, -0.268092, 0 ),
    mpoint2 = E3(  0.118421,   0.402961, 0 );  

  maxis->ControlMesh() = mpoint0, mpoint0, mpoint0, mpoint1, mpoint2, mpoint2, mpoint1;
    
  maxis->SetPeriodicEnd();
  maxis->KnotVector() = 0.,1,2,2.4,3,4,5,6;
    
  TensorBlossom<2,3> *srf = new TensorBlossom<2,3>(ruled, boundary, maxis);
  new glModel(v, srf);
}
  
void new_glModel(View* v) 
{
  srf_cmpl(v);
}


Generated on Wed Apr 7 21:40:48 2004 by doxygen1.2.18