mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2025-06-10 14:58:10 -05:00
ObjLoading/ObjWriting: Initial skeleton for loading and writing obj files
This commit is contained in:
38
src/ObjLoading/ObjLoading.cpp
Normal file
38
src/ObjLoading/ObjLoading.cpp
Normal file
@ -0,0 +1,38 @@
|
||||
#include "ObjLoading.h"
|
||||
#include "IObjLoader.h"
|
||||
#include "Game/T6/ObjLoaderT6.h"
|
||||
#include "ObjContainer/ObjContainerRegistry.h"
|
||||
|
||||
IObjLoader* objLoaders[]
|
||||
{
|
||||
new ObjLoaderT6()
|
||||
};
|
||||
|
||||
void ObjLoading::LoadReferencedContainersForZone(Zone* zone)
|
||||
{
|
||||
for (auto* loader : objLoaders)
|
||||
{
|
||||
if (loader->SupportsZone(zone))
|
||||
{
|
||||
loader->LoadReferencedContainersForZone(zone);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void ObjLoading::LoadObjDataForZone(Zone* zone)
|
||||
{
|
||||
for (auto* loader : objLoaders)
|
||||
{
|
||||
if (loader->SupportsZone(zone))
|
||||
{
|
||||
loader->LoadObjDataForZone(zone);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void ObjLoading::UnloadContainersOfZone(Zone* zone)
|
||||
{
|
||||
g_ObjContainerRegistry.RemoveContainerReferences(zone);
|
||||
}
|
Reference in New Issue
Block a user