Closed marwie closed 1 year ago
Currently, three.quarks doesn't support raycasting yet. We may need to implement raycast
method in the batchRenderer to make it work. I briefly checked the layer code in threejs, and it only works on cameras and raycaster. We could will propagate the layer setting from particle system parameter to the batch renderer to support camera flow.
Supporting raycast is a different feature. Ultimately, if we want to support physics. we should probably migrate a significant part of code to WebAssembly or WebGPU.
Sorry I wasnt clear maybe: I want to set the layers on the batched meshes so that the three raycaster ignores them - because currently we get hits for the batched mesh geometry when raycasting the scene
Gotcha. yeah, we will support a layer setting to avoid hits soon. but the results are incorrect without a customized version of raycast on VFXBatch. I don't know if 1e9e40b209aa3a78379cb60fdf44086954d02b75 fix your problem
Ah cool - I think it would.
Hey,
is it possible to easily update and/or configure the
Object3D.layers
mask to a batched system? I don't want to exclude particles from being hit when raycastingMaybe here? https://github.com/Alchemist0823/three.quarks/blob/7efd8552ba6c8de511453052c1bc41e88388f8f0/src/VFXBatch.ts#L12