Announcement

Collapse
No announcement yet.

Importing OpenFlight Models

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Importing OpenFlight Models

    Hi everyone,

    I'm currently working on reusing a set of OpenFlight Models in a UE4.24 application. Importing the model via the Presagis Plugin works mostly fine, but my problem is the combination of Degree Of Freedom (DOF) and Level of Detail (LOD) nodes used in the models, which aren't correctly supported after import.

    OpenFlight has a diffrent structure for LODs than UE.
    OpenFlight selects the correct model based on the distance to the camera and not like UE based on the screen size, and in addition, OpenFlight uses groups for LODs, so a model structure like this can occur, where multiple models share the same LOD:
    Code:
    LOD1 (up to 10m):
            Model A_1
            DOF1:
                    Model B_1
    LOD2 (up to 100m):
            Model A_2
            DOF2:
                    Model B_2
    LOD3 (up to 1000m):
            Model A_3
    For the closest LOD1 Model A and B are presented in the highest quality and B can be transformed (Rotation Translation, Scale) with the DOF node.
    In LOD2 the same structure appears, but with fewer details. Model B can still be animated.
    In LOD3 this animation capability is lost, and Model A and B are combined into one single Mesh A_3.

    I'll have the following structure after the import:
    Code:
    DatasmithSceneActor:
            StaticMeshActor -> StaticMesh_A (With all 3 LODs correctly):
                    StaticMeshActor -> StaticMesh_B1
                    StaticMeshActor -> StaticMesh_B2
    There is the Static Mesh A with all three LODs correctly applied, and two single Static meshes B_1 and B_2. The next step would be combining them in some manner, but I don't know what structure I should be aiming for.

    So my question is what model structure can be used in UE to represent the OpenFlight logic?
    It's not about how the scripts shall look like, I'll figure that out by myself, but I don't know the aim of those scripts.


    Something like this seems to be nice:
    Code:
    DatasmithSceneActor
            StaticMeshActor -> StaticMesh_A (With A_1, A_2, A_3)
            StaticMeshActor -> StaticMesh_B (With B_1, B_2)
    But I think it's not possible in native UE to synchronize the LODs of StaticMesh A and B to always match, so there are always artifacts if the A and B LODs are out fo sync.
    A custom Actor class, which implements this synchronization, might be a solution but forcing UE to swap the StaticMeshes based on the distance to the camera or sth. does not feel right for me.

    Are maybe Skeletal Meshes the solution for this? But implementing skeletons for each model would really suck because I've got a library of a few hundred.
Working...
X