google-ar / sceneform-android-sdk

Sceneform SDK for Android
https://developers.google.com/sceneform/develop/
Apache License 2.0
1.23k stars 604 forks source link

Load SFB at runtime (without Sceneform plugin/gradle combo) #636

Closed fzaiatz closed 5 years ago

fzaiatz commented 5 years ago

Is it possible to generate a SFB file outside of Android Studio? Something like a Blender plugin / a console script, so we can load SFB models at runtime (taking advantage of model animations for instance).

bobekos commented 5 years ago

You can use the converter also outside of android studio. Check this here: https://github.com/gdamoreira/google-ar-asset-converter

tpsiaki commented 5 years ago

Currently the only supported way to generate SFBs to use the Sceneform gradle plugin (either inside an android studio project, or in a standalone gradle build).

As pointed out by @bobekos, there is an underlying command line tool that gets called by the Sceneform plugin. When you run a gradle build using the Sceneform plugin, right now the command line tool is unzipped into the build/sceneform_sdk directory and could theoretically be used directly. Note a couple of important details with the converter command line tool:

fzaiatz commented 5 years ago

Thanks @bobekos for linking to the converter, didn't know about that one. Also thanks @tpsiaki for those notes about it :)

jungwonwoong commented 4 years ago

your_project_work_directory\app\build\sceneform_sdk\windows\converter.exe

windows10 cmd bat file

convert.bat.txt

%1 : output folder name %2 : .obj file name in input dir

ex) C:....\sceneform_sdk\windows\convert.bat output andy.obj