October 2010


So, I was reading The Swamp and came across a post about getting an alignment station/offset label to draw a line over to the alignment. There were a few options  but I came up with my own solution and I would like to share it here with all of you.

So, This is what the user wants the labels to look like (I drew this up myself so if you think it looks sloppy, the blame lies solely on me):

You can do this with a station label and just have it add the line and then the text but, what if you need to adjust the labels so they are farther from the alignment? Or on the other side? Well, this is what you get:

(select the image to see the animation)

So, what did I do? To start off with, I used a station/offset label with a line component. In this post, I’m going to focus on the line itself and not necessarily the text. Create a new label style, delete everything (I like to start out fresh) and add in a line component. The line will attach middle center of the feature as there is nothing else to attach to at this point. The end of the line will be calculated so don’t specify an ending point.

Now, to control the length and the rotation of the line, we have to create a couple expressions. The length of the line is determined by the offset value of the label location but, the length of the line is also dependent on the drawing scale. If the scale changes, the length of the line changes. I’m going to use a technique I wrote about in an earlier blog post HERE to avoid the length of the line changing when the drawing scale changes. Basically, I’m going to take the offset value and divide it by the drawing scale factor:

We also need to create an expression for the rotation of the line. I used the Instantaneous Direction of the line. The problem with that is  if I just use that for the rotation, it rotates the line the wrong direction. To overcome this, simply multiple the direction by a negative 1. Also, the line is going the wrong direction so we need to add a rotation of 180 degrees to the line so add in pi to the direction (remember it’s in radians).

Now, use these two expressions in the label style for the length of the line and it’s rotation:

Add some text components, some more line components, and perhaps a reference text component and you are good to go! Hope this helps everyone!

Advertisements

Seems that things come in spurts. I talked with someone the other day that was about to give up on C3D because, “The only way pipes can connect to a structure is at the insertion point.” The last week or so, there have been two wishes submitted to the AUGI C3D wish list about this.

Well, I have some good news for you, pipes don’t HAVE to connect at the structure insertion point. Here’s an example: I have a storm sewer system that includes a curb inlet. This inlet is 15′ long and the discharge pipe comes out of the end of the box. 15.5′ away from the edge of the inlet s the 4′ diameter manhole it needs to connect to. The distance from center to center of the structure is 25′ but, there is only 15.5′ of actual pipe. According to Civil 3D, the length of the pipe is 25′ and that is the distance that is used for the slope calculations. You can display the edge to edge distance but, for slope calculations or quantity takeoff purposes, the pipe is still 25′ long. So, what do we do? Well, just move the pipe to whatever part of the structure you want!

(click on the image to see the animation)

The trick to get this to work correctly is the pipe must be connected to the structure first. Once it is connected, simply grab the grip and place it anywhere on the structure that you want. Just make sure you still see the glyph that indicates you are connecting to a structure. You have edited the pipe! It’s now as long as it really is. QTO will recognize the true length of the pipe and the slope calculations are done correctly.

There are some things to be cautious of however. If you move one of the structures, the pipes will jump back to the insertion point of the structure. Also, if you create an alignment from the network parts, it goes from start of pipe to start of pipe so you’ll probably end up editing the alignment after the fact but that’s extremely simple to do. Finally, you can snap to the structure but if you do that, it will change the invert elevations of the pipe so, you’ll need to come back and edit them after the fact if you use snaps (that’s why I just eye balled it in the image above).

Now go out there and get your pipes to work correctly!