소스 검색

Fix PyAssimp complaining on 'builtin_function_or_method' object has no attribute '_init'. Thanks to pekuja for the patch!

git-svn-id: https://assimp.svn.sourceforge.net/svnroot/assimp/trunk@552 67173fc5-114c-0410-ac8e-9d2fd5bffc1f
aramis_acg 15 년 전
부모
커밋
722dc4a9c2
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      port/PyAssimp/pyassimp/pyassimp.py

+ 2 - 2
port/PyAssimp/pyassimp/pyassimp.py

@@ -160,7 +160,7 @@ def _init(self):
 Python magic to add the _init() function to all C struct classes.
 """
 for struct in dir(structs):
-    if not (struct.startswith('_') or struct.startswith('c_') or struct == "Structure"):
+    if not (struct.startswith('_') or struct.startswith('c_') or struct == "Structure" or struct == "POINTER"):
         setattr(getattr(structs, struct), '_init', _init)
 
 
@@ -268,4 +268,4 @@ def aiDecomposeMatrix(matrix):
     
     from ctypes import byref, pointer
     _assimp_lib.dll.aiDecomposeMatrix(pointer(matrix), byref(scaling), byref(rotation), byref(position))
-    return scaling._init(), rotation._init(), position._init()
+    return scaling._init(), rotation._init(), position._init()