How to use the pyassimp.postprocess.aiProcess_GenNormals function in pyassimp

To help you get started, we’ve selected a few pyassimp examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github TangibleDisplay / twiz / ddd / assimpobjloader.py View on Github external
def __init__(self, source):
        # super(AssimpObjLoader, **kwargs)
        # source = kwargs.get('source', '')
        if not source:
            print "no source given!"
            return

        self.scene = scene = load(
            source, 0
            | postprocess.aiProcess_Triangulate
            | postprocess.aiProcess_SplitLargeMeshes
            | postprocess.aiProcess_GenNormals
            )

        self.objects = {}
        for i, mesh in enumerate(scene.meshes):
            self.objects[i] = AssimpMesh(scene, mesh)
github TangibleDisplay / twiz / examples / cube / libs / garden / garden.ddd / assimpobjloader.py View on Github external
def __init__(self, source):
        # super(AssimpObjLoader, **kwargs)
        # source = kwargs.get('source', '')
        if not source:
            print "no source given!"
            return

        self.scene = scene = load(
            source, 0
            | postprocess.aiProcess_Triangulate
            | postprocess.aiProcess_SplitLargeMeshes
            | postprocess.aiProcess_GenNormals
            )

        self.objects = {}
        for i, mesh in enumerate(scene.meshes):
            self.objects[i] = AssimpMesh(scene, mesh)