- Major update to the viewer. A little bit buggy now, but I'll fix that

- 2/3 of the viewer code are no wrapped in helper classes
- ByteSwap.h header added 
- Bugfix in the 3DS loader: Texture blend mode was read incorrectly
- Bugfix in the X-Loader. Assets with specular_exp == 0 use gouraud lighting now
- Added new helper functions to MaterialHelper 
- Added aiMaterialGetTexture() function to allow easy access to all properties of a texture

git-svn-id: https://assimp.svn.sourceforge.net/svnroot/assimp/trunk@16 67173fc5-114c-0410-ac8e-9d2fd5bffc1f
This commit is contained in:
aramis_acg
2008-05-13 23:26:52 +00:00
parent 7144737824
commit 2eb6fca408
60 changed files with 7502 additions and 2613 deletions

View File

@@ -41,6 +41,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
/** @file Implementation of the post processing step tokill mesh normals
*/
#include "KillNormalsProcess.h"
#include "DefaultLogger.h"
#include "../include/aiPostProcess.h"
#include "../include/aiMesh.h"
#include "../include/aiScene.h"
@@ -69,15 +70,25 @@ bool KillNormalsProcess::IsActive( unsigned int pFlags) const
// Executes the post processing step on the given imported data.
void KillNormalsProcess::Execute( aiScene* pScene)
{
DefaultLogger::get()->debug("KillNormalsProcess begin");
bool bHas = false;
for( unsigned int a = 0; a < pScene->mNumMeshes; a++)
this->KillMeshNormals( pScene->mMeshes[a]);
{
if( this->KillMeshNormals( pScene->mMeshes[a]))
bHas = true;
}
if (bHas)DefaultLogger::get()->info("KillNormalsProcess finished. Found normals to kill");
else DefaultLogger::get()->debug("KillNormalsProcess finished. There was nothing to do.");
}
// -------------------------------------------------------------------
// Executes the post processing step on the given imported data.
void KillNormalsProcess::KillMeshNormals(aiMesh* pMesh)
bool KillNormalsProcess::KillMeshNormals(aiMesh* pMesh)
{
if (!pMesh->mNormals)return false;
delete[] pMesh->mNormals;
pMesh->mNormals = NULL;
return;
return true;
}