JunkBox_Lib++ (for Windows) 1.10.1
|
#include <MaterialParam.h>
Public Member Functions | |
MaterialParam (void) | |
virtual | ~MaterialParam (void) |
void | init (void) |
void | free (void) |
void | clear (void) |
void | dup (MaterialParam m) |
bool | isSetTexture (void) |
bool | isSetBumpMap (void) |
bool | isSetSpecMap (void) |
bool | isSetGlow (void) |
bool | isSetBright (void) |
bool | isSetShininess (void) |
bool | isSetTransparent (void) |
bool | isTransparency (void) |
void | setTextureName (const char *name) |
void | setBumpMapName (const char *name) |
void | setSpecMapName (const char *name) |
char * | getTextureName (void) |
char * | getBumpMapName (void) |
char * | getSpecMapName (void) |
char * | getName (void) |
void | setFullName (const char *extname) |
void | setParamString (const char *param) |
void | addParamString (const char *param) |
char * | getParamString (void) |
void | setKind (char c) |
void | setShininess (double s) |
void | setGlow (double g) |
void | setBright (double b) |
void | setGlossiness (double g) |
void | setEnvironment (double e) |
void | setSpecExp (double s) |
void | setLight (double l) |
char | getKind (void) |
double | getShininess (void) |
double | getGlow (void) |
double | getBright (void) |
double | getGlossiness (void) |
double | getEnvironment (void) |
double | getSpecExp (void) |
double | getLight (void) |
void | printParam (FILE *fp) |
char * | getBase64Params (unsigned char cc='-') |
Public Attributes | |
bool | enable |
int | mapping |
マッピング方法 | |
int | mflags |
メディアフラグ | |
int | others |
その他のフラグ | |
TextureParam | texture |
テクスチャ | |
TextureParam | specmap |
Specular マップ テクスチャ | |
TextureParam | bumpmap |
Bumpmap テクスチャ | |
Private Attributes | |
Buffer | paramstr |
パラメータ文字列 (Base64文字列) | |
char | kind |
オブジェクトの種類.'O', 'T', 'G', 'E' | |
double | shininess |
輝き | |
double | glow |
発光 | |
double | bright |
明るさ | |
double | glossiness |
滑らかさ | |
double | speclightexp |
SpecularLightExponents. | |
double | environment |
環境光 | |
double | light |
周りを照らすライト | |
Definition at line 152 of file MaterialParam.h.
|
inline |
Definition at line 180 of file MaterialParam.h.
References MaterialParam::init().
|
inlinevirtual |
Definition at line 181 of file MaterialParam.h.
|
inline |
Definition at line 215 of file MaterialParam.h.
References cat_s2Buffer, and MaterialParam::paramstr.
|
inline |
Definition at line 186 of file MaterialParam.h.
References MaterialParam::free(), and MaterialParam::init().
Referenced by MeshFacetNode::delMaterialParam().
void dup | ( | MaterialParam | m | ) |
Definition at line 244 of file MaterialParam.cpp.
References MaterialParam::bumpmap, TextureParam::dup(), MaterialParam::getParamString(), make_Buffer_str, MaterialParam::paramstr, MaterialParam::specmap, and MaterialParam::texture.
Referenced by jbxl::newMaterialParam(), and MeshFacetNode::setMaterialParam().
void free | ( | void | ) |
Definition at line 232 of file MaterialParam.cpp.
References MaterialParam::bumpmap, TextureParam::free(), free_Buffer(), MaterialParam::paramstr, MaterialParam::specmap, and MaterialParam::texture.
Referenced by MaterialParam::clear(), OBJFacetMtlNode::free(), and MeshFacetNode::setMaterialParam().
char * getBase64Params | ( | unsigned char | cc = '-' | ) |
マテリアルの各パラメータを Base64で文字列化する.ただし '/' はファイル名として使用できないので,cc に変換される.
戻りポインタは free する必要がある.
obj | オブジェクトの種類を示す任意の一文字 |
Definition at line 362 of file MaterialParam.cpp.
References MaterialParam::bright, encode_base64_filename(), TextureParam::getAlphaCutoff(), TextureParam::getAlphaMode(), TextureParam::getColor(), MaterialParam::glow, TextureParam::hasAlphaChannel(), MaterialParam::kind, MaterialParam::light, MATERIAL_ATTR_ALPHACUTOFF, MATERIAL_ATTR_ALPHAMODE, MATERIAL_ATTR_BRIGHT, MATERIAL_ATTR_COLOR_BLUE, MATERIAL_ATTR_COLOR_GREEN, MATERIAL_ATTR_COLOR_RED, MATERIAL_ATTR_GLOW, MATERIAL_ATTR_LEN, MATERIAL_ATTR_LIGHT, MATERIAL_ATTR_OBJECT, MATERIAL_ATTR_SHININESS, MATERIAL_ATTR_TRANSPARENT, MaterialParam::shininess, and MaterialParam::texture.
Referenced by jbxl::isSameMaterial().
|
inline |
Definition at line 232 of file MaterialParam.h.
References MaterialParam::bright.
Referenced by ColladaXML::addEffect().
|
inline |
Definition at line 209 of file MaterialParam.h.
References MaterialParam::bumpmap, and TextureParam::getName().
Referenced by ColladaXML::addPolylists().
|
inline |
|
inline |
|
inline |
Definition at line 231 of file MaterialParam.h.
References MaterialParam::glow.
Referenced by ColladaXML::addEffect(), and GLTFData::addMaterialParameters().
|
inline |
Definition at line 228 of file MaterialParam.h.
References MaterialParam::kind.
Referenced by GLTFData::addMaterialParameters().
|
inline |
char * getName | ( | void | ) |
Definition at line 256 of file MaterialParam.cpp.
References MaterialParam::bumpmap, TextureParam::getName(), TextureParam::isSetTexture(), MaterialParam::specmap, and MaterialParam::texture.
Referenced by MeshFacetNode::setMaterialID().
|
inline |
Definition at line 216 of file MaterialParam.h.
References Buffer::buf, and MaterialParam::paramstr.
Referenced by MeshObjectData::addData(), MeshObjectData::addData(), MeshObjectData::addData(), MaterialParam::dup(), and MeshObjectData::setMaterialParam().
|
inline |
Definition at line 230 of file MaterialParam.h.
References MaterialParam::shininess.
Referenced by ColladaXML::addEffect(), GLTFData::addMaterialParameters(), and OBJFacetMtlNode::setup_params().
|
inline |
Definition at line 235 of file MaterialParam.h.
References MaterialParam::speclightexp.
|
inline |
Definition at line 210 of file MaterialParam.h.
References TextureParam::getName(), and MaterialParam::specmap.
|
inline |
Definition at line 208 of file MaterialParam.h.
References TextureParam::getName(), and MaterialParam::texture.
Referenced by ColladaXML::addEffect(), and ColladaXML::addPolylists().
void init | ( | void | ) |
< 光沢
< 環境光
Definition at line 205 of file MaterialParam.cpp.
References MaterialParam::bright, MaterialParam::bumpmap, MaterialParam::enable, MaterialParam::environment, MaterialParam::glossiness, MaterialParam::glow, TextureParam::init(), init_Buffer(), MaterialParam::kind, MaterialParam::light, MaterialParam::mapping, MaterialParam::mflags, MaterialParam::others, MaterialParam::paramstr, MaterialParam::shininess, MaterialParam::specmap, and MaterialParam::texture.
Referenced by MaterialParam::clear(), MeshFacetNode::init(), and MaterialParam::MaterialParam().
|
inline |
Definition at line 198 of file MaterialParam.h.
References MaterialParam::bright.
Referenced by ColladaXML::addEffect().
|
inline |
Definition at line 191 of file MaterialParam.h.
References MaterialParam::bumpmap, and TextureParam::isSetTexture().
|
inline |
Definition at line 197 of file MaterialParam.h.
References MaterialParam::glow.
Referenced by ColladaXML::addEffect().
|
inline |
Definition at line 199 of file MaterialParam.h.
References MaterialParam::shininess.
Referenced by ColladaXML::addEffect().
|
inline |
Definition at line 192 of file MaterialParam.h.
References TextureParam::isSetTexture(), and MaterialParam::specmap.
|
inline |
Definition at line 190 of file MaterialParam.h.
References TextureParam::isSetTexture(), and MaterialParam::texture.
|
inline |
Definition at line 200 of file MaterialParam.h.
References TextureParam::getColor(), and MaterialParam::texture.
Referenced by MaterialParam::isTransparency().
|
inline |
Definition at line 202 of file MaterialParam.h.
References TextureParam::hasAlphaChannel(), MaterialParam::isSetTransparent(), and MaterialParam::texture.
Referenced by ColladaXML::addEffect().
void printParam | ( | FILE * | fp | ) |
Definition at line 314 of file MaterialParam.cpp.
References MaterialParam::bright, Buffer::buf, MaterialParam::bumpmap, MaterialParam::enable, MaterialParam::environment, MaterialParam::glossiness, MaterialParam::glow, TextureParam::isSetTexture(), MaterialParam::mapping, MaterialParam::mflags, MaterialParam::others, MaterialParam::paramstr, TextureParam::printParam(), MaterialParam::shininess, MaterialParam::specmap, and MaterialParam::texture.
Referenced by GLTFData::addMaterialParameters().
|
inline |
|
inline |
Definition at line 205 of file MaterialParam.h.
References MaterialParam::bumpmap, and TextureParam::setName().
|
inline |
void setFullName | ( | const char * | ext | ) |
ext | 拡張子 |
Definition at line 274 of file MaterialParam.cpp.
References TextureParam::addName(), MaterialParam::bumpmap, TextureParam::isSetTexture(), MaterialParam::specmap, and MaterialParam::texture.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Definition at line 214 of file MaterialParam.h.
References copy_s2Buffer, and MaterialParam::paramstr.
|
inline |
|
inline |
|
inline |
Definition at line 206 of file MaterialParam.h.
References TextureParam::setName(), and MaterialParam::specmap.
|
inline |
Definition at line 204 of file MaterialParam.h.
References TextureParam::setName(), and MaterialParam::texture.
|
private |
Definition at line 161 of file MaterialParam.h.
Referenced by MaterialParam::getBase64Params(), MaterialParam::getBright(), MaterialParam::init(), MaterialParam::isSetBright(), MaterialParam::printParam(), and MaterialParam::setBright().
TextureParam bumpmap |
Definition at line 177 of file MaterialParam.h.
Referenced by MaterialParam::dup(), MaterialParam::free(), MaterialParam::getBumpMapName(), MaterialParam::getName(), MaterialParam::init(), jbxl::isSameMaterial(), MaterialParam::isSetBumpMap(), MaterialParam::printParam(), MaterialParam::setBumpMapName(), MaterialParam::setFullName(), and OBJFacetMtlNode::setup_params().
bool enable |
Definition at line 169 of file MaterialParam.h.
Referenced by ColladaXML::addPolylists(), MaterialParam::init(), MaterialParam::printParam(), MeshFacetNode::setMaterialParam(), and MeshObjectData::setMaterialParam().
|
private |
Definition at line 165 of file MaterialParam.h.
Referenced by MaterialParam::getEnvironment(), MaterialParam::init(), MaterialParam::printParam(), and MaterialParam::setEnvironment().
|
private |
Definition at line 163 of file MaterialParam.h.
Referenced by MaterialParam::getGlossiness(), MaterialParam::init(), MaterialParam::printParam(), and MaterialParam::setGlossiness().
|
private |
Definition at line 160 of file MaterialParam.h.
Referenced by MaterialParam::getBase64Params(), MaterialParam::getGlow(), MaterialParam::init(), MaterialParam::isSetGlow(), MaterialParam::printParam(), and MaterialParam::setGlow().
|
private |
Definition at line 157 of file MaterialParam.h.
Referenced by MaterialParam::getBase64Params(), MaterialParam::getKind(), MaterialParam::init(), and MaterialParam::setKind().
|
private |
Definition at line 166 of file MaterialParam.h.
Referenced by MaterialParam::getBase64Params(), MaterialParam::getLight(), MaterialParam::init(), and MaterialParam::setLight().
int mapping |
Definition at line 171 of file MaterialParam.h.
Referenced by FBXData::addShell(), OBJData::addShell(), ColladaXML::addTexcrdSource(), GLTFData::execAffineUVMap(), MaterialParam::init(), and MaterialParam::printParam().
int mflags |
Definition at line 172 of file MaterialParam.h.
Referenced by MaterialParam::init(), and MaterialParam::printParam().
int others |
Definition at line 173 of file MaterialParam.h.
Referenced by MaterialParam::init(), and MaterialParam::printParam().
|
private |
Definition at line 155 of file MaterialParam.h.
Referenced by MaterialParam::addParamString(), MaterialParam::dup(), MaterialParam::free(), MaterialParam::getParamString(), MaterialParam::init(), MaterialParam::printParam(), and MaterialParam::setParamString().
|
private |
Definition at line 159 of file MaterialParam.h.
Referenced by MaterialParam::getBase64Params(), MaterialParam::getShininess(), MaterialParam::init(), MaterialParam::isSetShininess(), MaterialParam::printParam(), and MaterialParam::setShininess().
|
private |
Definition at line 164 of file MaterialParam.h.
Referenced by MaterialParam::getSpecExp(), and MaterialParam::setSpecExp().
TextureParam specmap |
Definition at line 176 of file MaterialParam.h.
Referenced by ColladaXML::addEffect(), MaterialParam::dup(), MaterialParam::free(), MaterialParam::getName(), MaterialParam::getSpecMapName(), MaterialParam::init(), jbxl::isSameMaterial(), MaterialParam::isSetSpecMap(), MaterialParam::printParam(), MaterialParam::setFullName(), MaterialParam::setSpecMapName(), and OBJFacetMtlNode::setup_params().
TextureParam texture |
Definition at line 175 of file MaterialParam.h.
Referenced by ColladaXML::addEffect(), GLTFData::addMaterialParameters(), GLTFData::addMaterials(), GLTFData::addTextures(), MaterialParam::dup(), MeshFacetNode::execAffineTransUVMap(), MaterialParam::free(), MaterialParam::getBase64Params(), MaterialParam::getName(), MaterialParam::getTextureName(), MaterialParam::init(), jbxl::isSameMaterial(), MaterialParam::isSetTexture(), MaterialParam::isSetTransparent(), MaterialParam::isTransparency(), MaterialParam::printParam(), MaterialParam::setFullName(), MaterialParam::setTextureName(), and OBJFacetMtlNode::setup_params().