#Importing into swift

1 messages · Page 1 of 1 (latest)

violet epochBOT
#
Welcome to the help forum!

Please make sure to read #1021015331910713395 as it may answer your question!

Once your question has been resolved, please mark the post as closed by using the </close:1163944441741049897> command.

round aurora
#

Probably very hard, they use completely different rendering engines

charred stream
#

When you say “Swift Code”, what specifically are you referring to? Are you talking about an app written in the Swift programming language? If so, Blockbench is just like any other 3D modeling program (Blender, Maya, 3DS Max). Just export the 3D model from Blockbench to any format that you want to use in your Swift project. I’m using .glb for my Godot project. .obj is pretty widely supported, but doesn’t support animations.

#

It should work great. I am trying to avoid using Blender so I can streamline my workflow, but Blender can do any format conversions you need.

#

Right now I am using Blockbench with some Asset Forge models. Export from Blockbench with animations, then import directly into the game engine.

round aurora
charred stream
#

Once you export to any standard format it is up to the new software to determine how it is rendered. Blockbench creates very simple models and textures that can be handled by pretty much any renderer. I have tried the same models in Blockbench, Asset Forge, Blender, and Godot, and they all render pretty much identically if you use an unlit shader. Lighting changes things, but the model formats themselves work fine. Behind the scenes a model is just a collection of verts, edges, tris, normals, uv coordinates, and throw in a texture map or two with some metadata and you have the .obj format. .gltf, .dae, and .fbx have animation information as well, but they are portable, just like .txt or .json.

#

Short answer:
Step 1 - Export from Blockbench as .obj.
Step 2 - Import into Apple Scenekit or ARkit, or whatever library you are using for the Swift project.

charred stream
#

Importing is probably going to be the easiest part. What kind of an app are you building in Swift?

charred stream
#

👍 There should be plenty of resources to help the process.