Hi all, I'm new here. I'm trying to find out if it's possible at all to stream unique meshes in Unity for playback at a reasonable frame rate. Say 24fps. By stream I mean load in on a per frame basis, or switch on or off in sequence. Say if you have "body-scan-0001.obj" "body-scan-0002.obj" "body-scan-0003.obj" "body-scan-0004.obj" etc with controls for frame rate, looping etc Is there a tool or Unity store asset currently available for this? could it be scripted? Ideally some kind of native built in solution could be quite powerful i.e. alembic support streaming in from a folder. Perhaps there is somewhere I could post to get help with this? Here's a good example using Thiago Costa's obj importer for Softimage: I've just learnt the basics of Unity over the weekend. Incredible application, very powerful. Thanks, Lee
It would totally depend on the network connection that the streaming's being done on. Unity doesn't provide anything that would do it directly, but I wrote an open source OBJ importer (that hasn't had much testing) and Eric5h5 sells one on the Asset Store as well. I know mine could import an OBJ from a stream (because I designed it to) and I imagine that Eric's could, too.
There is a system on the asset store that has support for industry point cache files ie pc2 mdd and mc formats, but that is for animating a mesh and maybe not what you need. What is it exactly you are looking to do?
OBJ files require quite a bit of pre-processing and interpreting, which can't really be done in real-time unless the models are fairly simple. A custom format that used binary data which mirrors Unity's mesh format would probably be some orders of magnitude faster. --Eric
We are in the process of adding a system like this to MegaFiers, we have been looking at the Alembic format which is quite complex but would be good to support and doing offline processing of OBJ files to a custom format as well as a plugin for Max to record complete scenes but it is a little way off. As Mike said above there are systems that can do full point cache playback, but it does really depend on what it is that you are needing to do.
Many thanks for the replies. What I'm looking to do initially is just play back animation, swapping out .objs quickly. Maybe an interim solution would be some kind of script to flip through the naming _001.obj, _002.obj by turning them on or off. Perhaps 15-35k polygon meshes. 24 to start with then scale up. I wouldn't imagine Unity would have a hard time loading these into the scene, hidden then flip through them in a loop? but it's finding a tool / script to do that. Creating a script is out of my remit (something I would be happy to pay to be developed) but I can supply the data to test with. The ideal goal would be to stream in from disk, or from a cache. The goal is to play back motion scans in real-time and view them in VR. It's just a proof of concept. I have a cool hand animation captured here that could be a good test subject, 25k meshes, 15 frames, hand opening and closing.
The author of MegaFiers is adding support for import sequences of OBJ files, also with the option for creation a cache file for streaming at runtime.
Did another example showing the OBJ cache system. The cache file it creates is about 1/10th the memory use of all the OBJ files used to create it.
MegaCache has been submitted to the AssetStore so hopefully will be approved this week otherwise it is available now on our website www.megafiers.com
Just to say my system is available finally in the Asset Store and more info can be found on our website at http://www.west-racing.com/mf/?page_id=6219 I have attached the PDF of the docs which explains in detail the components included.