DesignCAD 3D Max 2027 box
Now available

DesignCAD 2027

Hatches that follow their boundaries, an on-screen dial to turn your model, and a way to find any command by name, in a clean Windows 11 look.

Rendering problems

Started by adriank, June 26, 2012, 09:38:50 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

DrollTroll

Non-planar grid facets are allowed for the sake of efficiency. Say you have a grid of 10 grid lines, each with 10 points per line. Points 1 and 2 of line 1 attach to points 2 and 1 of line 2, then back to point 1 of line 1, forming one "quad" facet. Similarly, points 1 and 2 of line 2 attach to points 2 and 1 of line 3, and so forth. No matter how you twist the points of that grid, the point relations for each facet remain the same, and the 10x10 grid with 81 facets only takes up 100 points in the database. If you split that grid into discrete triangles, you have 162 triangles, each with 4 points, giving you more than 6x the original 100 points, plus all the overhead data for 162 discrete entities (layer, color, material, etc).

I'd certainly like, someday, to have another surface type that allows for a more efficent representation of any collection of facets (be they quads, triangles, or other polygons) as a surface, without requiring the row/column data format that grids require.
25 years with DesignCAD

prl

Quote from: Bob P on June 29, 2012, 02:40:45 AM
IMHO, this is an inherent problem with grid "planes" that are actually non-planar.  Why does DC even create them?

I'm guessing here but much of DesignCAD was invented when holding data in memory was limited.  That is why I think we have index numbers for layers and a great many things. This approach was great in the 80s but has been causing headaches for me since.

For grids, a rectangular grid seems to be internally programmed to automatically be two planar triangles with the diagonal always hidden.  A space saving invention I'm thinking.  Problems occur, however, when a rectangular grid is exploded and it becomes an improper rectangular plane (a five point plane, 1st and last point the same) which is in fact not planar because the 4th point is out-of-plane.  Think of a piece of plywood with one corner pulled up.  To be proper, it should explode into two triangular planes but it doesn't.

Years ago I wrote some code that will take exploded grids and triangulate the 5 point grid panels.  If someone needs it, I'll dig into my files.  Can't remember why I wanted or needed to do that.

Bob P

I'm curious how DC defines the plane defined by a grid entity.  I mention this because I'm trying to do the actual math for a corrected Snap to Plane.  The current command will snap to an edge if no real perpendicular exists from the point to an existing plane.  It's pretty weird to me that DC won't use the virtual plane rather than the actual one.  I think the former is more useful.

My original macro was to create a parallel plane by distance.  Something that requires that you set the direction so that any Planesnap is directly above the existing plane.

Dr PR

prl is correct about rectangular grid facets actually being created from two triangles with the common hypotenuse hidden. You can demonstrate this in two ways:

1. Create a plane that intersects a grid and crosses at least one entire rectangular facet. Use the Surface Intersect function to find the intersection line between the plane and the grid. Select this line in Point Select mode - notice all the extra points that just happen to fall along an invisible line between opposite corners of the facet. These points are on the hidden hypotenuses of the triangles.

Years ago DesignCAD didn't place all of these intermediate points in the surface intersect line. Was this a change in the surface intersect routine, or were facets originally warped four point planes and later changed to be two triangles?

2. Define a grid to be a solid and then subtract another solid from it. The original grid will explode into a plethora of triangles, with no hidden edges. The file size will also explode.

****

I have mixed feelings about the ability to move a point of a plane so it is warped into a non-planar shape. I used to think this was a really cool feature of DesignCAD, far advanced beyond rather limited capabilities of other programs. It made for smaller file sizes and it was easy to close gaps between non-coplanar surfaces without adding extra filler planes.

This feature also allowed the early DesignCAD to do things that much more expensive programs could not do, such as helical surfaces.

Shadows changed all of that. Non-planar surfaces cause many rendering problems, including stray shadows. I found that many of my 3D models from older versions could not be shaded with shadows because of the stray shadows that were caused by the non-planar surfaces. It took a very long time to discover the cause of these errant shadows, and a huge amount of wasted time.

Non-planar surfaces can also cause the Solid Boolean operations to behave unpredictably, and there are other rendering issues.

Now I avoid non-planar polygons like the plague! Unfortunately, it is all too easy to accidentally bend a polygon out of plane in Point Select mode. This is truly a user beware feature! There is no easy way to ferrit out non-planar polygons.

Phil
DesignCAD user since 1987

prl

#19
Quote from: Bob P on June 29, 2012, 10:45:34 AM
I'm curious how DC defines the plane defined by a grid entity.  I mention this because I'm trying to do the actual math for a corrected Snap to Plane.

I once studied grids trying to understand them and create them with Basiccad.  Like the Doc mentions in the previous post, they (grids) are unique to DesignCAD since you can draw for example two multipoint lines with say 8 points each and orient them oddly in 3d space and stretch a skin like Saran Wrap across them.  Not sure I'm answering question other than to say, grids aren't planes although they can be.  Clear as mud???

Edit:
In the other tread where someone wants to twist a beam, I posted some pics about how that could be done with lofting.  In the below attached pic, I took the last profile and reversed the point order. I also added the arrows to show how the grid line points are set.  All the rectangular faces you see are grid panels and they are NOT planes. They are actually two triangular planes each with the common diagonal hidden.