Skip to content

Filament 1.10.7 + New ArFragment Listeners + Selectable Nodes + Memory optimizations + Automatic Plane and AugmentedImages InstructionsController + Big clean on Trackables + ...

Compare
Choose a tag to compare
@ThomasGorisse ThomasGorisse released this 18 Jul 11:58
· 134 commits to master since this release
  • Filament 1.9.25 1.10.7
  • Added arFragment.setOnAugmentedImageUpdateListener(OnAugmentedImageUpdateListener listener)
    @Override
    public void onAugmentedImageUpdate(AugmentedImage augmentedImage) {    
        if (augmentedImage.getTrackingState() == TrackingState.TRACKING
                && augmentedImage.getTrackingMethod() == AugmentedImage.TrackingMethod.FULL_TRACKING) {

            // Setting anchor to the center of Augmented Image
            AnchorNode anchorNode = new AnchorNode(augmentedImage.createAnchor(augmentedImage.getCenterPose()));
            ...​
        }
    }
  • Added arFragment.setOnArUnavailableListener(OnArUnavailableListener listener)
    @Override
    protected void onArUnavailableException(UnavailableException sessionException) {
        String message;
        if (sessionException instanceof UnavailableArcoreNotInstalledException) {
            message = getString(R.string.sceneform_unavailable_arcore_not_installed);
        } else if (sessionException instanceof UnavailableApkTooOldException) {
            message = getString(R.string.sceneform_unavailable_apk_too_old);
        } else if (sessionException instanceof UnavailableSdkTooOldException) {
            message = getString(R.string.sceneform_unavailable_sdk_too_old);
        } else if (sessionException instanceof UnavailableDeviceNotCompatibleException) {
            message = getString(R.string.sceneform_unavailable_device_not_compatible);
        } else {
            message = getString(R.string.sceneform_failed_to_create_ar_session);
        }
        ...
    }
  • Internationalized default session initialization error strings
  • Added node.setSelectable(boolean selectable) for controlling what nodes can be hit by the hitTest.
    /**
     * Defines if the node can be selected within the
     * {@Link com.google.ar.sceneform.collision.CollisionSystem} when a touch event happened.
     * @param selectable true if the node can be selected
     */
    public void setSelectable(boolean selectable) {
        this.selectable = selectable;
    }
  • New automatic Plane and AugmentedImages InstructionsController visibility detection.
  • Fix AugmentedImage instructions visibility if AugmentedImageDatabase has no images to recognize.
  • Memory optimizations on the ARCore calls part.
  • Removed the abstract qualifier for some BaseArFragment functions to lightweight the override
  • Cleanup/simplified the Session creation and configuration
  • Big clean on Trackables
    • Centralized Session.getAllTrackbles() and Frame.getUpdatedTrackables(). For performance and consuming reasons.
    • PlaneRenderer takes an updatedPlanes parameter instead of also getting it from the frame
    • Global Trackables manager for filtering
    • PlaneRenderer and InstructionsController automatically disabled depending on the session.config
    • Augmented Image detection for InstructionsController is made from Trackables instead of AumgentedImagesDatabase