Closed zhaishengfu closed 3 years ago
You could use the CPU to read the pixels from the particles simulations, and use the CPU to integrate the "particles to player" (point 2) collision logic. As for the "player to particles" (points 1 and 3) collision logic, you could pass the player position from the CPU to the shader, and do your computations on the GPU.
Hello, do you have any ideas for doing player sprite collision with sand simulation?? for example:
The way I can think is read character pixel from viewport, and when the pixel is character, do collision logic. But I can not think clearly the logic