- extract MaterialHelper and move all of its members to aiMaterial in /include.

- pull in IOhannes' patch to set the gcc default visibility for all symbols to NO and to mark ASSIMP_API with __attribute__ ((visibility("default"))).
- drop unneeded ASSIMP_API from most internal classes in /code, we just need to keep some exports on Windows to keep AssimpView alive.

git-svn-id: https://assimp.svn.sourceforge.net/svnroot/assimp/trunk@1066 67173fc5-114c-0410-ac8e-9d2fd5bffc1f
This commit is contained in:
aramis_acg
2011-08-22 20:22:51 +00:00
parent 9f32504792
commit 9d85c8834d
111 changed files with 1867 additions and 1935 deletions

View File

@@ -170,7 +170,7 @@ void IRRImporter::BuildSkybox(std::vector<aiMesh*>& meshes, std::vector<aiMateri
{
// Update the material of the skybox - replace the name and disable shading for skyboxes.
for (unsigned int i = 0; i < 6;++i) {
MaterialHelper* out = ( MaterialHelper* ) (*(materials.end()-(6-i)));
aiMaterial* out = ( aiMaterial* ) (*(materials.end()-(6-i)));
aiString s;
s.length = ::sprintf( s.data, "SkyboxSide_%i",i );
@@ -246,7 +246,7 @@ void IRRImporter::CopyMaterial(std::vector<aiMaterial*>& materials,
if (UINT_MAX == defMatIdx)
{
defMatIdx = (unsigned int)materials.size();
MaterialHelper* mat = new MaterialHelper();
aiMaterial* mat = new aiMaterial();
aiString s;
s.Set(AI_DEFAULT_MATERIAL_NAME);
@@ -564,7 +564,7 @@ void IRRImporter::ComputeAnimations(Node* root, aiNode* real, std::vector<aiNode
// ------------------------------------------------------------------------------------------------
// This function is maybe more generic than we'd need it here
void SetupMapping (MaterialHelper* mat, aiTextureMapping mode, const aiVector3D& axis = aiVector3D(0.f,0.f,-1.f))
void SetupMapping (aiMaterial* mat, aiTextureMapping mode, const aiVector3D& axis = aiVector3D(0.f,0.f,-1.f))
{
// Check whether there are texture properties defined - setup
// the desired texture mapping mode for all of them and ignore
@@ -687,7 +687,7 @@ void IRRImporter::GenerateGraph(Node* root,aiNode* rootOut ,aiScene* scene,
// often the case so we can simply extract it to a shared oacity
// value.
std::pair<aiMaterial*, unsigned int>& src = root->materials[mesh->mMaterialIndex];
MaterialHelper* mat = (MaterialHelper*)src.first;
aiMaterial* mat = (aiMaterial*)src.first;
if (mesh->HasVertexColors(0) && src.second & AI_IRRMESH_MAT_trans_vertex_alpha)
{
@@ -757,7 +757,7 @@ void IRRImporter::GenerateGraph(Node* root,aiNode* rootOut ,aiScene* scene,
// Now adjust this output material - if there is a first texture
// set, setup spherical UV mapping around the Y axis.
SetupMapping ( (MaterialHelper*) materials.back(), aiTextureMapping_SPHERE);
SetupMapping ( (aiMaterial*) materials.back(), aiTextureMapping_SPHERE);
}
break;
@@ -775,7 +775,7 @@ void IRRImporter::GenerateGraph(Node* root,aiNode* rootOut ,aiScene* scene,
// Now adjust this output material - if there is a first texture
// set, setup cubic UV mapping
SetupMapping ( (MaterialHelper*) materials.back(), aiTextureMapping_BOX );
SetupMapping ( (aiMaterial*) materials.back(), aiTextureMapping_BOX );
}
break;