now I can make cylinder shape with shader. But what I want to do is like picking up ice cream with an ice cream scoop. How can I do this?

What I did

What I want to do.

  • \$\begingroup\$ The first image is a vertex shader that rolls up the mesh? You'd probably have to define a scoop shape and apply that to the verts so they roll in a more rounded shape. Then write a fragment shader that gives the ice cream texture. Maybe applying a texture with some time-based distortion would work well enough? Not sure how to generate the overflow tufts at the edges of the scoop. I'd probably occasionally spawn additional pieces and scale them up as a first shot. \$\endgroup\$
    – idbrii
    Jun 8, 2022 at 20:41

1 Answer 1


Here's a sketch of how I'd approach an effect like that:

  1. When the scoop contacts the surface of the ice cream, spawn a decal at that position that overwrites the ice cream's normals to look like it's bulging (like a classic ground pound effect). As the scoop presses deeper, expand/increase the intensity of this decal.

  2. As the scoop passes a threshold depth, spawn/reveal an ice cream textured sphere just under the surface of the ice cream. Scale this sphere so it's a narrow spindle at first, lying perpendicular to the scoop direction.

  3. As the scoop moves, gradually grow the sphere back to uniform scale and slide it into position in the center of the bowl. While doing this, pan the ice cream texture along the sphere so it looks like the ice cream is rolling. Adjust the texture tiling so that the details remain the same size as the sphere gets bigger.

  4. Behind the scoop, extend the distortion decal into a ribbon, similar to drawing skid marks behind a car tire. You can use a parallax displacement effect in the decal shader to make it look like a concave hollow.

If you need to take multiple overlapping scoops out of the same ice cream surface (not specified in your question), then the decal fakery won't hold up, and you may want to draw the ice cream surface using a heightmap instead, like terrain. Where the scoop travels, lower the heights in the heightmap to leave a trough shape.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .