WPF C# AB3d animation - c#

I need to do a 3d project in WPF in my school, I wanted to do a very complex animation. So I checked out the ab3d software, where you can export animation to 3ds file and convert them. But I try again and again to export 3ds file from blender with animation, I keyframed it, and it doesn't work. but their example files are working, and when I import them to blender, no animation exits.
Can someone help me understand how I export 3d animation to 3ds file?
here are some pics for with animation and without.
links to the files: Without With
(I want to mention that when I import the file back to blender, no animation)
without:
with:

I know a long time has passed but I had figured it out.
It appears to be that blender 3ds exporter for some reason can't export animation in 3ds format.
Therefore to solve it you need to transfer your model to other programs, like 3ds,
and only their animate, then export your model as a 3ds file.
Works like a charm:)

Related

How to create a scene without the Unity 3D editor

I have the following problem:
I have a 3D engine that has their scenes, but they are not compatible with Unity.
But I have the metadata of this another 3D engine about everything on the scene, like: position, lights, models, light probes, physics, cameras etc...
I'd like to recreate this scene on Unity, but programmatically doing a parser onto this metadata I have, but not using the Unity Editor. (In the end I would have a .scene file and some created prefabs)
But in the same time I'd like to be able to load this created scene (from the metadata) inside the the Unity Editor (since I created it for Unity now)
I would like to have all the models and things created as prefabs to be able to use addressable in the future.
Is this feasible?
Maybe is there a way to create UnityYAML scene files?
It looks like this would sort of be a 2 step process:
Parse your existing data structure and create them as GameObjects/Components in a scene. You should be able to do this with a regular ol' script attached to a regular GameObject. For me, I would call it something like "CustomSceneLoader". On start, read your data file, parse it, and instantiate GameObjects with that data.
From there, it looks like you can use the PrefabUtility to create new Prefabs based on the GameObjects in the scene. Maybe as part of step 1 you attach a custom Component that adds a button to the inspector that would create a Prefab from the GameObject.
For example:
PrefabUtility.SaveAsPrefabAssetAndConnect(gameObject, localPath, InteractionMode.UserAction, out prefabSuccess);
As Retired Ninja mentions in the comments
UnityYAML is just based on YAML which is a raw text file format (similar to JSON)
=> Of course in theory you can generate such a file and all your content prefab and .meta files and GUIDs from scratch completely without Unity.
Which basically would mean you have to replicate this entire part of the Unity Editor.
Is this feasible?
In theory yes, but the question is, is this really worth the time and struggle? I would doubt that.
Instead depending on your exact file formats I would rather
Search for any plugins / external libraries that maybe already exist for this file format
If really non exists you again have multiple options
From your other engine which already understands your existing file formats export the content into a format Unity understands built-in
For example
Export all meshes as FBX (-> already supports embedded materials, textures and hierarchy)
Export the hierarchy e.g. as a JSON or whatever text file
Then in Unity reconstruct the scene according to those
Implement your own custom Scripted Importer which can directly parse your original file(s) and convert it(them) into a scene directly within Unity.

Read, modify, and display .STL file 3D model using c#

I used Solidworks to build a 3D model and save as a .STL file. I would like to use C# to read the file and change the data while displaying the model.
Can any one give me some references?
Any help would be greatly appreciated.
Thanks in advance.
You may user batu92k's STL Viewer.
Project url is below.
https://github.com/batu92k/STL-Viewer
And also you may open stl in a text editor and modify the file by changing related parameters.

Extract voxel coordinates from file

I'm making a game in Unity C# and need to extract voxel position (and ideally color) from my MagicaVoxel editor which saves it's files in the .vox format, and can export in a few other ones.
I'd think it's best to extract this information from the .vox files, but none of my text editing programs could decern it's encoding.
Does anyone know how exactly I should go about getting this data?
Here's the answer in case someone is still interested: with the export option you can save it in the .ply format (click 'point' - export point clouds). If you open the .ply file with a text editor, you will find the coordinates and the associated RGB values.

Blender file import assimp

I want to import a blender file using Assimp (in c#), all classic format like .obj works.
I saw here that the better way to do it is to convert the blender file in one more usual, like obj.
You need to open your file .blend and export it to .3ds, .obj etc.
How do you load Blender files using Assimp?
But my question is how can I convert it, I searched in Assimp Documentation, there's nothing for convert and I can't import blender file so I can't export it in another kind.
I search for another library but I also find nothing.
You can run Blender via command line, allowing it to run a python script, to open .blend, then export to another format, then run that through a custom assimp process you were trying to do. Not sure your target format, but you could also just have blender go right to that instead of assimp.
This is something semi-similar, but you will need to connect the dots.
http://indygamedev.com/blender/automating-fbx-model-export-process/
Use Blender 2.79 (not 8.x).
Pack all textures, then save the *.blend to your data directory.
Then unpack all images which will put them in "textures*.*".
Resave the file after the Unpack -
Assimp should now see your textures.

Creating my own FBX files for XNA? (in 3ds max)

I'm now reading this example. I see there is one FBX file and a few texture files in the content project, and that in the code you can choose which "take" to play. In the code it is "Take_001". Please tell me: When I create and animate my own 3D model in 3DS Max, how can I define those takes? plus, are any configurations need to be made when exporting FBX from 3DS Max to XNA?
You don't. The model artist does. In his modeling software he can name every bone or animation sequence, and then you can activate it from code.
The built-in FBX pipeline in XNA supports animation only partially, but it doesn't need any pre-configuration. So does the pipeline you linked to.

Categories

Resources