Releases: google-ar/sceneform-android-sdk
Sceneform SDK for Android v1.6.0
Breaking changes
- Deleted classes and methods that were marked as deprecated and to be removed in v1.6.
- Removed
Scene.setOnPeekTouchListener
, useScene.addOnPeekTouchListener
andScene.removeOnPeekTouchListener
instead. - Removed
Scene.setOnUpdateListener
, useScene.addOnUpdateListener
andScene.removeOnUpdateListener
instead. - Removed
ViewRenderable.getPixelsToMetersRatio
,ViewRenderable.getMetersToPixelsRatio
, andViewRenderable.setPixelsToMetersRatio
. Instead, useViewRenderable.setSizer
andViewRenderable.getSizer
. - Removed
TransformationGestureDetector
interface andTransformationSystem.getGestureDetector
. Instead, use theTransformationSystem
directly to access gesture detectors. - Removed
Renderer.captureScreenshot
. Instead, use Android's pixelCopy API or the new API for mirroring the SceneView to another surface.
- Removed
New APIs and capabilities
- Added Video Recording sample to demonstrate how to use Sceneform surface
mirroring to record a video of the Sceneview. - Sceneform UX source code is added to the maven repository in addition to GitHub.
- Added video recording support via mirroring of
SceneView
contents onto another Surface, such as a surface provided byMediaRecorder.getSurface()
- Automatically modulates sun color and indirect diffuse color using ARCore light estimation color correction value by calling
Scene.setLightEstimate
internally.
Other changes
- Chroma Key Video sample updated to optionally disable the Chromakeying and display the entire video.
Bug fixes
- Fixes a bug where Android resources could not be loaded in dynamic feature modules.
- Fixes a bug where a Node would receive touch input for a gesture even after it was handled by
Scene.OnTouchListener
. - Fixes a bug where
ACTION_POINTER_DOWN
would only be dispatched to a node if the motion event touched a node. - Fix memory leak in
Texture.setSource(Bitmap)
Sceneform SDK for Android v1.5.1
Bug fixes
- Fixed a rendering issue with calculating normals.
Sceneform SDK for Android v1.5.0
Sceneform UX source code
- Sceneform UX source code is now available from the
sceneformux
folder. This will enable developers to extend or make customizations to the UX library. We are currently not accepting Pull Requests.
Breaking changes
- Removed the method
Node.onTap()
. This doesn't change functionality, but will break if a subclass overrode it. Instead, useNode.setOnTapListener
. - Removed
Texture.isReady()
. TheCompletableFuture
status should be used to determine if the texture is ready to use.
New APIs and capabilities
- Added an assets library,
com.google.ar.sceneform:assets
that can be optionally included in an app and used to convert models from glTF to SFB in an Android app.- Use
RenderableSource
as the source when building aModelRenderable
.
- Use
- Added ability to load assets that are in the root of the project. URIs that start with
file:///android_asset/
will now work. - Added
FrameTime.getDeltaTime()
andFrameTime.getStartTime()
to provide provide frame timing in anyTimeUnit
.
Deprecations
None.
Behavioral changes
- When ARCore needs to be installed or updated, AR Optional apps will no longer display an initial screen informing the user that ARCore is required and instead immediately show the install screen.
Other changes
- Removed Javadoc for internal implementations methods incorrectly exposed in
Camera
,Scene
, andBox
.
Sceneform SDK for Android v1.4.0
Breaking changes
None.
New APIs and capabilities
-
Sceneform now supports OpenGL ES 3.0, enabling it to run on the Android Emulator on macOS.
-
Added SFA attribute
recenter:"root"
to reposition an imported object such that its lowest point is positioned at the height of the local origin so that it can be easily attached to a plane. This is now the default when a new model is imported. -
Converter support for the glTF/2.0
KHR_materials_pbrSpecularGlossiness
extension. Note, materials using this extension will currently be less performant than if they use the metallic-roughness model. -
Added API
Scene.addOnUpdateListener
making it possible to connect multiple update listeners to the scene. -
Added API
Scene.addOnPeekTouchListener
making it possible to connect multiple peek touch listeners to the scene. -
Added API
Node.LifecycleListener
andNode.addLifecycleListener
which is used to be notified when a node is updated, activated, or deactivated. -
Added class
BaseTransformableNode
that can be subclassed to createTransformableNode
s with custom transformation controllers. CalladdTransformationController
from the subclass constructor to hook up the transformation controller to the node. This helps ensure that only one transformation controller will be transforming the node at a time. -
Added API
TranslationController.setAllowedPlaneTypes
to control which types of planes aTransformableNode
can be translated on. -
Added API
TransformationSystem.setSelectionVisualizer
andTransformationSystem.getSelectionVisualizer
. -
Added API
TransformationSystem.addGestureRecognizer
andTransformationSystem.getGesturePointersUtility
which can be used to add custom gestures to theTransformationSystem
, either by adding them directly or subclassingTransformationSystem
. If you subclassTransformationSystem
, you should also subclassArFragment
and overridemakeTransformationSystem
to instantiate your subclass.
Deprecations
TransformationGestureDetector
has been deprecated and will be removed in Sceneform 1.6.0. The functionality has been merged intoTransformationSystem
.Scene.setOnUpdateListener
will be removed in Sceneform 1.6.0. UseScene.addOnUpdateListener
andScene.removeOnUpdateListener
instead.Scene.setOnPeekTouchListener
will be removed in Sceneform 1.6.0. UseScene.addOnPeekTouchListener
andScene.removeOnPeekTouchListener
instead.- The Screenshot API is unsupported and will be removed in Sceneform 1.6.0. For an example of how to capture screenshots, see the Codelab for Sceneform.
Behavioral changes
- Newly imported models will have the new
recenter:"root"
SFA attribute applied, which repositions them such that their lowest point is at the height of the local origin, so that they are more easily anchored to planes.
Other changes
None.
Bug fixes
- Fixed an issue where the camera stream would appear over saturated.
- Fixed an issue where all file URIs were treated as assets. Files stored in device storage can now be loaded using a URI.
- Fixes support for
int
/bool
parameters in custom materials.
Sceneform SDK for Android v1.3.0
New samples
- Added Augmented Image sample to demonstrate using Augmented Images with Sceneform.
Breaking changes
- Rebuilding old glTF Sceneform models may result in different scales and translations, and your glTF may need to be modified.
New APIs and capabilities
- Binary format conversion supports the glTF/2.0 extension
"KHR_materials_unlit"
. TransformableNode
will now work with vertical planes.SceneView
can now be used instead ofArSceneView
to render a scene when not using ARCore.- The camera can be moved and rotated via
SceneView.getScene().getCamera()
.- The initial camera transform is currently not defined and likely to change in future releases. Make sure the camera position and orientation is set when the view is created.
SceneView.setBackgroundColor()
or theandroid:background
property can be used to control the background color of the scene.
- The camera can be moved and rotated via
Deprecations
None.
Behavioral changes
TranslationController
will start translation when dragging a child of theTransformableNode
, not just theTransformableNode
itself.- Transparent
Renderable
will cast a shadow (if it is a shadow caster).
Other changes
- Private construtor added to
DemoUtils
class, since it only has static methods. - If a sample is run on a device that can't support AR a popup will appear and the activity will finish.
Bug fixes
- Binary format conversion will pre-transform model vertices in order to support glTF models with node transform hierarchies.
- Fixed support for
smoothing_angle
property in glTF/OBJ files. - Fixed support for
flip_texture_coordinates
property in FBX files. BaseArFragment
will no longer request permissions it already has.ArFragment
can now be loaded dynamically and added to an existing container.- Fixed logging on ARCore initialization errors.
- Fixed bug in
BaseTransformationController
,setEnabled()
was ignored if called beforesetParent()
. - Fixed a bug that caused the plane visualization to not display on
HORIZONTAL_DOWNARD_FACING
planes. Renderable.setMaterial()
was always throwing an exception. Now it only throws on error.ViewRenderable
colors reflect theView
more accurately now. Previously, they were slightly washed out.- Fixed a bug where the index offsets were wrong when building a
Renderable
with aRenderableDefinition
with multiple submeshes. - Fixed bug that caused the camera feed to render incorrectly on Samsung Galaxy S9 and S9+ devices with a Qualcomm processor.
Known issues
Runtime
- The initial camera transform of the non-AR camera (
SceneView.getScene().getCamera()
) is currently not defined and likely to change in future releases. Make sure the camera position and orientation is set when the view is created.
Sceneform SDK for Android v1.0.1
This updates the samples to use version 1.0.1 of the Gradle plugin to convert models to the Sceneform binary format. Version 1.0.1 addresses issues found when building in a Linux environment. Refer to the 1.0.0 release notes for other information.
Sceneform SDK for Android v1.0.0
Known issues
Runtime
- The
ArSceneView
must be setup with an Sceneform Session that is configured to use theLATEST_CAMERA_IMAGE
update mode. See ArSceneView.setupSession(). - Sceneform requires GLES 3.1+ to run. Currently, this means that Sceneform applications will not run in the Android Emulator on macOS.
- Sceneform only supports
ARGB8
image formats. ViewRenderables
don’t currently cast shadows.- View doesn’t start rendering until resources requested in
onCreate()
have finished loading. This may be an issue when loading assets over the network. As a workaround, delay lengthy resource loads untilonResume()
orupdate()
. See Scene.setOnUpdateListener().
Google Sceneform Tools Android Studio plugin
- Within
*.sfa
Sceneform asset files, thecenter
andsize
attributes insuggested_collision
are currently unused. Instead, the collision shape is currently always a bounding box matching the geometry inflated by theskin_width
(defaults to zero). - On macOS, stretching the viewer so that it is wider than your monitor can cause performance issues.
- Opening an
*.sfb
Sceneform bundle file that was built outside of the current project build will result in the*.sfb
binary file being loaded in the text editor, rather than the corresponding*.sfa
text file. We recommend re-importing source models into the project rather than copying over*.sfb
's. - If you import and your gradle project build does not reference the
google()
maven repository, your build will fail, and not be reverted. You may fix this build failure by adding thegoogle()
repository to your root build.gradle dependencies. - Lighting environment reflections appear different when previewed in the Android Studio plugin compared to how they appear at runtime.
3D model formats
- Sceneform currently does not support glTF extensions.
- When glTF file dependencies are missing, the plugin prints a generic error saying "No suitable reader found for the file format". This indicates that not all dependent files are present.
- Transform hierarchies in glTF models are ignored on import. Consequently, importing a glTF model with a transform hierarchy will result in all submeshes being drawn with an identity transform (i.e. at the model origin with no rotation)
Gradle plugin
- When a change in the source asset requires a new
*.sfa
file, e.g. if the model has updated material parameters, the plugin will print a warning saying "run with --in_place". We recommend that in this case, you delete the*.sfa
file and rebuild, causing the*.sfa
to be regenerated by the gradle plugin.