Package com.biodigital.humansdk
Interface HKHumanInterface
public interface HKHumanInterface
Callback functions for the 3D Scene
-
Method Summary
Modifier and Type Method Description voidonAnimationComplete()Called when the current is done runningvoidonAnnotationCreated(java.lang.String annotationId)Called when a new annotation is created in the scenevoidonAnnotationDestroyed(java.lang.String annotationId)Called when an annotation is destroyed in the scenevoidonAnnotationsShown(java.lang.Boolean isShown)Called when annotations are shown or hidden in the scenevoidonAnnotationUpdated(HKAnnotation annotation)Called when the annotations screen position has changedvoidonCameraUpdated(HKCamera camera)Called when the camera moves in the scenevoidonChapterTransition(java.lang.String chapterId)Called when a new chapter is loaded by the scenevoidonModelLoaded(java.lang.String modelId)Called when loading is complete for a scenevoidonModelLoadError(java.lang.String modelId)Called when an error has occurred during loading for a scenevoidonObjectColor(java.lang.String objectId, HKColor color)Called when an object's color is retrievedvoidonObjectDeselected(java.lang.String objectId)Called when an object is deselected in the scenevoidonObjectPicked(java.lang.String objectId, double[] position)Called when an object is picked by the uservoidonObjectSelected(java.lang.String objectId)Called when an object is selected in the scenevoidonObjectsShown(java.util.Map<java.lang.String,java.lang.Object> objects)Called when a set of objects are shown or hidden in the scenevoidonSceneCapture(java.lang.String captureString)Called when a scene capture is completevoidonSceneInit(java.lang.String title)Called when the scene is initialized and metadata is availablevoidonSceneRestore()Called when the scene is restoredvoidonScreenshot(android.graphics.Bitmap image)Called when a screenshot is returned from the SDKvoidonTimelineUpdated(HKTimeline timeline)Called when the timeline has been updatedvoidonXrayEnabled(java.lang.Boolean isEnabled)Called when xray mode is enabled or disabled
-
Method Details
-
onModelLoaded
void onModelLoaded(java.lang.String modelId)Called when loading is complete for a scene- Parameters:
modelId- String id of the loaded model
-
onModelLoadError
void onModelLoadError(java.lang.String modelId)Called when an error has occurred during loading for a scene- Parameters:
modelId- String id of the loaded model
-
onObjectSelected
void onObjectSelected(java.lang.String objectId)Called when an object is selected in the scene- Parameters:
objectId- String id of the selected object
-
onObjectDeselected
void onObjectDeselected(java.lang.String objectId)Called when an object is deselected in the scene- Parameters:
objectId- String id of the selected object
-
onObjectsShown
void onObjectsShown(java.util.Map<java.lang.String,java.lang.Object> objects)Called when a set of objects are shown or hidden in the scene- Parameters:
objects- a Map of object IDs and boolean values for shown/hidden
-
onChapterTransition
void onChapterTransition(java.lang.String chapterId)Called when a new chapter is loaded by the scene- Parameters:
chapterId- String id of the current chapter
-
onAnimationComplete
void onAnimationComplete()Called when the current is done running -
onScreenshot
void onScreenshot(android.graphics.Bitmap image)Called when a screenshot is returned from the SDK- Parameters:
image- Bitmap representation of the saved screenshot
-
onSceneInit
void onSceneInit(java.lang.String title)Called when the scene is initialized and metadata is available- Parameters:
title- the scene title
-
onXrayEnabled
void onXrayEnabled(java.lang.Boolean isEnabled)Called when xray mode is enabled or disabled- Parameters:
isEnabled- true if enabled
-
onSceneRestore
void onSceneRestore()Called when the scene is restored -
onTimelineUpdated
Called when the timeline has been updated- Parameters:
timeline- the HKTimeline object
-
onAnnotationCreated
void onAnnotationCreated(java.lang.String annotationId)Called when a new annotation is created in the scene- Parameters:
annotationId- the ID of the new HKAnnotation object
-
onAnnotationDestroyed
void onAnnotationDestroyed(java.lang.String annotationId)Called when an annotation is destroyed in the scene- Parameters:
annotationId- the ID of the destroyed HKAnnotation
-
onCameraUpdated
Called when the camera moves in the scene- Parameters:
camera- the updated HKCamera object
-
onObjectPicked
void onObjectPicked(java.lang.String objectId, double[] position)Called when an object is picked by the user- Parameters:
objectId- the ID of the objectposition- the 3D position of the picked object
-
onAnnotationsShown
void onAnnotationsShown(java.lang.Boolean isShown)Called when annotations are shown or hidden in the scene- Parameters:
isShown- true if annotations are shown
-
onAnnotationUpdated
Called when the annotations screen position has changed- Parameters:
annotation- the updated HKAnnotation object
-
onObjectColor
Called when an object's color is retrieved- Parameters:
objectId- the ID of the objectcolor- the HKColor of the object
-
onSceneCapture
void onSceneCapture(java.lang.String captureString)Called when a scene capture is complete- Parameters:
captureString- the saved data as a Json String the capture can also be retrieved as a Map object with HKScene.captureJson
-