Community
Civil 3D Forum
Welcome to Autodesk’s Civil 3D Forums. Share your knowledge, ask questions, and explore popular AutoCAD Civil 3D topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Feature Line color conditionally

9 REPLIES 9
SOLVED
Reply
Message 1 of 10
jroot
1517 Views, 9 Replies

Feature Line color conditionally

Maybe I'm dreaming too far out of the box on this one... I can see this moving to the Ideas forum.

What I would like is for the color of a Feature Line to change according to the slope between vertical PI's.  And not just one color for the whole line, I mean each "segment" would be a color based on slope.  Perhaps red for a segment 0-0.5%, then orange for 0.5-1.0% and so on.  I know you can label the slopes ( and I do that) and you can see the slope in Elevation Editor, and turn on Slopes for a Surface.  But I think the changing-color Feature Line would be handy in working up some rough designs, to be able to see flat/steep spots on the fly.

Is this possible?

9 REPLIES 9
Message 2 of 10
BlackBox_
in reply to: jroot


@jroot wrote:

Is this possible?


Yes, this is possible using a .NET Overrule, so certainly possible for dev team using ARX. 

 

Bad news, is that Overruling the objects is the easy part... Implementing a new mechanism/UI that allows user to define/edit slope ranges and be smart enough to preclude overlapping ranges, etc is the more difficult aspect to this, IMO.

 

As one who does a lot of site grading design, this is definitely something I'd be interested in using/developing for my own work. 

 

Cheers



"How we think determines what we do, and what we do determines what we get."

Message 3 of 10
MMcCall402
in reply to: jroot

You could simulate it by adding a series of line components that overlay the feature line to your label style in various colors representing slope ranges and control their visibility by a length value supplied by expressions that test the slope of the line and returns a value of the segment length or 0 if it falls within a specified slope range.

 

An expression like the one below test for greater than or equal to 0 but less than 1

 

IF(0<={General Segment Grade},IF({General Segment Grade}<0.01,{General Segment Length}/{Drawing Scale Conversion},0),0)

Mark Mccall 
CAD Mangler



Hammer Land Engineering


Linkedin

Message 4 of 10
jroot
in reply to: MMcCall402

This is brilliant. 

I finally got time to play with it and it's working.  I changed the 0<={General Segment Grade} to be:

-0.01<={General Segment Grade}

so that it looks at grades that are less than 1% in either direction.

The only downside I see so far without actually using it during design is that if all the segments are less than 1% the line will be visible and I can't grab the Feature Line without selection cycling because the line is on top.

Thanks Mark!

Message 5 of 10
Neilw_05
in reply to: jroot

Some years ago the question came up about color coding slope labels according to a range. The concept was to apply slope labels to a surface and they would be colored according to a slope range. It is not the same as coloring the featureline itself but it may be a suitable alternative. I believe Jeff Mishler developed a tool for this in his "Sincpac" tools. Terry Dotson may also have a tool for this in his DOTSOFT tools.

 

You can also search the forum for "color" + "slope labels" in the topic headings.

Neil Wilson (a.k.a. neilw)
AEC Collection/C3D 2024, LDT 2004, Power Civil v8i SS1
WIN 10 64 PRO

http://www.sec-landmgt.com
Message 6 of 10
Neilw_05
in reply to: Neilw_05

Dotsoft has a tool that appears to do color coded labels (see screen capture below).

 

Also I found an old post where Peter Funk had a label that changed color based on slope direction (plus or Minus). It may offer some ideas. https://forums.autodesk.com/t5/civil-3d-forum/custom-labels/m-p/1924960

 

I didn't find the topic I mentioned earlier. I am pretty sure Jeff Mishler was involved along with myself. This was maybe 7 years ago or more. The context was in regard to evaluating handicap routes for slope compliance.

Capture.JPG

Neil Wilson (a.k.a. neilw)
AEC Collection/C3D 2024, LDT 2004, Power Civil v8i SS1
WIN 10 64 PRO

http://www.sec-landmgt.com
Message 7 of 10
TerryDotson
in reply to: Neilw_05

Thanks for the mention.  BlackBox mentioned the solution (overrules) and affiliated slowdown (specification table).  We already have overrules for FeatureLines where we add transient geometry (example below).

capture.png

Everything shown in red is transient (doesn't actually exist in the drawing) including the point tics, station/elevation, general direction arrows, percent slope and distance labels.  They are not saved in the drawing and they don't plot.  The size can easily be controlled by the TEXTSIZE variable (followed by regen) or a single click of the command icon takes them away.

 

We already have color <> range grid control code we can implement, so we're really about an hour away from complete as long as generating 3dArcs isn't a problem (we could use short chords if necessary).

Message 8 of 10
BlackBox_
in reply to: TerryDotson

Thanks, @TerryDotson ; can't wait to see (and test?) what you come up with. :beer:

 

Hands down, Overrules are my favorite new [.NET API] chew toy! Haha

 

This started out as a curiosity, to see if I could more easily model residential lots (but useful for many other things too), as the Corridor alternative for lots is just terrible! Overrules allowed me to ensure each 'lot line' was an exact length with the lot drainage type's required slopes (rear to front, front to rear, mid-lot break), while allowing the 'front lot corner' (first PI) to be relative to the roadway's Corridor Surface (see Command Line & Elevation Editor):

 

Feature RulesFeature Rules



"How we think determines what we do, and what we do determines what we get."

Message 9 of 10
TerryDotson
in reply to: BlackBox_

Here is the revised options dialog using the color ranges mentioned by the OP.

capture.png

Existing users run the Check for Updates tool.

Message 10 of 10
jroot
in reply to: TerryDotson

I don't have DotSoft (sorry) but this is a good solution as well.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Rail Community


Autodesk Design & Make Report