1
$\begingroup$

I hope I'm asking on the right StackExchange site. Apologies if I'm not.

I want to generate 3D triangulated models of optical lenses, circular in shape. I can create the meshes for the front and back surface. I'm having trouble creating the triangles for the sides of the lenses (as the front surface is a certain distance from the backside, also on the sides). I want the vertices of the front and back surfaces to be on a rectangular grid (z=f(x,y) where (x,y) are on the grid). That means the sides will have to deal with the "staircasing" that exists because of clipping the front and back on the rectangles of the grid.

How do I select which vertices (on/near the edge) of the front and back surfaces to use for the lens sides?

That appears to be not as easy as I thought. For instance, taking the vertices that are within "lens radius" and "lens radius minus sqrt(grid spacing)" from the center doesn't work. Similar other tries didn't work out either.

To be a little more clear: the front and back surface are perfectly aligned and share the same grid for their x and y coordinates. Therefore the sides are always vertical.

$\endgroup$
  • $\begingroup$ Circles don't pass through grid points nicely - with the exception of some pythagorean triples. So you're going to have to relax your requirements. You'll have to adjust the topology of your surface to tessellate the quads of your grid with triangles that transition from the front to the side. $\endgroup$ – Wyck Feb 6 '18 at 20:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.