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.

Can dotted lines starting with a gap?

Started by samdavo, November 12, 2013, 01:25:04 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

samdavo

Four questions
1. Is Dashed Line simply Hidden at half/twice scale?, eg if you look at the first jpeg, I see no difference between Dashed at Scale 3, and Hidden at Scale 6.  I will call them both "dotted' for this exercise.

2. Is it possible to start either type of dotted line with a gap?   This would apply to both Dashed or Hidden.    The central horizontal line in the first jpeg , "Start-with-gap Option",  is three lines (coaxially aligned), but not with common endpoints (because that would mean the line did NOT start with a gap).  And AFAIK that is the only way to achieve a gap to stop the first exterior solid line appearing to continue past its "legitimate" endpoint.  I mean, if a line is meant to be hidden, then IMO it should not look like an extension of a solid line, even if only in part. 

By way of example, If you look at the rectangle in the second jpeg ABoCDEF, you will note that there is a gap between B and O.   There is no such gap when the dotted line EF meets the solid line FA.   But this has been "manufactured" by deleting dotted line BC, and replacing it with line OC.

I would maintain that dotted lines in these situations are clearer if there is a dash to start with.

3. Finally, is it possible to ALSO finish a dotted line with a gap?  (although you can get a gap by complete luck I notice, based on the scale of the dashed/hidden line versus the length of the line).

4. Final question.   How about making a difference between Dashed and Hidden, whereby
a. one starts without a gap, and
b. the other starts and ends with a gap?

PS That drawing is 2D by the way (ignore the fact it might look like 3D),  and those hidden lines have been amended manually - not very efficient - but it permits me to illustrate the points above (2 cents).

PS This option of starting with a gap would only apply to BC  and FE.   The other dotted lines CH, DJ etc probably / arguably look better if they start and end with a dash rather than a gap. 

minstrel

#1
I'd be interested to see if there were any 'internal' settings to make these sorts of adjustments as well, but they may be non-existent.

Only way I see, which I think you make mention of, is the adjustment of the 'line' length [either way] to cosmetically change its appearance.  Works for x, y and diagonals...and is far from ideal.  If the line is dimensioned, well that would require setting point marks of the original first [for the dimensions], then the length adjustments for appearances.

edit #1 - hold on there, Jessy!  Just pulled out an old v18 printed manual and Appendix A deals with 'custom line styles and hatch patterns' ... maybe something can actually be done.  It does refer to the 'Dash offset' as the space after the dash [ not before it ].   
Even the 'Multi line' style has potential...you can overlay 2 lines with different scales/ colors [one set to bg color] but the space in front/end still seem to be a problem. 

Ed #2 - ok, here's the best attempt for the moment...see 2nd attachment.  Sam, you will, once again, need to revisit your notes on printed vrs bg colors to work the best settings...but, multiline seems to be the best solution thus far. Note - we are in 2D mode here, obviously.

And please be sure to attach 'screenshots' of the 'Multiline style' settings when you stumble onto the good ones...this way we can all try them. 

samdavo

#2
Quote from: minstrel on November 12, 2013, 03:34:47 AM
...see 2nd attachment.  Sam, you will, once again, need to revisit your notes on printed vrs bg colors to work the best settings...but, multiline seems to be the best solution thus far. Note - we are in 2D mode here, obviously.

And please be sure to attach 'screenshots' of the 'Multiline style' settings when you stumble onto the good ones...this way we can all try them. 
Lateral thinking there Minstrel :)  - actually I'm not quite keeping up with you.  You have two lines in the multi-line there,  yet I only see one red dashed line (?)  One set to background?  More thought required on my part.   (edit I tried setting Multi-line style "exactly" as you have it, ( as I thought), but the red line draws as solid instead of hidden?)

To be honest I probably assumed someone had already sorted it, or "found a workaround".  Speaking of which, I should add that I have a compatriot at work who has a neat cheat on this one, and literally does dotted lines.    Which is another way.  (Refer jpegs - I have chosen scale 2).  It is quick and easy at least,  and both ends of the line are "correct" irrespective of length and scale of line  - and whether these are common multiples of the number you first thought of etc (2 cents).
Cheers sam

PS You're right, Linestyle editor (under Options) doesn't seem to give option of an offset at the start.     And I have a minor aversion to Multiline ( having checked it out a bit) in that it's colours/colors are defined outside my normal philosophy.  i.e. the red dotted line can be on my layer 4 - yet that is reserved for green , etc.   I can guessing it would lead to confusion - for me anyway.

I suppose there is the option of importing a symbol, whereby you click each end of the line and it imports a dashed line that stops short of each end.

Or for that matter you could draw the line as hidden and zoom it down by 1% or 3% or whatever about its centre/center  (2 cents) - maybe with a macro (?)

Heath and Robinson would have loved this forum, lol.

samdavo

#3
PS Getting back to two pet gripes of mine -

1. the fact that Paperspace can't do HLD (Hidden Lines Dashed) - I wonder if it could be easily programmed to do HLLD Hidden Lines Literally Dotted ?

2. And the same goes for converting a 3D drawing to 2D  (via Save As) -  you only get the option of HLR (removed altogether).  Cheers.

I suspect that Scale is not as important for HLLD as it is for "Dashed" and "Hidden".  And let's face it,  for case 2 at least, if the DCAD program could just do the hard yards of changing hidden lines to some line type such as Dotted,  then you could select every such line by using the Selection Filter, and change it's scale (and even its type) -  if you felt so inclined and had the time.

(approx what Big Ben said to the Leaning Tower of Pisa) :)   

Dr PR

Beginning and end of a line are relative to which point is set first.

It looks like the end where the first point was set will always start with a dash.

You can set the first point on the right and the second on the left, and adjust the line scale to make the left end appear to "start" with a blank space.

Not perfect, but it is an occasionally useful trick.

Phil
DesignCAD user since 1987

Lar

Quote from: samdavo on November 12, 2013, 08:49:17 AM
...  then you could select every such line by using the Selection Filter, and change it's scale (and even its type) -  if you felt so inclined and had the time.
The creators of dcad were not smart enough to write commands for every possible need a user may have but they were smart enough to recognize their own shortcoming so they came up with BasicCAD.

A macro could be written to check every line in the drawing and check their properties. If certain properties match your requirements those line can then be selected for you to manipulate as required.

Lar
ps: I know, I know... BasicCAD can't cover every possible need either... but I say that it can, it may just require more effort or imagination to accomplish.

samdavo

#6
Quote from: Lar on November 12, 2013, 04:43:16 PM
A macro could be written to check every line in the drawing and check their properties. If certain properties match your requirements those line can then be selected for you to manipulate as required.
Lar
Lar - Limiting the conversation to "finding and presenting hidden lines/planes", DCad is brilliant. i.e. In 3D modelspace mode,  it can present either
1. HLR (Hidden Line Removed) or
2. HLD (Hidden Line Dashed).

To do that
a) it checks every line,
b) indeed every part of every line
c) and other entities, including differentiating between 2D and 3D text
d) to see what is visible and what is not.   
e) It presents those that are visible and hides or dashes those that are not
f) and it does that for each of the open views, whether 3 or 30.
g) (and every part of every plane - but ignore shading because we are talking types of wireframe here).

My point is that, when you go to Paperspace, it can still achieve a) to f),  but only with HLR.   Why not HLD?

Likewise when a 3D drwg is exported to 2D - you can have HLR, but not HLD (?)

That's why I say they've done the hard yards ( a to f).   Why don't they take it to its logical conclusion?   

PS If you're suggesting it would be possible to write a macro that achieves a) to f), - apart from the fact that I couldn't do it in a month of Sundays  -  I would counter that I believe that should lie with the DCad programmers, because they do it already.   i.e. whether hidden lines are removed (HLR) or Dashed/Dotted (HLD) is surely just twigging the margins.     
cheers

samdavo

#7
Actually, given that dotted lines vary from view to view, and given that they can be added by DCAD in modelspace, 
...
then under those circumstances, I find it totally inefficient that anyone would have to add
a single dotted line manually  (assuming they have gone to the trouble of doing a 3D drawing).
Dotted Lines should be automatic! (surely)  - and that goes for Paperspace and 2D export, as well as 3D modelspace imo. 

Lar

#8
Concerning macros (and I'll include non-macro techniques, tricks and workarounds) what I'm saying is there are things I can do in dcad today that I could not do years ago, but using the same commands that were available those years ago. Eg, going back as far as 1994 I first tried to model a face and failed utterly (to my liking, if I was working on the Toy Story staff I would have been on target). Every 5 years or so I would re-attempt the face and never quite achieve the face I want but would learn something new. Finally, since about 2 years ago I was able to model a face very close to my liking, but what I learned over the years brought me full circle to using the exact same dcad features that I used back in 1994, except with a bit more of a departure from that box everyone is talking about now'a days (can't remember if that box was ever spoken of back in 1994). I'm saying anything is possible but we just limit ourselves to our own imaginary comfort zone.

Since I don't really require 'hidden line as dashed' I have never put much thought into it. If, however, I desperately needed it in paper space today (ie, I couldn't wait years for DT&Co to make it official) I would either...
a] use the built in 'HLD' in the HLR command, save a screen image and either insert the image into model space, which would allow you to display it in a view frame in paper space, or paste the image directly into paper space, without the need for a view frame;

or...

b] use Prl's trick of 'saving as 2d' twice, one as hidden line and one as wireframe. Then, convert all the wirefame lines to dashed, group them all and drop the group on top of the hidden line drawing. Where the lines of the two files coincide will appear as solid lines. Otherwise, the remainder of the wirefame group will show as dashed lines (you can extend Prl's technique to combining dashed vectors with a shaded bitmap to get 'shaded image with hidden line as dashed);

<<since a can only be achieved with the 'current view' option, Prl's technique would be better for sharp prints>>

or...

c] in my case, export the file to cinema4d, save a hidden line as dash image there and insert it into dcad for display into p-space (a hidden line as dashed animation can also be created). I think sketchup can do the image also.

In terms of writing macros, a and b can be incorporated in a macro that can display the desired view, manipulate the layers and save the image to the desired filename (in case changes are made to the drawing, ie, the image will still show the pre-changes stuff. If the image is inserted into dcad as 'file reference' then you won't have to reinsert the image itself).

Of course these methods require a lot of work as compared to having the built in command, but they are all available today.

Lar
ps: my previous post about macros was in reference to selecting all lines of a certain linestyle and scale... the selection filter can fine all of the dsired linestyle, the macro can deselect those not of the desired scale and then change the selected to the desired scale.

samdavo

#9
Quote from: Lar on November 13, 2013, 06:26:22 AM
I would either...
a] use the built in 'HLD' in the HLR command, save a screen image and either insert the image into model space, which would allow you to display it in a view frame in paper space, or paste the image directly into paper space, without the need for a view frame;

or...

b] use Prl's trick of 'saving as 2d' twice, one as hidden line and one as wireframe. Then, convert all the wirefame lines to dashed, group them all and drop the group on top of the hidden line drawing. Where the lines of the two files coincide will appear as solid lines. Otherwise, the remainder of the wirefame group will show as dashed lines (you can extend Prl's technique to combining dashed vectors with a shaded bitmap to get 'shaded image with hidden line as dashed);

...
Lar
ps: my previous post about macros was in reference to selecting all lines of a certain linestyle and scale... the selection filter can fine all of the dsired linestyle, the macro can deselect those not of the desired scale and then change the selected to the desired scale.
Lar
a) I was aware of this one and have posted something similar (posted again). The dashed lines are pretty anemic with this method for some reason. 
b) but thanks for explaining this b) option.  (the penny drops) :)  And that is a pretty neat workaround - I imagine I will use that (as far as it goes - Paperspace would be better).

As for your final comment,  yep that's exactly what I was proposing (when I mentioned selection filter), but unless DCAD puts those lines there as something (anything) , whether dotted, dashed or barbed wire fence, then I can't select it to change it.  I am guessing ( might be wrong) that I am making a reasonable request, but since no response, then maybe I should accept it is a lot a work for them too.  And DCAD is still the best value CAD package around.
 
Hey will the Heavens fall if I can't use HLD in Paperspace? No.
Just that I hate drawing dotted lines even in 2D. 

PS I enclose another way to get there - just set out the views in Modelspace neatly, and do a screen snap of that.

Also you can use sections to get a similar result - well quarter the way there for some drawings.

Also (as I say) a previous post with "paperspace plus jpeg of dotted lines" (2 cents).   And as you say, I wouldn't get a job with Toy Story, but getting there.

The final jpeg is a paperspace screen with a giant jpeg screensnap of modelspace in the middle :)

PS thanks for the discussion.

PPS Just to put a degree of difficulty on working out whether a line should be visible or hidden.   Imagine a house with a stack of LOOONG Venetian blinds - and with 3 flagpoles out the front.   The line of each side of each flagpole interrups several horizontal line, which then become  7 short lines, 3 of which ( behind the flagpoles) are hidden.  sheesh. 

And that's without even considering shading - or shadows, or lighting, or ... 

It's amazing this CAD stuff, when you think about it , yes?  fantastic really. 

Lar

Quote from: samdavo on November 13, 2013, 12:27:20 PM
..., but unless DCAD puts those lines there as something (anything) , whether dotted, dashed or barbed wire fence, then I can't select it to change it.
Are you saying that the selection filter does not allow you to select by line style. If that's what you're saying then check out the 'line syle' tab, about exactly center amongst the tabs of the selection filter. There you will find a listing of every line style in the drawing. Double click a style (or a few) in the left half and it appears in the right half, allowing you to only be able to select entities of that line style.

Now, if you want to select only a particular line scale of the selected line styles then you could do this with a macro that checks out the properties of the selected entities and deselects those entities whose line scale does not match your criteria. In fact, a macro can be written to select the needed line style and line scale without the use of the selection filter.

Lar

samdavo

#11
Lar
Here's a cactus plant in a fenced-in area.  (compare flagpoles in front of venetians as I said above).
The lines of the planks behind the plant are straight (and are nailed onto corner posts). 
Assume each of those solids are exploded and vc'ed.
Each line (one single entity each) becomes a number of elemental parts,  up to say 9 in this case (varies with each view) - some of which are visible some are not. 
How are you going to write a macro that checks the properties of the single entity as to visible/not visible?

As for Selection Filter - yes exactly, I agree with all you say.  That's why I suggested using it.   But what are you going to select, if the two options are HLR (where the "lines of interest" are missing) and full wireframe (where they are the same as all other lines)?   There is nothing to permit you to select the lines to be dashed (unless as you say, you have both of those superimposed - as Phil suggested). 

But I doubt that there is any way to detect what is hidden by searching entity properties.   Or more correctly, I am not aware of it.   It would have to   
a) split each line into parts visible and otherwise, number of elements per line and length of each  (for the top line there are "about" 9 elements x 9 short lengths, including the effect of the corner posts as well as the cactus branches ); 
b) for each view  (say 4 off) - assuming Paperspace (although for 2D export, you can only export one view at a time I believe)
c) and recorded this as maybe 9x9x4 = 320 Sys functions for that line ...

But having said that, DCAD obviously calculates exactly that (or something with the same result) when it does this in Modelspace  (see third jpeg).  AND it exports this property to 2D when you select HLR.   

And btw, even if there were entities to tell you which elements of a given line were visible and which were not,  then I can't see how that would help in Paperspace  ...

Although I concede it might help in 2D export. 

samdavo

#12
By the way, here's Phil's solution ( although I didn't show the cactus as being dashed because cylinders are pretty messy - even messier than the third jpeg above, which is HLD drawn in modelspace).

i.e starting with one of the views in the dcd file above,
1. "Save a copy" as 2D with HLR
2. "Save a copy" as 2D with full wireframe
3. VC and edit\breaklines, then select all
4. Convert all lines to dashed lines
5. Get rid of about half the lines because - IN SOME CASES - they insist on staying solid when there is a second line under them which is dashed (?) - there are a few errors as a result of my not removing these excess lines thoroughly
6. Copy this with a handle and
7. Open the HLR 2D drawing
8. Paste onto the same image in this drawing.

PS When you "Save a copy as 2D", there is a box there called "enable hidden line cleanup".   What does that mean?  and/or what does it do?

Incidentally, I show the breakup of one line into visible and invisible "elemental lengths"  (and there are 9 of them for that particular line) 2 cents.   

PS This method works ok I guess, but you have to go through those steps with each view, hence 4 views takes a while.  And if you change one thing, you have to do it all again from scratch to amend your "4 views in 2D".  i.e. It's not an instantaneous update in all views as it is with Modelspace in 3D.   (or as it would be IF Paperspace had HLD).

Lar

***This is in response to Sam's previous post***
Sam,

1]The selection filter searches for existing properties, not visibility, so it won't help in your current example.

2] A macro can be written to generate hidden line removal and hidden line as dash. I actually started writing a shading macro many years ago, since dcad's shading was always so weak (and still is) but then I discovered cinema 4d so I abandoned that macro. Before I even started using dcad 3d I wrote BASIC programs that generated simple color animated 3d scenes (I wasn't even aware of the "a plane must have 3 points" rule back then).

3] While you're waiting years for HLDIPS ("hidden line as dashed in paper space") to be implemented use PHLDT ("Prl's hidden line as dash technique", see "b]" in my 2nd post before this one, use 'hidden line cleanup' to reduce the overlaps in the dashed file), put the compiled 'save as 2d' on a dedicated layer (ie, a layer that nothing else is on) and in paper space create a view frame displaying that layer only and you're done.

Lar

Dr PR

#14
Here is another trick you can use to create unusual and complex lines, such as roads (parallel lines that "Y" and "+" correctly at intersections) or railroad tracks.

1. Draw simple lines (V), curves (C), arcs or whatever to create the path that you want to work with. It is best to work on a new or previously empty layer.

2. Select all and copy to another layer, being sure you place the copy exactly over the original.

3. Give one of these sets of lines a relatively wide line width and select a color. Then use "Edit/Selection Edit/Display Order/Move to Back" to put it in the background.

4. Select the other set of lines (on the other layer) and give them a narrower line with and a contrasting color (from the background lines). Then use "Edit/Selection Edit/Display Order/Move to Top" to put it in the foreground.

5. Move both line sets to the same layer and group them. Now you have a new compley line pattern.

For example, if the wide background lines are black and the foreground narrower lines are white, you will have nice parallel lines with neat intersections just right for creating roads on a map.

If the upper narrow lines are light yellow and dashed, and the wider background lines are solid dark green, you will get narrow yellow dashes over a solid green line. Give both lines the same width and you get alternating yellow and green dashes.

You can build up multiple lines like this to create railroad tracks, power lines and other complex line patterns.

Note: You must select a background color that contrasts with both line colors. For example, if you put a white line over a black line, and you have a white (or black) background, both lines will display black on the white background (or white on a black background).

If the line color is very close to the background color, where it is nearly invisible, DesignCAD automatically reverses the displayed color of the line so you can see it. The line still retains it's assigned color, but it is not displayed. DesignCAD always does this and there is no way to defeat it.

Note: If you use parallel lines for things like the railroad tracks shown below, they must be straight lines. If you use curves the dashes will not align properly throughout the entire length. For curved tracks you need to create a new custom line style.

Phil


DesignCAD user since 1987