Tag Archives: Realistic

A & B Tip 2 – realistic threads

In this series of posts, I’ll be providing tips that show how to do something in both AutoCAD and BricsCAD, hence A & B.

The Series

The idea behind this series is to provide useful information for several sorts of reader:

  1. AutoCAD users.
  2. BricsCAD users.
  3. People in the process of transitioning from AutoCAD to BricsCAD and who need to know what to do differently (if anything).
  4. People considering transitioning from AutoCAD to BricsCAD and who want to know about the differences and similarities.

Realistic Threads

This post explains how to create realistic-looking threads for screws, nuts and the like in your presentation 3D models. I don’t suggest you do this routinely because it will add pointless complexity to your everyday models, but occasionally you will need to make a model that looks highly realistic. For example, you might need a photorealistic rendering of an assembly or an exploded view for a user manual. This example will use ISO metric parts, but the principles are the same for all threads. I’ll assume you have a basic understanding of creating 3D primitives and the boolean operations (union, subtract and intersect).

BricsCAD Standard Parts

The first thing to note is that unless you insist on the threads being helical, you probably have very little work to do. Have a look at this ISO M10 screw and bolt. It doesn’t have helical threads, but is it good enough for your needs?

If so, and if you have BricsCAD Platinum, you can save yourself a lot of work. I created this model using the Standard Parts panel on the left. To create the nut, I used ISO > HEX NUT > ISO 4033 > M10 x 1.5. Having chosen my component, I just dragged and dropped it from the panel (the bit that’s highlighted above) into the drawing and specified an insertion point. The screw was similarly easy: ISO > HEX NUT > ISO 4018 > M10 x 1.5 and Length 50.

Here’s a close-up. This is good enough for most cases, but if you’re picky you can tell the threads aren’t helical. If you’re really, really picky you can tell that the threads aren’t the exactly correct profile (e.g. no flats on the peaks or troughs).

Also, getting really, really, really picky, there is neither a runout of the thread at the top nor a spherical end at the bottom. If that’s not good enough and you need to construct a model that provides a completely accurate representation, how can you do this? Read on.

Creating helical threads in BricsCAD and AutoCAD

I’m going to recreate the above screw as our example, but will make it dimensionally accurate. For simplicity, I’ll ignore the hex head and just do the shaft part. I’ll use BricsCAD to work through this, but it doesn’t matter. The steps are exactly the same in AutoCAD. There are a few things in BricsCAD’s 3D repertoire that might make things a little easier than in AutoCAD, but I won’t be using them here. I will be switching back and forth between visual styles in order to better show what’s going on with the geometry, so don’t expect consistency between the images.

First, construct a few basic parts from solid primitives. Here are the dimensions you’ll need for doing that:

From left to right, we have:

  1. DIA 20 x 40 cylinder that has been unioned with an DIA 20 sphere
  2. DIA 10 x 50 cylinder
  3. DIA 10 x 1.25 cylinder that has been unioned with a truncated cone DIA 10 to 7 x 3.75

The next step is to create the thread. There are two parts to this: the path and the profile. The path is easy: we just use the HELIX command. Specify the center of the middle cylinder as the base, a base and top radius of 5 (but specify the base radius using a known point such as a quadrant), a turn height of 1.5 (that’s the thread pitch) and a height of 50.

You might be tempted to make a simplified profile using an equilateral triangle with a side length of 1.5 (the pitch). Hot tip: don’t do this. Unfortunately, this will cause problems. Both AutoCAD (usually) and BricsCAD (sometimes) may refuse to create the thread because it thinks it self-intersects. You can use a simple triangle profile, but you’ll need to make it slightly smaller than the pitch: scaling by a factor of 0.95 should do.

Instead, let’s do it more accurately. The profile can be created as a polyline using conventional 2D techniques. Here are the profile dimensions for an M10 x 1.5 thread:

Note: to be completely accurate, the thread profile should also have a root radius. Feel free to add one if you like.

Either draw this profile in place using an appropriate UCS such that it is vertical up against the middle cylinder, or draw it in WCS and then move it into place using the ALIGN command. Although having the profile located in the right plane and location is theoretically not necessary, in practice it makes creating the thread much less fraught.

Here’s a tip that will save you a lot of trouble later: move the profile very slightly away from the center of the cylinder. A distance of, say, 0.01 will do. Here’s what it should look like if you zoom in far enough:

If you don’t do this, your CAD application will get into trouble later when you try to subtract the thread, because the outside of the thread and the cylinder will coincide, causing problems for the software. Having the outside of the thread just slightly beyond the edge of the cylinder will prevent this issue. Instead of kludging things by moving the profile slightly as described here, you could alternatively draw the profile such that it’s dimensionally accurate but with an outside edge slightly beyond the cylinder. Just make sure you don’t extend the profile so far that you run into the self-intersecting problem.

Next, use the SWEEP command, select the profile and the path. That should give you this:

Subtract the thread from the cylinder. Now move the cylinder/cone primitive into place on top of the shaft using CENter osnap and union the two solids, producing the elegant thread runout you see here:

Move the cylinder/sphere primitive into place on top of the shaft using CENter osnap:

Finally, intersect the two solids, producing this domed end to the threaded shaft:

Here’s the finished product in BricsCAD after I added a hex head to the top, unioned the solids together and added a brushed metal material.

Summary

The steps are the same in AutoCAD and BricsCAD:

  1. Create the primitive objects you’ll use later to define the threaded object
  2. Create a thread path using HELIX
  3. Create a thread profile polyline and move it into position
  4. Ensure the profile extends slightly beyond the edge of the shaft
  5. Use SWEEP to create the thread
  6. Subtract the thread from the shaft
  7. Move the cone/cylinder primitive into place and union the parts
  8. Move the sphere/cylinder primitive into place and intersect the parts

If you want to do this in a nut or hole, use the same principles. You just need to reverse the thread profile such that it’s pointing outwards into the hole before sweeping and subtracting.

Draping images over surfaces in Civil 3D

Having recently overcome various difficulties to successfully drape an image over a surface in Civil 3D, it may be useful to pass on a few points I have learned. There are various posts and videos out there that helpfully go through this process, but some of them (including Autodesk sources) contain information that is irrelevant or just plain wrong, and none of them contained all  of the information I needed to complete the task.

I used Civil 3D 2015 for this, but the principles apply to all recent releases. Here is the basic sequence required:

  1. In the drawing containing the surface, attach the image to your drawing using your preferred method (ImageAttach, Xref, ClassicImage). I’ll assume you’re familiar with what you need to do to get the image correctly scaled and aligned with the surface.
  2. Invoke the DrapeImage command, which will show you this dialog:DrapeImage01
    Make sure this is set for the image you want to drape and the surface you want it draped over. You can change the Render Material Name to whatever you like, or leave it as the default. Pick OK.
  3. You no longer need the image attached to the drawing and it will probably only confuse matters, so you can use use the Xref or ClassicImage command to detach it.

If you’re really lucky, that’s it. You will have a lovely-looking surface with a draped image over it. However, at this stage that’s pretty unlikely. Don’t panic! You also need to ensure the following conditions are in place:

  1. The surface will need to use a surface style that includes triangulated surfaces so the image has something to drape over. In the Toolspace, under Surfaces, right-click on the surface and pick Surface Properties…, then change Surface Style to anything with triangles, triangulation or TIN in the name (this varies depending on the template used). If you don’t have such a style available, you’ll need to make your own or edit an existing one using the button with a pencil in it.DrapeImage02
  2. While you’re in the Surface Properties dialog, have a look at Render Material. That should be showing the Render Material Name you specified in step 2 above. If it isn’t, make sure it is. Pick OK.
    Bonus tip: if you later need to remove the draped image from the surface, you can do so by changing the Render Material to something else (e.g. ByLayer).
  3. Still seeing nothing useful? Make sure you are using the Realistic visual style. You can get at the Visual Styles Manager using the VisualStyles command, but in recent releases it has been made easier to switch visual styles using the in-canvas control:DrapeImage03
  4. Still nothing? Try turning off Hardware Acceleration. Right-click on that glowing blue blob thing in the lower right corner and pick Graphics Performance…DrapeImage04That will give you a dialog with a Hardware Acceleration switch. Turn it off, pick OK and (hopefully) voila!

Note that the above conditions need to be in place when plotting, too. You might not expect hardware acceleration to make a difference to plotting, but in this case, it does.