Beispiel #1
0
def getMesh(name):
    global _mesh_cache

    if name not in _mesh_cache:
        _mesh_cache[name] = meshLoader.loadMeshes(
            os.path.join(getResourcePath('meshes'), name))[-1]
    return _mesh_cache[name]
Beispiel #2
0
def getMesh(name):
    global _mesh_cache

    if name not in _mesh_cache:
        full_filename = os.path.join(getResourcePath('meshes'), name)
        if os.path.isfile(full_filename):
            _mesh_cache[name] = meshLoader.loadMeshes(os.path.join(getResourcePath('meshes'), name))[-1]
        else:
            _mesh_cache[name] = None
    return _mesh_cache[name]
Beispiel #3
0
 def _loadMeshThread(self, filename):
     self._mesh = None
     mesh = loadMeshes(filename)[0]
     self._mesh = mesh
     self._updated()
     self._updateMeshInfo()
Beispiel #4
0
 def _loadMeshThread(self, filename):
     self._mesh = None
     mesh = loadMeshes(filename)[0]
     self._mesh = mesh
     self._updated()
     self._updateMeshInfo()
Beispiel #5
0
def getMesh(name):
    global _mesh_cache

    if name not in _mesh_cache:
        _mesh_cache[name] = meshLoader.loadMeshes(os.path.join(getResourcePath('meshes'), name))[-1]
    return _mesh_cache[name]