Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Unity cloud build and Blender

Discussion in 'Unity Build Automation' started by Skade88, Aug 19, 2020.

  1. Skade88

    Skade88

    Joined:
    Jan 2, 2017
    Posts:
    21
    Howdy Y'all!

    Does Unity Cloud Build support .blend files by any chance?

    Best,
    David Brooks
     
  2. ollieblanks

    ollieblanks

    Unity Technologies

    Joined:
    Aug 21, 2017
    Posts:
    459
    Hey David,

    Unfortunately, Cloud Build does not handle native .blend files. To use these models with a Cloud Build workflow you will need to export them to non-proprietary format like .fbx.

    Hope this helps!
     
  3. Skade88

    Skade88

    Joined:
    Jan 2, 2017
    Posts:
    21
    Thanks for the info! Is there a timeline for when .blend support will be added to Unity Cloud Build? The Unity editor and compiler on my local machine can handle the .blend files. Is it a big LOE to add that functionality to the Cloud Build tool, especially since it already exists in the Unity editor and compiler?

    Best,
    David Brooks
     
    UnityGio likes this.
  4. senjacob

    senjacob

    Joined:
    Mar 25, 2018
    Posts:
    4
    AFAIK, .blend file is a memory dump kind of file from blender. Blender only can load it back to memory. So the maximum integration point would involve opening a blender instance in cloud and load the file in that blender instance; then use some custom addons to export to standard file formats like obj or fbx to use it in Unity.
     
    Skade88 likes this.
  5. Skade88

    Skade88

    Joined:
    Jan 2, 2017
    Posts:
    21
    Interesting... I use my .blend files in Unity and they work in the editor and they get compiled in when I build locally. Is Unity just opening Blender in the background or something to make that work?
     
  6. senjacob

    senjacob

    Joined:
    Mar 25, 2018
    Posts:
    4
    They might be.
    \Editor\Data\Tools\Unity-BlenderToFBX.py actually contains blender scripting apis in it.

    Code (JavaScript):
    1. import bpy.ops
    2.     bpy.ops.export_scene.fbx(filepath=outfile, ...
     
  7. Whatever560

    Whatever560

    Joined:
    Jan 5, 2016
    Posts:
    505
    Any way to automate this ? Maybe thanks to \Editor\Data\Tools\Unity-BlenderToFBX.py ?
     
    Waz and Skade88 like this.
  8. Whatever560

    Whatever560

    Joined:
    Jan 5, 2016
    Posts:
    505
    I'm using another method now, from https://github.com/jonathanleang/blendToFbxExporterForUnity that I execute in my CI pipeline before unity.
    I'm still having some visual issues with the shaders/lightning but the models and textures are here and working.
    I guess I'd probably need to reimport prefab that includes the blend files in the build process or something like that
     
  9. cyberscorpia_unity

    cyberscorpia_unity

    Joined:
    Dec 15, 2017
    Posts:
    3
    Has there been any evolution in this?
    I am facing the same problem.