Hole in a curved surface

Previously, adding a hole in on a complex curved surface was not easy to do in Inventor. With the new Curve On Face feature in Inventor 2017, this has been made much easier. This is how it’s done:

-Start a 3D sketch.
-Select “Curve On Face”.
-Draw a 3 point spline on the surface, with the 4th connecting to the first one to close the loop.

hole on surface

-Finish the 3D sketch.
-Create a plane out of 3 points, using the 3 points from the spline.

hole on surface 2

-Create a 2D sketch on the plane.
-Add a circle on the 2D sketch and place it in the center of the spline points. The circle will be used to extrude the hole.
-Finish the 2D sketch.
-Create an axis by selecting “Normal to Plane through Point” and select the mid point and the work plane. This axis can be used later to align a screw.

hole on surface 3

-Add a work point to the center point. This will be used later to place a screw.
-Extrude the circle with a cut operation. You might have to extrude it both ways to create a clean cut.

hole on surface 4

-Hide the 3D sketch and the work plane, leaving only the hole, work point, and the work axis behind.

hole on surface 5

-Now you can add a screw, rod, etc in an assembly.

hole on surface 6

Advertisements

A320 CAD design

Here are some screenshots of the finished A320 cockpit CAD model. The CAD model is available for purchase. Please use the contact form at www.airlinetools.com for inquiries.

Experimental texturing of monitor in Substance painter:

monitor 2

Test of leather material in Substance Painter.

leather

Test of leather material (armrest) in Substance Painter:

leather 2

Throttle unit. The text is embossed into the geometry:

full 9

Some more screenshots:

full 8 full 7 full 6 full 5 full 4 full 3 full 2 full 1

CAD conversion pitfalls

When editing imported CAD data, there are several things to be aware of. CAD data uses explicit (custom) normals. Smoothing groups are not used at all. It is important that all explicit normals are maintained when editing the mesh, otherwise you are likely to get nasty shading errors.

There are three ways to check for shading errors:

-Check the normals.
-Check the shading look.
-Check for any back facing triangles using Views->xView->Face Orientation (shown in green).

The only way to view explicit normals is to add an “Edit Normals” modifier to the top of the stack, then adjust the Display Length (length of the vectors). The explicit normals are shown in green. Blue lines are unspecified normals which are calculated using averaging and you do not want to see those in a CAD model.

Unfortunately 3ds Max is very buggy maintaining explicit normals and not very helpful displaying any resulting shading errors. The main problems are:

-The way the default viewport shading works makes incorrect normals not very apparent.
-Some operations dump the explicit normals and replace it with unspecified normals.
-Some operations maintain the explicit normals but rotate them in some random direction.
-Some operations create double triangles (back facing and forward facing), which go undetected unless you view the vertex/triangle count.
-Importing an Inventor model as a body object will create flipped faces on mirrored features and in some cases even removes faces completely.
-Flipped triangles go undetected unless you use xView.

I wrote a script called InvToSP (Inventor to Substance Painter) which fixes all of these issues. You can find it here:
http://www.scriptspot.com/3ds-max/scripts/inventor-to-substance-painter

Here are some things to keep in mind if you want to do the conversion manually.

Some surfaces appear to be watertight but are actually separate surfaces. To fix this, you need to weld the vertices of all objects. This is done in order to reduce vertex count and to make sure the derived projection cage is correct, in order to prevent texture baking errors. There are several ways to merge vertices, but all of them destroy explicit normals, except this method:

-Convert the object to an Editable_Mesh.
-Add a ProOptimizer modifier with the following settings:
*Keep Normals = on
*Protect Normals = on
*Merge Vertices = on
*Threshold = 0.0
-Press Calculate on the ProOptimizer modifier.
-Collapse the stack. Note that this is important because if there are a lot of objects and you do the above steps in a script loop, PropOptimizer WILL fail without warning.

If Inventor objects (and possibly other CAD files) are imported into 3ds Max as a body object, some mirrored features will have back facing triangles. The only reliable way to fix flipped faces is to re-import the Inventor model as a mesh instead of a body object. But this will trigger another bug in 3ds Max. The wireframe can’t be made visible. To work around this, add a ProOptimizer modifier to the object and configure the settings as above. Then press Calculate and the wireframe will be visible if enabled.

When the CAD file is exported to an FBX file, all objects will have a transform which is not set at zero. Unity imports this correctly, but unfortunately Substance Painter do not and it is unlikely they will fix this. A workaround is to use a script called “reset_Xform_on_selected.ms”, available here:
http://www.hard-light.net/forums/index.php?topic=73720.0

In order to reduce draw calls, static objects need to be fused into a single object wherever practical. There are several ways to do this, but all of them destroy explicit normals, except this method:

-Execute the script “reset_Xform_on_selected.ms” on each which is to be fused. This prevents the explicit normals from pointing in the wrong direction after the mesh is fused.
-Convert all objects which need to be fused to an Editable_Poly. This prevents the explicit normals to be converted into unspecified normals.
-Select the first object which need to be fused.
-On the Editable Poly modifier, on the Edit Geometry rollout, select the little icon next to the Attach button (Attach List). Or click on the Attach button and then click on a second object you want to attach.

If you detach a surface, the normals will point in the wrong direction after you fuse the new object with another object. In order to prevent this from happening, you need to add an Edit Normals modifier to the detached object and make the normals explicit,  then collapse the stack. Now you can fuse the detached object with another object.

If you want to manually flip a surface, do this to prevent the loss of the explicit normals:
-Reset the Xform using “reset_Xform_on_selected.ms”.
-Convert it to an Editable Poly.
-Add an Edit Normals modifier.
-Select he Editable Poly modifier on the stack.
-Enable polygon selection and select the face you want to flip.
-Go to the Edit Polygons rollout and select Flip.
-Collapse the stack.

Another bug in 3ds Max occasionally causes holes in an imported CAD model. The only way to fix this is to adjust the mesh resolution slider to a different resolution, or re-import the model as a mesh instead of a body object.

Imported Inventor files contain materials which are incompatible with the FBX file format, and possibly other export file formats. This results in the loss of all materials, which will make a texture set disappear in Substance Painter. In order to fix this, you need to convert all materials to a standard material.