Announcement

Collapse
No announcement yet.

Looking for runtime Datasmith import/reimport or alternatives

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

    Looking for runtime Datasmith import/reimport or alternatives

    I've been working on a VR mechanical visualization tool and i'm looking for something that allows me to import meshes from an external file to the scene outside the editor and add it to a catalog.

    It looks like with the current feature set of Unreal Studio I can get 90% there, but the moment i launch or package the project, the Datasmith importer won't work because
    -You can't execute python scripts at runtime.
    -Blueprint Datasmith importing requires parenting a editor-only class, so this doesn't work either.

    I've found this Runtime Mesh Loader plugin (https://github.com/GameInstitute/RuntimeMeshLoader) but it looks like development has stopped and it works inconsistently.

    Does anybody know of something I could use?

    #2
    For the moment what we recommend is:
    1- to trigger a preparation from your runtime application. From your application run a UEditor in command line that is going to do the import+preparation+cook of the CAD data. You can run a python script in command line or run your own commandlet.
    2- load the cook asset in your application. Mount the directory containing your cook asset and load it in your runtime application.

    This requires that your runtime application has access to a computer with a UEditor to trigger the preparation.

    Comment


      #3
      Hello Frinalal!
      Im looking for a very similar solution for ( I believe )very similar goals. Have you had any luck in that ? Im thinking of a more manual way to do this. Do you think modifying Unreal at source would help us ? The community seems clueless about this also. Feels like it was locked that way for some reason. What do you think ?

      Comment


        #4
        Hello all

        This is very similar to what I need to do. I m in ArchViz sector and we decided to move to unreal engine. What I want to do now is to create a "game" where by pressing a button we can load/import a datasmith file from external drive/folder (for example a room from sketchup or 3ds max) in runtime and start applying materials, meshes or textures that have been already implemented in the package. However I haven't found how a datasmith importer can be enabled (if it is possible) during runtime. Any idea or blueprints ?

        Comment


          #5
          Hello UE_FlavienP , thank you for your recommendation.
          Is it possible to provide us a small template to achieve that ?

          Comment


            #6
            Originally posted by deathbool View Post
            Hello Frinalal!
            Im looking for a very similar solution for ( I believe )very similar goals. Have you had any luck in that ? Im thinking of a more manual way to do this. Do you think modifying Unreal at source would help us ? The community seems clueless about this also. Feels like it was locked that way for some reason. What do you think ?
            What I ended up doing is to use Assimp and Rama's plugin to load a GLTF file from a specified folder and loading Assimp's mesh data into a procedural mesh component. The process usually takes less than 10 seconds but it relies on the file's UVs, tangents, smoothing groups, etc. Rendering can easily get very expensive as you get no LODs but it works for me at the moment. I'm also looking into Koderz Runtime Mesh Component as an alternative to UE4's procedural mesh component.

            I don't know if modifying UE4's source would work mostly because i don't have any C++ knowledge and I also think that the Datasmith importer was locked without reason, as every game engine has to internally process all 3D file formats to be able to "understand" them and optimize them.

            Sorry for the late response, I normally use my work account instead of the personal one I used to write this post.

            Comment


              #7
              Alright this is good for me,
              ["I've been working on a VR mechanical visualization tool and i'm looking for something that allows me to import meshes from an external file to the scene outside the editor and add it to a catalog."]

              I thought DATASMITH compiled all your imports into a computer language, so that there was no Interpreting what I am importing or reimporting during Runtime.

              what I am I thinking of? because that's what I want ~ I want a compressor, so that I don't need an interpreter, and I can just run it on an emulator. do these things even exist or are we actually all limited very rutidmentary Process Hogs in this field?

              lord_gord@msn.com
              please do send me the information, if there is a Compiler that I am looking for.

              it saves some 150-30% of your computing power during runtime.
              (im following this convo now.)
              think it might be DirectX... it s a real-pain of my **** to search through convoluted non-sense looking for the answer to my question. enough to make you think the industry is lasping: it can't be... sure we can run 30 million bytes per second, but its twice as much fkn work as necessary to not have a Compressor. is it DirectX or maybe DATASMITH?

              Comment


                #8
                Hello all !
                It'll be a hard work while there is no "CoreTech" module which is used by other CAD modules in source code.
                Source code :

                Code:
                // CAD library is only available if CoreTech is available too
                bool bHasCoretech = System.Type.GetType("CoreTech") != null;
                
                // Support for Windows only
                bool bIsPlateformSupported = Target.Platform == UnrealTargetPlatform.Win64;
                
                if (bIsPlateformSupported && bHasCoretech)
                {
                PublicDefinitions.Add("CAD_INTERFACE");
                PublicDependencyModuleNames.Add("CoreTech");
                }
                As bHasCoretech equal false, CAD_INTERFACE will never been defined, so many codes will be commented.

                Click image for larger version  Name:	Untitled.png Views:	0 Size:	104.6 KB ID:	1789431
                Click image for larger version  Name:	Untitled02.png Views:	0 Size:	93.1 KB ID:	1789435

                btw: anyone have the source code of "CoreTech" module ?
                Last edited by hamkoo; 07-17-2020, 07:26 AM.

                Comment

                Working...
                X