geom3d
Library to handle 3D geometric primitives: create, intersect, display, and make basic computations
Author: David Legland

Hey David,
It seems that the functions:
intersectRayPolygon3d
intersectLinepolygon3d
Don't work properly.
I have a rectangular 3D polygon (fairly simple, like an elongated cube) defined by both the vertices and the planes of it's sides.
A line or a ray, with a location in the middle of it in ANY direction should generate an intersection point. This does not work. Not for a line nor a ray.

@Johannes,
The new set of faces refer to indices of vertices actually used by the faces. So it is necessary to use the following syntax:
[V2 F2] = mergeCoplanarFaces(vertices, K);
drawMesh(V2, F2);
The demo file is somewhat outdated, I will update it, and fix the doc of the mergeCoplanarFaces function.
Concerning the tolerance value, it is used for comparing normalised normal vectors of planes containing faces. There can be some numerical issues, but using 1e-4 should be fine.
regards,
David

Comment only

16 Jun 2014

geom3d
Library to handle 3D geometric primitives: create, intersect, display, and make basic computations

Hi Chien Ting,
thanks, this is fixed! Yes, if you have any more updates, I an include them. Do not hesitate to contact me by email (on my author page)
regards,
David

Comment only

03 Jun 2014

geom3d
Library to handle 3D geometric primitives: create, intersect, display, and make basic computations

I've been using your toolboxes for years, thanks for some great tools.
In drawEdge3d.m, line 29, I believe is a bug, it would never get executed. The correct line might be:
elseif nargin >= 6;
Also I've complete the documentation of drawEdge3d.m for my group's use. If you want see/use my version, let me know!
Thanks for some great tools!

Comment only