82            if (texture_name==NULL) 
return;
 
   97        if (texture_name==NULL) 
return;
 
 
  211    if (facetdata==NULL) 
return false;
 
  212    if (facetdata->
index==NULL || facetdata->
vertex==NULL || facetdata->
normal==NULL) 
return false;
 
  216    if (!
getm()) 
return false;
 
  218    for (
int i=0; i<facetdata->
num_index; i++) {
 
  226    if (facetdata->
texcrd!=NULL) {
 
 
  249    if (facetdata==NULL) 
return false;
 
  250    if (facetdata->
index==NULL || facetdata->
vertex==NULL || facetdata->
normal==NULL) 
return false;
 
  253    if (brep==NULL) 
return false;
 
  259    if (vertex_data==NULL) {
 
  263    int vcount = facetdata->
vcount;
 
  283    BREP_CONTOUR_LIST::iterator icon;
 
  286        for (
int i=0; i<vcount; i++) {
 
 
  320    if (impvtx==NULL || impnrm==NULL) 
return false;
 
  322    set(impnum, impnum/vcount, vcount);
 
  323    if (!
getm()) 
return false;
 
 
  363    if (impvtx==NULL) 
return false;
 
  366    if (brep==NULL) 
return false;
 
  371    if (vertex_data==NULL) {
 
  394    BREP_CONTOUR_LIST::iterator icon;
 
  397        for (
int i=0; i<vcount; i++) {
 
 
  444        if (uvmap==NULL) 
return NULL;
 
  445        memset(uvmap, 0, len);
 
  453            binormal.
set(0.0, 1.0, 0.0);
 
  457            binormal.
set(1.0, 0.0, 0.0);
 
  464        uvmap[i].
u = 0.5 + (binormal*pos)*2.0;
 
  465        uvmap[i].
v = 0.5 - (tangent *pos)*2.0;
 
 
  477    if (node==NULL) 
return;
 
 
  491    if (node==NULL) 
return NULL;
 
 
  509    if (list==NULL) 
return node;
 
  510    if (node==NULL) 
return list;
 
 
#define JBXL_MATERIAL_PREFIX
 
void free_Buffer(Buffer *buf)
Buffer型変数のバッファ部を解放する
 
Buffer init_Buffer()
初期化したBuffer型変数を返す.
 
int cat_Buffer(Buffer *src, Buffer *dst)
Buffer変数 srcから dstへバッファを catする.
 
#define make_Buffer_str(str)
set_Buffer()
 
#define cat_s2Buffer(src, dst)
cat_b2Buffer()
 
#define make_Buffer_bystr(str)
set_Buffer()
 
void dup(ArrayParam< T > a, bool del=true)
 
BREP_CONTOUR_LIST contours
Contours リスト
 
long int index
シーケンシャルに増加する一意的な番号.Octree に格納されるときに設定される.
 
Vector< double > point
頂点の座標.
 
Vector< double > normal
法線ベクトル.周りの Contour の法線ベクトルの平均.
 
UVMap< double > uvmap
曲面のUV座標
 
BREP_VERTEX * vertex
Start of Vertex.
 
int num_data
データ数.(vertex, normal, texcrd, weight の要素数)
 
UVMap< double > * texcrd
テクスチャマップ texcrd[index[0]], texcrd[index[1]], texcrd[index[2]], ... の順に並ぶ
 
int num_index
インデックスの数.(index の要素数)
 
Vector< double > * vertex
頂点データ vertex[index[0]], vertex[index[1]], vertex[index[2]], ... の順に並ぶ
 
ArrayParam< int > * weight
Skin の Weight weight[index[0]], weight[index[1]], weight[index[2]], ... の順に並ぶ
 
Vector< double > * normal
法線ベクトル normal[index[0]], normal[index[1]], normal[index[2]], ... の順に並ぶ
 
TextureParam texture
テクスチャ
 
void dup(MaterialParam m)
 
MeshObject の Polygonデータ(1面)を格納するクラス.リスト構造を取る.
 
MaterialParam material_param
マテリアルパラメータ
 
Vector< double > * normal_value
法線ベクトルデータの並び.要素数は num_vertex
 
bool same_material
他の Node が既に同じマテリアルを使用している.
 
bool computeVertexByBREP(ContourBaseData *facetdata)
 
void delMaterialParam(void)
 
int num_texcrd
テクスチャ画像の座標数.通常は num_vertex に等しい.(texcrd_value の要素数)
 
int num_index
頂点の延べ数.num_polygon*MeshObjectData::num_vcount (num_polygon*3)(data_index の要素数)
 
void execAffineTransUVMap(UVMap< double > *uvmap=NULL, int num=-1)
 
ArrayParam< int > * weight_value
頂点の重み.Jointを持つデータに使用される.要素数は num_vertex. 各 weight_value[i] の値は トータルで正規化される必要がある.
 
bool computeVertexDirect(ContourBaseData *facetdata)
 
int * data_index
インデックスデータ.要素数は num_index
 
UVMap< double > * texcrd_value
テクスチャマップの並び.要素数は num_texcrd
 
bool getm(int vertex=0, int polygon=0, int vcount=0)
メモリの確保
 
void set(int vertex, int polygon, int vcount=3)
 
void setMaterialID(const char *str)
 
UVMap< double > * generatePlanarUVMap(Vector< double > scale, UVMap< double > *uvmap=NULL)
 
Buffer material_id
マテリアルを識別するID.JBXL_MATERIAL_PREFIX で始まる.
 
int num_vertex
頂点のデータ数.(vertex_value, normal_value の要素数)
 
Vector< double > * vertex_value
頂点データの並び.要素数は num_vertex
 
void setMaterialParam(MaterialParam param)
ノードにマテリアルパラメータを設定し,他のノードに同じマテリアルが存在するかチャックする.
 
void execTrans(UVMap< double > *uv, int n)
Rotate -> Scale -> Shift.
 
void set(T X, T Y=0, T Z=0, double N=0.0, double C=1.0, int D=0)
 
void freeBrepSolid(BREP_SOLID *&solid)
 
void freeMeshFacetList(MeshFacetNode *&node)
 
class DllExport BREP_SOLID
 
bool isSameMaterial(MaterialParam a, MaterialParam b)
compare each texture names and colors
 
MeshFacetNode * DelMeshFacetNode(MeshFacetNode *node)
 
DllExport BREP_VERTEX ** GetOctreeVertices(OctreeNode *octree, long int *vertexno)
 
DllExport int CreateTriSolidFromVector(BREP_SOLID *solid, int vno, Vector< double > *v, Vector< double > *n=NULL, UVMap< double > *uv=NULL, ArrayParam< int > *w=NULL, bool dupli=false, bool check=true)
 
void freeMeshFacetNode(MeshFacetNode *&node)
 
MeshFacetNode * AddMeshFacetNode(MeshFacetNode *list, MeshFacetNode *node)
 
unsigned char * buf
バッファの先頭へのポインタ.str[bufsz]は必ず 0x00となる.