Merge branch 'master' of git://github.com/assimp/assimp

pull/14/head
Alexander Gessler 2012-12-21 16:24:05 +01:00
commit bae9db2f03
179 changed files with 20711 additions and 7693 deletions

View File

@ -82,7 +82,7 @@ ELSE ( ASSIMP_ENABLE_BOOST_WORKAROUND )
MESSAGE( FATAL_ERROR
"Boost libraries (http://www.boost.org/) not found. "
"You can build a non-boost version of Assimp with slightly reduced "
"functionality by specifying -DENABLE_BOOST_WORKAROUND=ON."
"functionality by specifying -DASSIMP_ENABLE_BOOST_WORKAROUND=ON."
)
ENDIF ( NOT Boost_FOUND )

View File

@ -135,4 +135,10 @@ Several LWO and LWS fixes (pivoting).
GCC/Linux fixes for the SimpleOpenGL sample.
- Brian Miller
Bugfix for a compiler fix for iOS on arm.
Bugfix for a compiler fix for iOS on arm.
- Séverin Lemaignan
Rewrite of PyAssimp, distutils and Python3 support
- albert-wang
Bugfixes for the collada parser

View File

@ -44,6 +44,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "AssimpPCH.h"
#ifndef ASSIMP_BUILD_NO_ASE_IMPORTER
// internal headers
#include "TextureTransform.h"
@ -2148,3 +2149,5 @@ void Parser::ParseLV4MeshLong(unsigned int& iOut)
// parse the value
iOut = strtoul10(filePtr,&filePtr);
}
#endif // !! ASSIMP_BUILD_NO_BASE_IMPORTER

View File

@ -514,7 +514,8 @@ void ColladaLoader::BuildMeshesForNode( const ColladaParser& pParser, const Coll
// assign the material index
dstMesh->mMaterialIndex = matIdx;
}
dstMesh->mName = mid.mMeshOrController;
}
}
}

View File

@ -1369,9 +1369,11 @@ void ColladaParser::ReadEffectColor( aiColor4D& pColor, Sampler& pSampler)
int attrTex = GetAttribute( "texture");
pSampler.mName = mReader->getAttributeValue( attrTex);
// get name of UV source channel
attrTex = GetAttribute( "texcoord");
pSampler.mUVChannel = mReader->getAttributeValue( attrTex);
// get name of UV source channel. Specification demands it to be there, but some exporters
// don't write it. It will be the default UV channel in case it's missing.
attrTex = TestAttribute( "texcoord");
if( attrTex >= 0 )
pSampler.mUVChannel = mReader->getAttributeValue( attrTex);
//SkipElement();
}
else if( IsElement( "technique"))
@ -1795,14 +1797,13 @@ void ColladaParser::ReadAccessor( const std::string& pID)
SkipElement();
} else
{
ThrowException( "Unexpected sub element in tag \"accessor\".");
ThrowException( boost::str( boost::format( "Unexpected sub element <%s> in tag <accessor>") % mReader->getNodeName()));
}
}
else if( mReader->getNodeType() == irr::io::EXN_ELEMENT_END)
{
if( strcmp( mReader->getNodeName(), "accessor") != 0)
ThrowException( "Expected end of \"accessor\" element.");
ThrowException( "Expected end of <accessor> element.");
break;
}
}
@ -1826,13 +1827,13 @@ void ColladaParser::ReadVertexData( Mesh* pMesh)
ReadInputChannel( pMesh->mPerVertexData);
} else
{
ThrowException( "Unexpected sub element in tag \"vertices\".");
ThrowException( boost::str( boost::format( "Unexpected sub element <%s> in tag <vertices>") % mReader->getNodeName()));
}
}
else if( mReader->getNodeType() == irr::io::EXN_ELEMENT_END)
{
if( strcmp( mReader->getNodeName(), "vertices") != 0)
ThrowException( "Expected end of \"vertices\" element.");
ThrowException( "Expected end of <vertices> element.");
break;
}
@ -1919,13 +1920,13 @@ void ColladaParser::ReadIndexData( Mesh* pMesh)
}
} else
{
ThrowException( "Unexpected sub element in tag \"vertices\".");
ThrowException( boost::str( boost::format( "Unexpected sub element <%s> in tag <%s>") % mReader->getNodeName() % elementName));
}
}
else if( mReader->getNodeType() == irr::io::EXN_ELEMENT_END)
{
if( mReader->getNodeName() != elementName)
ThrowException( boost::str( boost::format( "Expected end of \"%s\" element.") % elementName));
ThrowException( boost::str( boost::format( "Expected end of <%s> element.") % elementName));
break;
}
@ -2063,7 +2064,7 @@ void ColladaParser::ReadPrimitives( Mesh* pMesh, std::vector<InputChannel>& pPer
{
// warn if the vertex channel does not refer to the <vertices> element in the same mesh
if( input.mAccessor != pMesh->mVertexID)
ThrowException( "Unsupported vertex referencing scheme. I fucking hate Collada.");
ThrowException( "Unsupported vertex referencing scheme.");
continue;
}
@ -2230,7 +2231,13 @@ void ColladaParser::ExtractDataObjectFromChannel( const InputChannel& pInput, si
pMesh->mColors[pInput.mIndex].insert( pMesh->mColors[pInput.mIndex].end(),
pMesh->mPositions.size() - pMesh->mColors[pInput.mIndex].size() - 1, aiColor4D( 0, 0, 0, 1));
pMesh->mColors[pInput.mIndex].push_back( aiColor4D( obj[0], obj[1], obj[2], obj[3]));
//pMesh->mColors[pInput.mIndex].push_back( aiColor4D( obj[0], obj[1], obj[2], obj[3]));
aiColor4D result(0, 0, 0, 1);
for (size_t i = 0; i < pInput.mResolved->mSize; ++i)
{
result[i] = obj[pInput.mResolved->mSubOffset[i]];
}
pMesh->mColors[pInput.mIndex].push_back(result);
} else
{
DefaultLogger::get()->error("Collada: too many vertex color sets. Skipping.");

File diff suppressed because it is too large Load Diff

View File

@ -45,7 +45,9 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "AssimpPCH.h"
#ifndef ASSIMP_BUILD_NO_IFC_IMPORTER
#include "IFCUtil.h"
#include "PolyTools.h"
#include "ProcessHelper.h"
namespace Assimp {
@ -127,6 +129,122 @@ void TempMesh::Append(const TempMesh& other)
vertcnt.insert(vertcnt.end(),other.vertcnt.begin(),other.vertcnt.end());
}
// ------------------------------------------------------------------------------------------------
void TempMesh::RemoveDegenerates()
{
// The strategy is simple: walk the mesh and compute normals using
// Newell's algorithm. The length of the normals gives the area
// of the polygons, which is close to zero for lines.
std::vector<IfcVector3> normals;
ComputePolygonNormals(normals, false);
bool drop = false;
size_t inor = 0;
std::vector<IfcVector3>::iterator vit = verts.begin();
for (std::vector<unsigned int>::iterator it = vertcnt.begin(); it != vertcnt.end(); ++inor) {
const unsigned int pcount = *it;
if (normals[inor].SquareLength() < 1e-5f) {
it = vertcnt.erase(it);
vit = verts.erase(vit, vit + pcount);
drop = true;
continue;
}
vit += pcount;
++it;
}
if(drop) {
IFCImporter::LogDebug("removing degenerate faces");
}
}
// ------------------------------------------------------------------------------------------------
void TempMesh::ComputePolygonNormals(std::vector<IfcVector3>& normals,
bool normalize,
size_t ofs) const
{
size_t max_vcount = 0;
std::vector<unsigned int>::const_iterator begin = vertcnt.begin()+ofs, end = vertcnt.end(), iit;
for(iit = begin; iit != end; ++iit) {
max_vcount = std::max(max_vcount,static_cast<size_t>(*iit));
}
std::vector<IfcFloat> temp((max_vcount+2)*4);
normals.reserve( normals.size() + vertcnt.size()-ofs );
// `NewellNormal()` currently has a relatively strange interface and need to
// re-structure things a bit to meet them.
size_t vidx = std::accumulate(vertcnt.begin(),begin,0);
for(iit = begin; iit != end; vidx += *iit++) {
if (!*iit) {
normals.push_back(IfcVector3());
continue;
}
for(size_t vofs = 0, cnt = 0; vofs < *iit; ++vofs) {
const IfcVector3& v = verts[vidx+vofs];
temp[cnt++] = v.x;
temp[cnt++] = v.y;
temp[cnt++] = v.z;
#ifdef _DEBUG
temp[cnt] = std::numeric_limits<IfcFloat>::quiet_NaN();
#endif
++cnt;
}
normals.push_back(IfcVector3());
NewellNormal<4,4,4>(normals.back(),*iit,&temp[0],&temp[1],&temp[2]);
}
if(normalize) {
BOOST_FOREACH(IfcVector3& n, normals) {
n.Normalize();
}
}
}
// ------------------------------------------------------------------------------------------------
// Compute the normal of the last polygon in the given mesh
IfcVector3 TempMesh::ComputeLastPolygonNormal(bool normalize) const
{
size_t total = vertcnt.back(), vidx = verts.size() - total;
std::vector<IfcFloat> temp((total+2)*3);
for(size_t vofs = 0, cnt = 0; vofs < total; ++vofs) {
const IfcVector3& v = verts[vidx+vofs];
temp[cnt++] = v.x;
temp[cnt++] = v.y;
temp[cnt++] = v.z;
}
IfcVector3 nor;
NewellNormal<3,3,3>(nor,total,&temp[0],&temp[1],&temp[2]);
return normalize ? nor.Normalize() : nor;
}
// ------------------------------------------------------------------------------------------------
void TempMesh::FixupFaceOrientation()
{
const IfcVector3 vavg = Center();
std::vector<IfcVector3> normals;
ComputePolygonNormals(normals);
size_t c = 0, ofs = 0;
BOOST_FOREACH(unsigned int cnt, vertcnt) {
if (cnt>2){
const IfcVector3& thisvert = verts[c];
if (normals[ofs]*(thisvert-vavg) < 0) {
std::reverse(verts.begin()+c,verts.begin()+cnt+c);
}
}
c += cnt;
++ofs;
}
}
// ------------------------------------------------------------------------------------------------
void TempMesh::RemoveAdjacentDuplicates()
{
@ -189,7 +307,7 @@ void TempMesh::RemoveAdjacentDuplicates()
base += cnt;
}
if(drop) {
IFCImporter::LogDebug("removed duplicate vertices");
IFCImporter::LogDebug("removing duplicate vertices");
}
}

View File

@ -76,12 +76,27 @@ struct delete_fun
struct TempMesh;
struct TempOpening
{
const IFC::IfcExtrudedAreaSolid* solid;
const IFC::IfcSolidModel* solid;
IfcVector3 extrusionDir;
boost::shared_ptr<TempMesh> profileMesh;
// list of points generated for this opening. This is used to
// create connections between two opposing holes created
// from a single opening instance (two because walls tend to
// have two sides). If !empty(), the other side of the wall
// has already been processed.
std::vector<IfcVector3> wallPoints;
// ------------------------------------------------------------------------------
TempOpening(const IFC::IfcExtrudedAreaSolid* solid,IfcVector3 extrusionDir,boost::shared_ptr<TempMesh> profileMesh)
TempOpening()
: solid()
, extrusionDir()
, profileMesh()
{
}
// ------------------------------------------------------------------------------
TempOpening(const IFC::IfcSolidModel* solid,IfcVector3 extrusionDir,boost::shared_ptr<TempMesh> profileMesh)
: solid(solid)
, extrusionDir(extrusionDir)
, profileMesh(profileMesh)
@ -168,7 +183,19 @@ struct TempMesh
void Transform(const IfcMatrix4& mat);
IfcVector3 Center() const;
void Append(const TempMesh& other);
bool IsEmpty() const {
return verts.empty() && vertcnt.empty();
}
void RemoveAdjacentDuplicates();
void RemoveDegenerates();
void FixupFaceOrientation();
IfcVector3 ComputeLastPolygonNormal(bool normalize = true) const;
void ComputePolygonNormals(std::vector<IfcVector3>& normals,
bool normalize = true,
size_t ofs = 0) const;
};

View File

@ -45,6 +45,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "AssimpPCH.h"
#ifndef ASSIMP_BUILD_NO_IRR_IMPORTER
#include "IRRLoader.h"
#include "ParsingUtils.h"
#include "fast_atof.h"
@ -1471,3 +1473,5 @@ void IRRImporter::InternReadFile( const std::string& pFile,
*/
return;
}
#endif // !! ASSIMP_BUILD_NO_IRR_IMPORTER

View File

@ -43,6 +43,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "AssimpPCH.h"
#ifndef ASSIMP_BUILD_NO_IRR_IMPORTER
#include "IRRMeshLoader.h"
#include "ParsingUtils.h"
#include "fast_atof.h"
@ -509,3 +511,5 @@ void IRRMeshImporter::InternReadFile( const std::string& pFile,
delete reader;
AI_DEBUG_INVALIDATE_PTR(reader);
}
#endif // !! ASSIMP_BUILD_NO_IRR_IMPORTER

View File

@ -45,6 +45,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "AssimpPCH.h"
#ifndef ASSIMP_BUILD_NO_IRR_IMPORTER
#include "IRRShared.h"
#include "ParsingUtils.h"
#include "fast_atof.h"
@ -494,3 +496,5 @@ aiMaterial* IrrlichtBase::ParseMaterial(unsigned int& matFlags)
DefaultLogger::get()->error("IRRMESH: Unexpected end of file. Material is not complete");
return mat;
}
#endif // !! ASSIMP_BUILD_NO_IRR_IMPORTER

View File

@ -44,6 +44,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "AssimpPCH.h"
#ifndef ASSIMP_BUILD_NO_LWS_IMPORTER
#include "LWSLoader.h"
#include "ParsingUtils.h"
@ -918,3 +919,5 @@ void LWSImporter::InternReadFile( const std::string& pFile, aiScene* pScene,
}
}
#endif // !! ASSIMP_BUILD_NO_LWS_IMPORTER

View File

@ -310,7 +310,7 @@ struct Model
m_Groups.clear();
for ( std::map<std::string, Material*>::iterator it = m_MaterialMap.begin(); it != m_MaterialMap.end(); ++it ) {
// delete it->second;
delete it->second;
}
}
};

View File

@ -100,7 +100,7 @@ void OgreImporter::InternReadFile(const std::string &pFile, aiScene *pScene, Ass
//Read the Mesh File:
boost::scoped_ptr<CIrrXML_IOStreamReader> mIOWrapper( new CIrrXML_IOStreamReader( file.get()));
XmlReader* MeshFile = irr::io::createIrrXMLReader(mIOWrapper.get());
boost::scoped_ptr<XmlReader> MeshFile(irr::io::createIrrXMLReader(mIOWrapper.get()));
if(!MeshFile)//parse the xml file
throw DeadlyImportError("Failed to create XML Reader for "+pFile);
@ -108,21 +108,21 @@ void OgreImporter::InternReadFile(const std::string &pFile, aiScene *pScene, Ass
DefaultLogger::get()->debug("Mesh File opened");
//Read root Node:
if(!(XmlRead(MeshFile) && string(MeshFile->getNodeName())=="mesh"))
if(!(XmlRead(MeshFile.get()) && string(MeshFile->getNodeName())=="mesh"))
{
throw DeadlyImportError("Root Node is not <mesh>! "+pFile+" "+MeshFile->getNodeName());
}
//eventually load shared geometry
XmlRead(MeshFile);//shared geometry is optional, so we need a reed for the next two if's
XmlRead(MeshFile.get());//shared geometry is optional, so we need a reed for the next two if's
if(MeshFile->getNodeName()==string("sharedgeometry"))
{
unsigned int NumVertices=GetAttribute<int>(MeshFile, "vertexcount");;
unsigned int NumVertices=GetAttribute<int>(MeshFile.get(), "vertexcount");;
XmlRead(MeshFile);
XmlRead(MeshFile.get());
while(MeshFile->getNodeName()==string("vertexbuffer"))
{
ReadVertexBuffer(m_SharedGeometry, MeshFile, NumVertices);
ReadVertexBuffer(m_SharedGeometry, MeshFile.get(), NumVertices);
}
}
@ -136,13 +136,13 @@ void OgreImporter::InternReadFile(const std::string &pFile, aiScene *pScene, Ass
//-------------------Read the submeshs and materials:-----------------------
std::list<boost::shared_ptr<SubMesh> > SubMeshes;
vector<aiMaterial*> Materials;
XmlRead(MeshFile);
XmlRead(MeshFile.get());
while(MeshFile->getNodeName()==string("submesh"))
{
SubMesh* theSubMesh=new SubMesh();
theSubMesh->MaterialName=GetAttribute<string>(MeshFile, "material");
theSubMesh->MaterialName=GetAttribute<string>(MeshFile.get(), "material");
DefaultLogger::get()->debug("Loading Submehs with Material: "+theSubMesh->MaterialName);
ReadSubMesh(*theSubMesh, MeshFile);
ReadSubMesh(*theSubMesh, MeshFile.get());
//just a index in a array, we add a mesh in each loop cycle, so we get indicies like 0, 1, 2 ... n;
//so it is important to do this before pushing the mesh in the vector!
@ -170,9 +170,9 @@ void OgreImporter::InternReadFile(const std::string &pFile, aiScene *pScene, Ass
vector<Animation> Animations;
if(MeshFile->getNodeName()==string("skeletonlink"))
{
string SkeletonFile=GetAttribute<string>(MeshFile, "name");
string SkeletonFile=GetAttribute<string>(MeshFile.get(), "name");
LoadSkeleton(SkeletonFile, Bones, Animations);
XmlRead(MeshFile);
XmlRead(MeshFile.get());
}
else
{
@ -185,7 +185,7 @@ void OgreImporter::InternReadFile(const std::string &pFile, aiScene *pScene, Ass
//now there might be boneassignments for the shared geometry:
if(MeshFile->getNodeName()==string("boneassignments"))
{
ReadBoneWeights(m_SharedGeometry, MeshFile);
ReadBoneWeights(m_SharedGeometry, MeshFile.get());
}

View File

@ -148,12 +148,22 @@ aiMaterial* OgreImporter::LoadMaterial(const std::string MaterialName) const
}
}
}
//Fill the stream
boost::scoped_ptr<IOStream> MaterialFile(MatFilePtr);
vector<char> FileData(MaterialFile->FileSize());
MaterialFile->Read(&FileData[0], MaterialFile->FileSize(), 1);
BaseImporter::ConvertToUTF8(FileData);
if(MaterialFile->FileSize()>0)
{
vector<char> FileData(MaterialFile->FileSize());
MaterialFile->Read(&FileData[0], MaterialFile->FileSize(), 1);
BaseImporter::ConvertToUTF8(FileData);
ss << &FileData[0];
FileData.push_back('\0');//terminate the string with zero, so that the ss can parse it correctly
ss << &FileData[0];
}
else
{
DefaultLogger::get()->warn("Material " + MaterialName + " seams to be empty");
return NULL;
}
}
//create the material

View File

@ -640,6 +640,7 @@ bool Q3BSPFileImporter::importTextureFromArchive( const Q3BSP::Q3BSPModel *pMode
std::vector<std::string> supportedExtensions;
supportedExtensions.push_back( ".jpg" );
supportedExtensions.push_back( ".png" );
supportedExtensions.push_back( ".tga" );
if ( NULL == pArchive || NULL == pArchive || NULL == pMatHelper )
{
return false;
@ -670,10 +671,10 @@ bool Q3BSPFileImporter::importTextureFromArchive( const Q3BSP::Q3BSPModel *pMode
(void)readSize;
ai_assert( readSize == pTexture->mWidth );
pTexture->pcData = reinterpret_cast<aiTexel*>( pData );
pTexture->achFormatHint[ 0 ] = ext[ 0 ];
pTexture->achFormatHint[ 1 ] = ext[ 1 ];
pTexture->achFormatHint[ 2 ] = ext[ 2 ];
pTexture->achFormatHint[ 2 ] = '\0';
pTexture->achFormatHint[ 0 ] = ext[ 1 ];
pTexture->achFormatHint[ 1 ] = ext[ 2 ];
pTexture->achFormatHint[ 2 ] = ext[ 3 ];
pTexture->achFormatHint[ 3 ] = '\0';
res = true;
aiString name;

View File

@ -38,6 +38,9 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
----------------------------------------------------------------------
*/
#include "AssimpPCH.h"
#ifndef ASSIMP_BUILD_NO_Q3BSP_IMPORTER
#include "Q3BSPFileParser.h"
#include "DefaultIOSystem.h"
#include "Q3BSPFileData.h"
@ -273,3 +276,5 @@ void Q3BSPFileParser::getEntities()
// ------------------------------------------------------------------------------------------------
} // Namespace Assimp
#endif // ASSIMP_BUILD_NO_Q3BSP_IMPORTER

View File

@ -39,6 +39,9 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "AssimpPCH.h"
#ifndef ASSIMP_BUILD_NO_Q3BSP_IMPORTER
#include "Q3BSPZipArchive.h"
#include <algorithm>
#include <cassert>
@ -194,3 +197,5 @@ bool Q3BSPZipArchive::mapArchive()
} // Namespace Q3BSP
} // Namespace Assimp
#endif // ASSIMP_BUILD_NO_Q3BSP_IMPORTER

View File

@ -684,7 +684,7 @@ void SMDImporter::ParseFile()
const char* szCurrent = mBuffer;
// read line per line ...
while (true)
for ( ;; )
{
if(!SkipSpacesAndLineEnd(szCurrent,&szCurrent)) break;
@ -750,7 +750,7 @@ unsigned int SMDImporter::GetTextureIndex(const std::string& filename)
void SMDImporter::ParseNodesSection(const char* szCurrent,
const char** szCurrentOut)
{
while (true)
for ( ;; )
{
// "end\n" - Ends the nodes section
if (0 == ASSIMP_strincmp(szCurrent,"end",3) &&
@ -772,7 +772,7 @@ void SMDImporter::ParseTrianglesSection(const char* szCurrent,
{
// Parse a triangle, parse another triangle, parse the next triangle ...
// and so on until we reach a token that looks quite similar to "end"
while (true)
for ( ;; )
{
if(!SkipSpacesAndLineEnd(szCurrent,&szCurrent)) break;
@ -790,7 +790,7 @@ void SMDImporter::ParseVASection(const char* szCurrent,
const char** szCurrentOut)
{
unsigned int iCurIndex = 0;
while (true)
for ( ;; )
{
if(!SkipSpacesAndLineEnd(szCurrent,&szCurrent)) break;
@ -833,7 +833,7 @@ void SMDImporter::ParseSkeletonSection(const char* szCurrent,
const char** szCurrentOut)
{
int iTime = 0;
while (true)
for ( ;; )
{
if(!SkipSpacesAndLineEnd(szCurrent,&szCurrent)) break;
@ -887,7 +887,7 @@ void SMDImporter::ParseNodeInfo(const char* szCurrent,
else ++szCurrent;
const char* szEnd = szCurrent;
while (true)
for ( ;; )
{
if (bQuota && '\"' == *szEnd)
{

View File

@ -192,19 +192,19 @@ namespace STEP {
}
// utilities to deal with SELECT entities, which currently lack automatic
// conversion support.
template <typename T>
const T& ResolveSelect(const DB& db) const {
return Couple<T>(db).MustGetObject(To<EXPRESS::ENTITY>())->To<T>();
}
template <typename T>
const T* ResolveSelectPtr(const DB& db) const {
const EXPRESS::ENTITY* e = ToPtr<EXPRESS::ENTITY>();
return e?Couple<T>(db).MustGetObject(*e)->ToPtr<T>():(const T*)0;
}
public:
// conversion support.
template <typename T>
const T& ResolveSelect(const DB& db) const {
return Couple<T>(db).MustGetObject(To<EXPRESS::ENTITY>())->template To<T>();
}
template <typename T>
const T* ResolveSelectPtr(const DB& db) const {
const EXPRESS::ENTITY* e = ToPtr<EXPRESS::ENTITY>();
return e?Couple<T>(db).MustGetObject(*e)->template ToPtr<T>():(const T*)0;
}
public:
/** parse a variable from a string and set 'inout' to the character
* behind the last consumed character. An optional schema enables,

View File

@ -160,6 +160,30 @@ STEP::DB* STEP::ReadFileHeader(boost::shared_ptr<IOStream> stream)
}
namespace {
// ------------------------------------------------------------------------------------------------
// check whether the given line contains an entity definition (i.e. starts with "#<number>=")
bool IsEntityDef(const std::string& snext)
{
if (snext[0] == '#') {
// it is only a new entity if it has a '=' after the
// entity ID.
for(std::string::const_iterator it = snext.begin()+1; it != snext.end(); ++it) {
if (*it == '=') {
return true;
}
if (*it < '0' || *it > '9') {
break;
}
}
}
return false;
}
}
// ------------------------------------------------------------------------------------------------
void STEP::ReadFile(DB& db,const EXPRESS::ConversionSchema& scheme,
const char* const* types_to_track, size_t len,
@ -171,8 +195,9 @@ void STEP::ReadFile(DB& db,const EXPRESS::ConversionSchema& scheme,
const DB::ObjectMap& map = db.GetObjects();
LineSplitter& splitter = db.GetSplitter();
for(; splitter; ++splitter) {
const std::string& s = *splitter;
while (splitter) {
bool has_next = false;
std::string s = *splitter;
if (s == "ENDSEC;") {
break;
}
@ -184,6 +209,7 @@ void STEP::ReadFile(DB& db,const EXPRESS::ConversionSchema& scheme,
ai_assert(s.length());
if (s[0] != '#') {
DefaultLogger::get()->warn(AddLineNumber("expected token \'#\'",line));
++splitter;
continue;
}
@ -195,25 +221,75 @@ void STEP::ReadFile(DB& db,const EXPRESS::ConversionSchema& scheme,
const std::string::size_type n0 = s.find_first_of('=');
if (n0 == std::string::npos) {
DefaultLogger::get()->warn(AddLineNumber("expected token \'=\'",line));
++splitter;
continue;
}
const uint64_t id = strtoul10_64(s.substr(1,n0-1).c_str());
if (!id) {
DefaultLogger::get()->warn(AddLineNumber("expected positive, numeric entity id",line));
++splitter;
continue;
}
const std::string::size_type n1 = s.find_first_of('(',n0);
std::string::size_type n1 = s.find_first_of('(',n0);
if (n1 == std::string::npos) {
DefaultLogger::get()->warn(AddLineNumber("expected token \'(\'",line));
continue;
has_next = true;
bool ok = false;
for( ++splitter; splitter; ++splitter) {
const std::string& snext = *splitter;
if (snext.empty()) {
continue;
}
// the next line doesn't start an entity, so maybe it is
// just a continuation for this line, keep going
if (!IsEntityDef(snext)) {
s.append(snext);
n1 = s.find_first_of('(',n0);
ok = (n1 != std::string::npos);
}
else {
break;
}
}
if(!ok) {
DefaultLogger::get()->warn(AddLineNumber("expected token \'(\'",line));
continue;
}
}
const std::string::size_type n2 = s.find_last_of(')');
if (n2 == std::string::npos || n2 < n1) {
DefaultLogger::get()->warn(AddLineNumber("expected token \')\'",line));
continue;
std::string::size_type n2 = s.find_last_of(')');
if (n2 == std::string::npos || n2 < n1 || n2 == s.length() - 1 || s[n2 + 1] != ';') {
has_next = true;
bool ok = false;
for( ++splitter; splitter; ++splitter) {
const std::string& snext = *splitter;
if (snext.empty()) {
continue;
}
// the next line doesn't start an entity, so maybe it is
// just a continuation for this line, keep going
if (!IsEntityDef(snext)) {
s.append(snext);
n2 = s.find_last_of(')');
ok = !(n2 == std::string::npos || n2 < n1 || n2 == s.length() - 1 || s[n2 + 1] != ';');
}
else {
break;
}
}
if(!ok) {
DefaultLogger::get()->warn(AddLineNumber("expected token \')\'",line));
continue;
}
}
if (map.find(id) != map.end()) {
@ -239,6 +315,10 @@ void STEP::ReadFile(DB& db,const EXPRESS::ConversionSchema& scheme,
db.InternInsert(new LazyObject(db,id,line,sz,copysz));
}
if(!has_next) {
++splitter;
}
}
if (!splitter) {

View File

@ -203,7 +203,7 @@ void STLImporter::LoadASCIIFile()
pMesh->mNormals = new aiVector3D[pMesh->mNumVertices];
unsigned int curFace = 0, curVertex = 3;
while (true)
for ( ;; )
{
// go to the next token
if(!SkipSpacesAndLineEnd(&sz))

View File

@ -87,7 +87,7 @@ inline unsigned int ASSIMP_itoa10( char* out, unsigned int max, int32_t number)
// print all future zeroes from now
mustPrint = true;
*out++ = '0'+digit;
*out++ = '0'+static_cast<char>(digit);
++written;
number -= digit*cur;

View File

@ -188,6 +188,8 @@ bool TriangulateProcess::TriangulateMesh( aiMesh* pMesh)
FILE* fout = fopen(POLY_OUTPUT_FILE,"a");
#endif
const aiVector3D* verts = pMesh->mVertices;
// use boost::scoped_array to avoid slow std::vector<bool> specialiations
boost::scoped_array<bool> done(new bool[max_out]);
for( unsigned int a = 0; a < pMesh->mNumFaces; a++) {
@ -216,24 +218,59 @@ bool TriangulateProcess::TriangulateMesh( aiMesh* pMesh)
face.mIndices = NULL;
continue;
} /* does not handle concave quads
}
// optimized code for quadrilaterals
else if ( face.mNumIndices == 4) {
// quads can have at maximum one concave vertex. Determine
// this vertex (if it exists) and start tri-fanning from
// it.
unsigned int start_vertex = 0;
for (unsigned int i = 0; i < 4; ++i) {
const aiVector3D& v0 = verts[face.mIndices[(i+3) % 4]];
const aiVector3D& v1 = verts[face.mIndices[(i+2) % 4]];
const aiVector3D& v2 = verts[face.mIndices[(i+1) % 4]];
const aiVector3D& v = verts[face.mIndices[i]];
aiVector3D left = (v0-v);
aiVector3D diag = (v1-v);
aiVector3D right = (v2-v);
left.Normalize();
diag.Normalize();
right.Normalize();
const float angle = acos(left*diag) + acos(right*diag);
if (angle > AI_MATH_PI_F) {
// this is the concave point
start_vertex = i;
break;
}
}
const unsigned int temp[] = {face.mIndices[0], face.mIndices[1], face.mIndices[2], face.mIndices[3]};
aiFace& nface = *curOut++;
nface.mNumIndices = 3;
nface.mIndices = face.mIndices;
nface.mIndices[0] = temp[start_vertex];
nface.mIndices[1] = temp[(start_vertex + 1) % 4];
nface.mIndices[2] = temp[(start_vertex + 2) % 4];
aiFace& sface = *curOut++;
sface.mNumIndices = 3;
sface.mIndices = new unsigned int[3];
sface.mIndices[0] = face.mIndices[0];
sface.mIndices[1] = face.mIndices[2];
sface.mIndices[2] = face.mIndices[3];
sface.mIndices[0] = temp[start_vertex];
sface.mIndices[1] = temp[(start_vertex + 2) % 4];
sface.mIndices[2] = temp[(start_vertex + 3) % 4];
// prevent double deletion of the indices field
face.mIndices = NULL;
continue;
} */
}
else
{
// A polygon with more than 3 vertices can be either concave or convex.
@ -246,7 +283,6 @@ bool TriangulateProcess::TriangulateMesh( aiMesh* pMesh)
// We project it onto a plane to get a 2d triangle.
// Collect all vertices of of the polygon.
const aiVector3D* verts = pMesh->mVertices;
for (tmp = 0; tmp < max; ++tmp) {
temp_verts3d[tmp] = verts[idx[tmp]];
}

View File

@ -52,7 +52,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
using namespace Assimp;
static const aiImporterDesc desc = {
"Collada Importer",
"Direct3D XFile Importer",
"",
"",
"",
@ -594,8 +594,9 @@ void XFileImporter::ConvertMaterials( aiScene* pScene, const std::vector<XFile::
mat->AddProperty<int>( &shadeMode, 1, AI_MATKEY_SHADING_MODEL);
// material colours
// FIX: Setup this as ambient not as emissive color
mat->AddProperty( &oldMat.mEmissive, 1, AI_MATKEY_COLOR_AMBIENT);
// Unclear: there's no ambient colour, but emissive. What to put for ambient?
// Probably nothing at all, let the user select a suitable default.
mat->AddProperty( &oldMat.mEmissive, 1, AI_MATKEY_COLOR_EMISSIVE);
mat->AddProperty( &oldMat.mDiffuse, 1, AI_MATKEY_COLOR_DIFFUSE);
mat->AddProperty( &oldMat.mSpecular, 1, AI_MATKEY_COLOR_SPECULAR);
mat->AddProperty( &oldMat.mSpecularExponent, 1, AI_MATKEY_SHININESS);

View File

@ -460,7 +460,7 @@ void XFileParser::ParseDataObjectMesh( Mesh* pMesh)
Face& face = pMesh->mPosFaces[a];
for( unsigned int b = 0; b < numIndices; b++)
face.mIndices.push_back( ReadInt());
CheckForSeparator();
TestForSeparator();
}
// here, other data objects may follow
@ -583,7 +583,7 @@ void XFileParser::ParseDataObjectMeshNormals( Mesh* pMesh)
for( unsigned int b = 0; b < numIndices; b++)
face.mIndices.push_back( ReadInt());
CheckForSeparator();
TestForSeparator();
}
CheckForClosingBrace();

File diff suppressed because it is too large Load Diff

View File

@ -1,10 +1,10 @@
/*******************************************************************************
* *
* Author : Angus Johnson *
* Version : 4.6.3 *
* Date : 11 November 2011 *
* Version : 4.8.8 *
* Date : 30 August 2012 *
* Website : http://www.angusj.com *
* Copyright : Angus Johnson 2010-2011 *
* Copyright : Angus Johnson 2010-2012 *
* *
* License: *
* Use, modification & distribution is subject to Boost Software License Ver 1. *
@ -73,18 +73,21 @@ struct ExPolygon {
};
typedef std::vector< ExPolygon > ExPolygons;
enum JoinType { jtSquare, jtMiter, jtRound };
enum JoinType { jtSquare, jtRound, jtMiter };
bool Orientation(const Polygon &poly);
double Area(const Polygon &poly);
void OffsetPolygons(const Polygons &in_polys, Polygons &out_polys,
double delta, JoinType jointype = jtSquare, double MiterLimit = 2);
void SimplifyPolygon(const Polygon &in_poly, Polygons &out_polys, PolyFillType fillType = pftEvenOdd);
void SimplifyPolygons(const Polygons &in_polys, Polygons &out_polys, PolyFillType fillType = pftEvenOdd);
void SimplifyPolygons(Polygons &polys, PolyFillType fillType = pftEvenOdd);
void ReversePoints(Polygon& p);
void ReversePoints(Polygons& p);
void ReversePolygon(Polygon& p);
void ReversePolygons(Polygons& p);
//used internally ...
enum EdgeSide { esLeft, esRight };
enum EdgeSide { esNeither = 0, esLeft = 1, esRight = 2, esBoth = 3 };
enum IntersectProtects { ipNone = 0, ipLeft = 1, ipRight = 2, ipBoth = 3 };
struct TEdge {
@ -139,8 +142,8 @@ struct OutRec {
OutRec *AppendLink;
OutPt *pts;
OutPt *bottomPt;
TEdge *bottomE1;
TEdge *bottomE2;
OutPt *bottomFlag;
EdgeSide sides;
};
struct OutPt {
@ -256,9 +259,10 @@ private:
void IntersectEdges(TEdge *e1, TEdge *e2,
const IntPoint &pt, IntersectProtects protects);
OutRec* CreateOutRec();
void AddOutPt(TEdge *e, TEdge *altE, const IntPoint &pt);
void AddOutPt(TEdge *e, const IntPoint &pt);
void DisposeBottomPt(OutRec &outRec);
void DisposeAllPolyPts();
void DisposeOutRec(PolyOutList::size_type index, bool ignorePts = false);
void DisposeOutRec(PolyOutList::size_type index);
bool ProcessIntersections(const long64 botY, const long64 topY);
void AddIntersectNode(TEdge *e1, TEdge *e2, const IntPoint &pt);
void BuildIntersectList(const long64 botY, const long64 topY);

View File

@ -135,6 +135,11 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
/* Tells the compiler that a function never returns. Used in code analysis
* to skip dead paths (e.g. after an assertion evaluated to false). */
# define AI_WONT_RETURN __declspec(noreturn)
#elif defined(SWIG)
/* Do nothing, the relevant defines are all in AssimpSwigPort.i */
#else
# define AI_WONT_RETURN

View File

@ -56,8 +56,8 @@ class aiQuaterniont
{
public:
aiQuaterniont() : w(), x(), y(), z() {}
aiQuaterniont(TReal w, TReal x, TReal y, TReal z)
: w(w), x(x), y(y), z(z) {}
aiQuaterniont(TReal pw, TReal px, TReal py, TReal pz)
: w(pw), x(px), y(py), z(pz) {}
/** Construct from rotation matrix. Result is undefined if the matrix is not orthonormal. */
aiQuaterniont( const aiMatrix3x3t<TReal>& pRotMatrix);

View File

@ -178,7 +178,7 @@ struct aiColor3D
/** Component-wise subtraction */
aiColor3D operator-(const aiColor3D& c) const {
return aiColor3D(r+c.r,g+c.g,b+c.b);
return aiColor3D(r-c.r,g-c.g,b-c.b);
}
/** Component-wise multiplication */
@ -314,7 +314,7 @@ struct aiString
/** Append a string to the string */
void Append (const char* app) {
const size_t len = strlen(app);
const size_t len = ::strlen(app);
if (!len) {
return;
}

View File

@ -43,38 +43,39 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
%include "carrays.i"
%include "typemaps.i"
%{
#include "..\..\..\include\aiDefines.h"
#include "..\..\..\include\aiConfig.h"
#include "..\..\..\include\aiTypes.h"
#include "..\..\..\include\aiVersion.h"
#include "..\..\..\include\aiPostProcess.h"
#include "..\..\..\include\aiVector2D.h"
#include "..\..\..\include\aiVector3D.h"
#include "..\..\..\include\aiColor4D.h"
#include "..\..\..\include\aiMatrix3x3.h"
#include "..\..\..\include\aiMatrix4x4.h"
#include "..\..\..\include\aiCamera.h"
#include "..\..\..\include\aiLight.h"
#include "..\..\..\include\aiAnim.h"
#include "..\..\..\include\aiMesh.h"
#include "..\..\..\include\aiFileIO.h"
#include "..\..\..\include\aiMaterial.h"
#include "..\..\..\include\aiQuaternion.h"
#include "..\..\..\include\aiScene.h"
#include "..\..\..\include\aiTexture.h"
#include "..\..\..\include\assimp.hpp"
#include "..\..\..\include\IOSystem.h"
#include "..\..\..\include\IOStream.h"
#include "..\..\..\include\Logger.h"
#include "..\..\..\include\LogStream.h"
#include "..\..\..\include\NullLogger.h"
#include "..\..\..\include\ProgressHandler.h"
#include "..\..\..\include\assimp\defs.h"
#include "..\..\..\include\assimp\config.h"
#include "..\..\..\include\assimp\types.h"
#include "..\..\..\include\assimp\version.h"
#include "..\..\..\include\assimp\postprocess.h"
#include "..\..\..\include\assimp\vector2.h"
#include "..\..\..\include\assimp\vector3.h"
#include "..\..\..\include\assimp\color4.h"
#include "..\..\..\include\assimp\matrix3x3.h"
#include "..\..\..\include\assimp\matrix4x4.h"
#include "..\..\..\include\assimp\camera.h"
#include "..\..\..\include\assimp\light.h"
#include "..\..\..\include\assimp\anim.h"
#include "..\..\..\include\assimp\mesh.h"
#include "..\..\..\include\assimp\cfileio.h"
#include "..\..\..\include\assimp\material.h"
#include "..\..\..\include\assimp\quaternion.h"
#include "..\..\..\include\assimp\scene.h"
#include "..\..\..\include\assimp\texture.h"
#include "..\..\..\include\assimp\Importer.hpp"
#include "..\..\..\include\assimp\IOSystem.hpp"
#include "..\..\..\include\assimp\IOStream.hpp"
#include "..\..\..\include\assimp\Logger.hpp"
#include "..\..\..\include\assimp\LogStream.hpp"
#include "..\..\..\include\assimp\NullLogger.hpp"
#include "..\..\..\include\assimp\ProgressHandler.hpp"
%}
#define C_STRUCT
#define C_ENUM
#define ASSIMP_API
#define PACK_STRUCT
#define AI_FORCE_INLINE
%rename(__add__) operator+;
%rename(__addnset__) operator+=;
@ -504,33 +505,43 @@ ASSIMP_POINTER_POINTER(aiScene,aiTexture,mTextures,$self->mNumTextures);
%ignore ::aiGetMaterialTexture;
%include "..\..\..\include\aiDefines.h"
%include "..\..\..\include\aiConfig.h"
%include "..\..\..\include\aiTypes.h"
%include "..\..\..\include\aiVersion.h"
%include "..\..\..\include\aiPostProcess.h"
%include "..\..\..\include\aiVector2D.h"
%include "..\..\..\include\aiVector3D.h"
%include "..\..\..\include\aiColor4D.h"
%include "..\..\..\include\aiMatrix3x3.h"
%include "..\..\..\include\aiMatrix4x4.h"
%include "..\..\..\include\aiCamera.h"
%include "..\..\..\include\aiLight.h"
%include "..\..\..\include\aiAnim.h"
%include "..\..\..\include\aiMesh.h"
%include "..\..\..\include\aiFileIO.h"
%include "..\..\..\include\aiMaterial.h"
%include "..\..\..\include\aiQuaternion.h"
%include "..\..\..\include\aiScene.h"
%include "..\..\..\include\aiTexture.h"
%include "..\..\..\include\assimp.hpp"
%include "..\..\..\include\ProgressHandler.h"
%include "..\..\..\include\assimp\defs.h"
%include "..\..\..\include\assimp\config.h"
%include "..\..\..\include\assimp\types.h"
%include "..\..\..\include\assimp\version.h"
%include "..\..\..\include\assimp\postprocess.h"
%include "..\..\..\include\assimp\vector2.h"
%include "..\..\..\include\assimp\vector3.h"
%include "..\..\..\include\assimp\color4.h"
%include "..\..\..\include\assimp\matrix3x3.h"
%include "..\..\..\include\assimp\matrix4x4.h"
%include "..\..\..\include\assimp\camera.h"
%include "..\..\..\include\assimp\light.h"
%include "..\..\..\include\assimp\anim.h"
%include "..\..\..\include\assimp\mesh.h"
%include "..\..\..\include\assimp\cfileio.h"
%include "..\..\..\include\assimp\material.h"
%include "..\..\..\include\assimp\quaternion.h"
%include "..\..\..\include\assimp\scene.h"
%include "..\..\..\include\assimp\texture.h"
%include "..\..\..\include\assimp\Importer.hpp"
%include "..\..\..\include\assimp\ProgressHandler.hpp"
//%include "..\..\..\include\IOSystem.h"
//%include "..\..\..\include\IOStream.h"
//%include "..\..\..\include\Logger.h"
//%include "..\..\..\include\LogStream.h"
//%include "..\..\..\include\NullLogger.h"
%template(aiColor4D) aiColor4t<float>;
%template(aiVector3D) aiVector3t<float>;
%template(aiVector2D) aiVector2t<float>;
%template(aiQuaternion) aiQuaterniont<float>;
%template(aiMatrix3x3) aiMatrix3x3t<float>;
%template(aiMatrix4x4) aiMatrix4x4t<float>;
%template(FloatVector) std::vector<float>;
%template(UintVector) std::vector<unsigned int>;
%template(aiAnimationVector) std::vector<aiAnimation *>;

File diff suppressed because it is too large Load Diff

View File

@ -3,7 +3,7 @@
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>9.0.30729</ProductVersion>
<ProductVersion>9.0.21022</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{A0CE9ED2-A27E-40AE-95F5-FEF94BB7E131}</ProjectGuid>
<OutputType>Library</OutputType>
@ -142,9 +142,24 @@
<Compile Include="FloatVector.cs" />
<Compile Include="Importer.cs" />
<Compile Include="ProgressHandler.cs" />
<Compile Include="SWIGTYPE_p_aiImporterDesc.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="SWIGTYPE_p_Assimp__BaseImporter.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="SWIGTYPE_p_Assimp__ImporterPimpl.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="SWIGTYPE_p_float.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="SWIGTYPE_p_std__string.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="SWIGTYPE_p_void.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="UintVector.cs" />
</ItemGroup>
<ItemGroup>

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
@ -43,60 +43,6 @@ public class Assimp {
return ret;
}
public static aiVector2D __add__(aiVector2D v1, aiVector2D v2) {
aiVector2D ret = new aiVector2D(AssimpPINVOKE.__add__(aiVector2D.getCPtr(v1), aiVector2D.getCPtr(v2)), true);
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static aiVector2D __sub__(aiVector2D v1, aiVector2D v2) {
aiVector2D ret = new aiVector2D(AssimpPINVOKE.__sub____SWIG_0(aiVector2D.getCPtr(v1), aiVector2D.getCPtr(v2)), true);
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static float __mul__(aiVector2D v1, aiVector2D v2) {
float ret = AssimpPINVOKE.__mul____SWIG_0(aiVector2D.getCPtr(v1), aiVector2D.getCPtr(v2));
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static aiVector2D __mul__(float f, aiVector2D v) {
aiVector2D ret = new aiVector2D(AssimpPINVOKE.__mul____SWIG_1(f, aiVector2D.getCPtr(v)), true);
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static aiVector2D __mul__(aiVector2D v, float f) {
aiVector2D ret = new aiVector2D(AssimpPINVOKE.__mul____SWIG_2(aiVector2D.getCPtr(v), f), true);
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static aiVector2D __div__(aiVector2D v, float f) {
aiVector2D ret = new aiVector2D(AssimpPINVOKE.__div____SWIG_0(aiVector2D.getCPtr(v), f), true);
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static aiVector2D __div__(aiVector2D v, aiVector2D v2) {
aiVector2D ret = new aiVector2D(AssimpPINVOKE.__div____SWIG_1(aiVector2D.getCPtr(v), aiVector2D.getCPtr(v2)), true);
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static aiVector2D __sub__(aiVector2D v) {
aiVector2D ret = new aiVector2D(AssimpPINVOKE.__sub____SWIG_1(aiVector2D.getCPtr(v)), true);
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static aiScene aiImportFileFromMemory(string arg0, uint arg1, uint arg2, string arg3) {
IntPtr cPtr = AssimpPINVOKE.aiImportFileFromMemory(arg0, arg1, arg2, arg3);
aiScene ret = (cPtr == IntPtr.Zero) ? null : new aiScene(cPtr, false);
return ret;
}
public static readonly double AI_MATH_PI = AssimpPINVOKE.AI_MATH_PI_get();
public static readonly double AI_MATH_TWO_PI = AssimpPINVOKE.AI_MATH_TWO_PI_get();
public static readonly double AI_MATH_HALF_PI = AssimpPINVOKE.AI_MATH_HALF_PI_get();
@ -104,7 +50,10 @@ public class Assimp {
public static readonly double AI_MATH_TWO_PI_F = AssimpPINVOKE.AI_MATH_TWO_PI_F_get();
public static readonly double AI_MATH_HALF_PI_F = AssimpPINVOKE.AI_MATH_HALF_PI_F_get();
public static readonly string AI_CONFIG_GLOB_MEASURE_TIME = AssimpPINVOKE.AI_CONFIG_GLOB_MEASURE_TIME_get();
public static readonly string AI_CONFIG_PP_SBBC_MAX_BONES = AssimpPINVOKE.AI_CONFIG_PP_SBBC_MAX_BONES_get();
public static readonly int AI_SBBC_DEFAULT_MAX_BONES = AssimpPINVOKE.AI_SBBC_DEFAULT_MAX_BONES_get();
public static readonly string AI_CONFIG_PP_CT_MAX_SMOOTHING_ANGLE = AssimpPINVOKE.AI_CONFIG_PP_CT_MAX_SMOOTHING_ANGLE_get();
public static readonly string AI_CONFIG_PP_CT_TEXTURE_CHANNEL_INDEX = AssimpPINVOKE.AI_CONFIG_PP_CT_TEXTURE_CHANNEL_INDEX_get();
public static readonly string AI_CONFIG_PP_GSN_MAX_SMOOTHING_ANGLE = AssimpPINVOKE.AI_CONFIG_PP_GSN_MAX_SMOOTHING_ANGLE_get();
public static readonly string AI_CONFIG_IMPORT_MDL_COLORMAP = AssimpPINVOKE.AI_CONFIG_IMPORT_MDL_COLORMAP_get();
public static readonly string AI_CONFIG_PP_RRM_EXCLUDE_LIST = AssimpPINVOKE.AI_CONFIG_PP_RRM_EXCLUDE_LIST_get();
@ -118,6 +67,9 @@ public class Assimp {
public static readonly int AI_SLM_DEFAULT_MAX_VERTICES = AssimpPINVOKE.AI_SLM_DEFAULT_MAX_VERTICES_get();
public static readonly string AI_CONFIG_PP_LBW_MAX_WEIGHTS = AssimpPINVOKE.AI_CONFIG_PP_LBW_MAX_WEIGHTS_get();
public static readonly int AI_LMW_MAX_WEIGHTS = AssimpPINVOKE.AI_LMW_MAX_WEIGHTS_get();
public static readonly string AI_CONFIG_PP_DB_THRESHOLD = AssimpPINVOKE.AI_CONFIG_PP_DB_THRESHOLD_get();
public static readonly double AI_DEBONE_THRESHOLD = AssimpPINVOKE.AI_DEBONE_THRESHOLD_get();
public static readonly string AI_CONFIG_PP_DB_ALL_OR_NONE = AssimpPINVOKE.AI_CONFIG_PP_DB_ALL_OR_NONE_get();
public static readonly int PP_ICL_PTCACHE_SIZE = AssimpPINVOKE.PP_ICL_PTCACHE_SIZE_get();
public static readonly string AI_CONFIG_PP_ICL_PTCACHE_SIZE = AssimpPINVOKE.AI_CONFIG_PP_ICL_PTCACHE_SIZE_get();
public static readonly string AI_CONFIG_PP_RVC_FLAGS = AssimpPINVOKE.AI_CONFIG_PP_RVC_FLAGS_get();
@ -150,6 +102,10 @@ public class Assimp {
public static readonly string AI_CONFIG_IMPORT_LWS_ANIM_END = AssimpPINVOKE.AI_CONFIG_IMPORT_LWS_ANIM_END_get();
public static readonly string AI_CONFIG_IMPORT_IRR_ANIM_FPS = AssimpPINVOKE.AI_CONFIG_IMPORT_IRR_ANIM_FPS_get();
public static readonly string AI_CONFIG_IMPORT_OGRE_MATERIAL_FILE = AssimpPINVOKE.AI_CONFIG_IMPORT_OGRE_MATERIAL_FILE_get();
public static readonly string AI_CONFIG_IMPORT_OGRE_TEXTURETYPE_FROM_FILENAME = AssimpPINVOKE.AI_CONFIG_IMPORT_OGRE_TEXTURETYPE_FROM_FILENAME_get();
public static readonly string AI_CONFIG_IMPORT_IFC_SKIP_SPACE_REPRESENTATIONS = AssimpPINVOKE.AI_CONFIG_IMPORT_IFC_SKIP_SPACE_REPRESENTATIONS_get();
public static readonly string AI_CONFIG_IMPORT_IFC_SKIP_CURVE_REPRESENTATIONS = AssimpPINVOKE.AI_CONFIG_IMPORT_IFC_SKIP_CURVE_REPRESENTATIONS_get();
public static readonly string AI_CONFIG_IMPORT_IFC_CUSTOM_TRIANGULATION = AssimpPINVOKE.AI_CONFIG_IMPORT_IFC_CUSTOM_TRIANGULATION_get();
public static readonly int ASSIMP_CFLAGS_SHARED = AssimpPINVOKE.ASSIMP_CFLAGS_SHARED_get();
public static readonly int ASSIMP_CFLAGS_STLPORT = AssimpPINVOKE.ASSIMP_CFLAGS_STLPORT_get();
public static readonly int ASSIMP_CFLAGS_DEBUG = AssimpPINVOKE.ASSIMP_CFLAGS_DEBUG_get();
@ -162,7 +118,6 @@ public class Assimp {
public static readonly int AI_MAX_NUMBER_OF_COLOR_SETS = AssimpPINVOKE.AI_MAX_NUMBER_OF_COLOR_SETS_get();
public static readonly int AI_MAX_NUMBER_OF_TEXTURECOORDS = AssimpPINVOKE.AI_MAX_NUMBER_OF_TEXTURECOORDS_get();
public static readonly string AI_DEFAULT_MATERIAL_NAME = AssimpPINVOKE.AI_DEFAULT_MATERIAL_NAME_get();
public static readonly string AI_DEFAULT_TEXTURED_MATERIAL_NAME = AssimpPINVOKE.AI_DEFAULT_TEXTURED_MATERIAL_NAME_get();
public static readonly string _AI_MATKEY_TEXTURE_BASE = AssimpPINVOKE._AI_MATKEY_TEXTURE_BASE_get();
public static readonly string _AI_MATKEY_UVWSRC_BASE = AssimpPINVOKE._AI_MATKEY_UVWSRC_BASE_get();
public static readonly string _AI_MATKEY_TEXOP_BASE = AssimpPINVOKE._AI_MATKEY_TEXOP_BASE_get();

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
@ -128,6 +128,18 @@ public class Importer : IDisposable {
return ret;
}
public aiScene GetScene() {
IntPtr cPtr = AssimpPINVOKE.Importer_GetScene(swigCPtr);
aiScene ret = (cPtr == IntPtr.Zero) ? null : new aiScene(cPtr, false);
return ret;
}
public aiScene GetOrphanedScene() {
IntPtr cPtr = AssimpPINVOKE.Importer_GetOrphanedScene(swigCPtr);
aiScene ret = (cPtr == IntPtr.Zero) ? null : new aiScene(cPtr, false);
return ret;
}
public bool IsExtensionSupported(string szExtension) {
bool ret = AssimpPINVOKE.Importer_IsExtensionSupported__SWIG_0(swigCPtr, szExtension);
return ret;
@ -143,15 +155,31 @@ public class Importer : IDisposable {
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
}
public aiScene GetScene() {
IntPtr cPtr = AssimpPINVOKE.Importer_GetScene(swigCPtr);
aiScene ret = (cPtr == IntPtr.Zero) ? null : new aiScene(cPtr, false);
public uint GetImporterCount() {
uint ret = AssimpPINVOKE.Importer_GetImporterCount(swigCPtr);
return ret;
}
public aiScene GetOrphanedScene() {
IntPtr cPtr = AssimpPINVOKE.Importer_GetOrphanedScene(swigCPtr);
aiScene ret = (cPtr == IntPtr.Zero) ? null : new aiScene(cPtr, false);
public SWIGTYPE_p_aiImporterDesc GetImporterInfo(uint index) {
IntPtr cPtr = AssimpPINVOKE.Importer_GetImporterInfo(swigCPtr, index);
SWIGTYPE_p_aiImporterDesc ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_aiImporterDesc(cPtr, false);
return ret;
}
public SWIGTYPE_p_Assimp__BaseImporter GetImporter(uint index) {
IntPtr cPtr = AssimpPINVOKE.Importer_GetImporter__SWIG_0(swigCPtr, index);
SWIGTYPE_p_Assimp__BaseImporter ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_Assimp__BaseImporter(cPtr, false);
return ret;
}
public SWIGTYPE_p_Assimp__BaseImporter GetImporter(string szExtension) {
IntPtr cPtr = AssimpPINVOKE.Importer_GetImporter__SWIG_1(swigCPtr, szExtension);
SWIGTYPE_p_Assimp__BaseImporter ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_Assimp__BaseImporter(cPtr, false);
return ret;
}
public uint GetImporterIndex(string szExtension) {
uint ret = AssimpPINVOKE.Importer_GetImporterIndex(swigCPtr, szExtension);
return ret;
}
@ -164,6 +192,12 @@ public class Importer : IDisposable {
AssimpPINVOKE.Importer_SetExtraVerbose(swigCPtr, bDo);
}
public SWIGTYPE_p_Assimp__ImporterPimpl Pimpl() {
IntPtr cPtr = AssimpPINVOKE.Importer_Pimpl__SWIG_0(swigCPtr);
SWIGTYPE_p_Assimp__ImporterPimpl ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_Assimp__ImporterPimpl(cPtr, false);
return ret;
}
public string GetExtensionList() {
string ret = AssimpPINVOKE.Importer_GetExtensionList__SWIG_2(swigCPtr);
return ret;

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -0,0 +1,27 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
using System;
using System.Runtime.InteropServices;
public class SWIGTYPE_p_Assimp__BaseImporter {
private HandleRef swigCPtr;
internal SWIGTYPE_p_Assimp__BaseImporter(IntPtr cPtr, bool futureUse) {
swigCPtr = new HandleRef(this, cPtr);
}
protected SWIGTYPE_p_Assimp__BaseImporter() {
swigCPtr = new HandleRef(null, IntPtr.Zero);
}
internal static HandleRef getCPtr(SWIGTYPE_p_Assimp__BaseImporter obj) {
return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@ -0,0 +1,27 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
using System;
using System.Runtime.InteropServices;
public class SWIGTYPE_p_Assimp__ImporterPimpl {
private HandleRef swigCPtr;
internal SWIGTYPE_p_Assimp__ImporterPimpl(IntPtr cPtr, bool futureUse) {
swigCPtr = new HandleRef(this, cPtr);
}
protected SWIGTYPE_p_Assimp__ImporterPimpl() {
swigCPtr = new HandleRef(null, IntPtr.Zero);
}
internal static HandleRef getCPtr(SWIGTYPE_p_Assimp__ImporterPimpl obj) {
return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@ -0,0 +1,27 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
using System;
using System.Runtime.InteropServices;
public class SWIGTYPE_p_aiImporterDesc {
private HandleRef swigCPtr;
internal SWIGTYPE_p_aiImporterDesc(IntPtr cPtr, bool futureUse) {
swigCPtr = new HandleRef(this, cPtr);
}
protected SWIGTYPE_p_aiImporterDesc() {
swigCPtr = new HandleRef(null, IntPtr.Zero);
}
internal static HandleRef getCPtr(SWIGTYPE_p_aiImporterDesc obj) {
return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@ -0,0 +1,27 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
using System;
using System.Runtime.InteropServices;
public class SWIGTYPE_p_float {
private HandleRef swigCPtr;
internal SWIGTYPE_p_float(IntPtr cPtr, bool futureUse) {
swigCPtr = new HandleRef(this, cPtr);
}
protected SWIGTYPE_p_float() {
swigCPtr = new HandleRef(null, IntPtr.Zero);
}
internal static HandleRef getCPtr(SWIGTYPE_p_float obj) {
return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -0,0 +1,27 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
using System;
using System.Runtime.InteropServices;
public class SWIGTYPE_p_void {
private HandleRef swigCPtr;
internal SWIGTYPE_p_void(IntPtr cPtr, bool futureUse) {
swigCPtr = new HandleRef(this, cPtr);
}
protected SWIGTYPE_p_void() {
swigCPtr = new HandleRef(null, IntPtr.Zero);
}
internal static HandleRef getCPtr(SWIGTYPE_p_void obj) {
return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
@ -76,6 +76,49 @@ public class aiMaterial : IDisposable {
return ret;
}
public aiReturn AddBinaryProperty(SWIGTYPE_p_void pInput, uint pSizeInBytes, string pKey, uint type, uint index, aiPropertyTypeInfo pType) {
aiReturn ret = (aiReturn)AssimpPINVOKE.aiMaterial_AddBinaryProperty(swigCPtr, SWIGTYPE_p_void.getCPtr(pInput), pSizeInBytes, pKey, type, index, (int)pType);
return ret;
}
public aiReturn AddProperty(aiString pInput, string pKey, uint type, uint index) {
aiReturn ret = (aiReturn)AssimpPINVOKE.aiMaterial_AddProperty__SWIG_0(swigCPtr, aiString.getCPtr(pInput), pKey, type, index);
return ret;
}
public aiReturn AddProperty(aiString pInput, string pKey, uint type) {
aiReturn ret = (aiReturn)AssimpPINVOKE.aiMaterial_AddProperty__SWIG_1(swigCPtr, aiString.getCPtr(pInput), pKey, type);
return ret;
}
public aiReturn AddProperty(aiString pInput, string pKey) {
aiReturn ret = (aiReturn)AssimpPINVOKE.aiMaterial_AddProperty__SWIG_2(swigCPtr, aiString.getCPtr(pInput), pKey);
return ret;
}
public aiReturn RemoveProperty(string pKey, uint type, uint index) {
aiReturn ret = (aiReturn)AssimpPINVOKE.aiMaterial_RemoveProperty__SWIG_0(swigCPtr, pKey, type, index);
return ret;
}
public aiReturn RemoveProperty(string pKey, uint type) {
aiReturn ret = (aiReturn)AssimpPINVOKE.aiMaterial_RemoveProperty__SWIG_1(swigCPtr, pKey, type);
return ret;
}
public aiReturn RemoveProperty(string pKey) {
aiReturn ret = (aiReturn)AssimpPINVOKE.aiMaterial_RemoveProperty__SWIG_2(swigCPtr, pKey);
return ret;
}
public void Clear() {
AssimpPINVOKE.aiMaterial_Clear(swigCPtr);
}
public static void CopyPropertyList(aiMaterial pcDest, aiMaterial pcSrc) {
AssimpPINVOKE.aiMaterial_CopyPropertyList(aiMaterial.getCPtr(pcDest), aiMaterial.getCPtr(pcSrc));
}
public bool GetDiffuse(aiColor4D INOUT) {
bool ret = AssimpPINVOKE.aiMaterial_GetDiffuse(swigCPtr, aiColor4D.getCPtr(INOUT));
return ret;

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
@ -46,6 +46,36 @@ public class aiMatrix3x3 : IDisposable {
public aiMatrix3x3(float _a1, float _a2, float _a3, float _b1, float _b2, float _b3, float _c1, float _c2, float _c3) : this(AssimpPINVOKE.new_aiMatrix3x3__SWIG_1(_a1, _a2, _a3, _b1, _b2, _b3, _c1, _c2, _c3), true) {
}
public aiMatrix3x3 __mulnset__(aiMatrix3x3 m) {
aiMatrix3x3 ret = new aiMatrix3x3(AssimpPINVOKE.aiMatrix3x3___mulnset__(swigCPtr, aiMatrix3x3.getCPtr(m)), false);
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public aiMatrix3x3 __mul__(aiMatrix3x3 m) {
aiMatrix3x3 ret = new aiMatrix3x3(AssimpPINVOKE.aiMatrix3x3___mul__(swigCPtr, aiMatrix3x3.getCPtr(m)), true);
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public SWIGTYPE_p_float __idx__(uint p_iIndex) {
IntPtr cPtr = AssimpPINVOKE.aiMatrix3x3___idx____SWIG_0(swigCPtr, p_iIndex);
SWIGTYPE_p_float ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
public bool __equal__(aiMatrix4x4 m) {
bool ret = AssimpPINVOKE.aiMatrix3x3___equal__(swigCPtr, aiMatrix4x4.getCPtr(m));
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public bool __nequal__(aiMatrix4x4 m) {
bool ret = AssimpPINVOKE.aiMatrix3x3___nequal__(swigCPtr, aiMatrix4x4.getCPtr(m));
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public aiMatrix3x3(aiMatrix4x4 pMatrix) : this(AssimpPINVOKE.new_aiMatrix3x3__SWIG_2(aiMatrix4x4.getCPtr(pMatrix)), true) {
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
}

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
@ -50,6 +50,36 @@ public class aiMatrix4x4 : IDisposable {
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
}
public SWIGTYPE_p_float __idx__(uint p_iIndex) {
IntPtr cPtr = AssimpPINVOKE.aiMatrix4x4___idx____SWIG_0(swigCPtr, p_iIndex);
SWIGTYPE_p_float ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
public bool __equal__(aiMatrix4x4 m) {
bool ret = AssimpPINVOKE.aiMatrix4x4___equal__(swigCPtr, aiMatrix4x4.getCPtr(m));
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public bool __nequal__(aiMatrix4x4 m) {
bool ret = AssimpPINVOKE.aiMatrix4x4___nequal__(swigCPtr, aiMatrix4x4.getCPtr(m));
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public aiMatrix4x4 __mulnset__(aiMatrix4x4 m) {
aiMatrix4x4 ret = new aiMatrix4x4(AssimpPINVOKE.aiMatrix4x4___mulnset__(swigCPtr, aiMatrix4x4.getCPtr(m)), false);
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public aiMatrix4x4 __mul__(aiMatrix4x4 m) {
aiMatrix4x4 ret = new aiMatrix4x4(AssimpPINVOKE.aiMatrix4x4___mul__(swigCPtr, aiMatrix4x4.getCPtr(m)), true);
if (AssimpPINVOKE.SWIGPendingException.Pending) throw AssimpPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public aiMatrix4x4 Transpose() {
aiMatrix4x4 ret = new aiMatrix4x4(AssimpPINVOKE.aiMatrix4x4_Transpose(swigCPtr), false);
return ret;

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
@ -31,7 +31,9 @@ public enum aiPostProcessSteps {
aiProcess_OptimizeMeshes = 0x200000,
aiProcess_OptimizeGraph = 0x400000,
aiProcess_FlipUVs = 0x800000,
aiProcess_FlipWindingOrder = 0x1000000
aiProcess_FlipWindingOrder = 0x1000000,
aiProcess_SplitByBoneCount = 0x2000000,
aiProcess_Debone = 0x4000000
, aiProcess_ConvertToLeftHanded = aiProcess_MakeLeftHanded|aiProcess_FlipUVs|aiProcess_FlipWindingOrder,
}

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
@ -43,7 +43,7 @@ public class aiQuaternion : IDisposable {
public aiQuaternion() : this(AssimpPINVOKE.new_aiQuaternion__SWIG_0(), true) {
}
public aiQuaternion(float _w, float _x, float _y, float _z) : this(AssimpPINVOKE.new_aiQuaternion__SWIG_1(_w, _x, _y, _z), true) {
public aiQuaternion(float w, float x, float y, float z) : this(AssimpPINVOKE.new_aiQuaternion__SWIG_1(w, x, y, z), true) {
}
public aiQuaternion(aiMatrix3x3 pRotMatrix) : this(AssimpPINVOKE.new_aiQuaternion__SWIG_2(aiMatrix3x3.getCPtr(pRotMatrix)), true) {

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
@ -161,6 +161,17 @@ public class aiScene : IDisposable {
return ret;
}
public SWIGTYPE_p_void mPrivate {
set {
AssimpPINVOKE.aiScene_mPrivate_set(swigCPtr, SWIGTYPE_p_void.getCPtr(value));
}
get {
IntPtr cPtr = AssimpPINVOKE.aiScene_mPrivate_get(swigCPtr);
SWIGTYPE_p_void ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_void(cPtr, false);
return ret;
}
}
private aiAnimationVector GetmAnimations() {
IntPtr cPtr = AssimpPINVOKE.aiScene_GetmAnimations(swigCPtr);
aiAnimationVector ret = (cPtr == IntPtr.Zero) ? null : new aiAnimationVector(cPtr, true);

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
@ -70,6 +70,11 @@ public class aiString : IDisposable {
return ret;
}
public string C_Str() {
string ret = AssimpPINVOKE.aiString_C_Str(swigCPtr);
return ret;
}
public uint Length {
set {
AssimpPINVOKE.aiString_Length_set(swigCPtr, value);

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

View File

@ -1,6 +1,6 @@
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.1
* Version 2.0.8
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.

Some files were not shown because too many files have changed in this diff Show More