Is it possible to catch a signal when HeatmapMesh is fully rendered? (for animation purposes) #1832
-
Hi there! I am rendering a HeatmapMesh inside a VisCanvas, from @h5web/lib, with other components such as a TooltipMesh and other Annotations, in here: https://github.com/cnpem/arara/blob/main/image-viewer-web/src/components/viewer/Viewer.tsx I have been requested to display these images in an animation style with a logic such as: So that users can visualize their datasets more efficiently in a sort of time-lapse style. Thanks a lot in advance! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hello !
In your case, you can try to pass <HeatmapMesh
values={valuesArray}
domain={domain}
scaleType={scaleType}
colorMap={colorMap}
visProps={{onAfterRender: ...}}
/> I never used this callback myself so be please do tell if it works for you or not. |
Beta Was this translation helpful? Give feedback.
Hello !
HeatmapMesh
uses Three.js'Mesh
underneath (via aVisMesh
abstraction). All Three.js'Object3D
have aonAfterRender
callback property, which might do the trick: https://threejs.org/docs/?q=mes#api/en/core/Object3D.onAfterRenderIn your case, you can try to pass
visProps
with an adequateonAfterRender
property:I never used this callback myself so be please do tell if it works for you or not.