Converting a perspective view to a flat drawing?
I have a fairly long assembly, that ideally would be shown in perspective. This would permit me to both show the closer up objects in detail, while also giving a sense of the entire assembly. I have looked at generated view, FlatShot, and SolProf. None of them are happy with perspective turned on.
Many years ago, in AutoCAD v10, I recall printing to a HPGL file, and then using the HPGL import feature. This gave us a lower resolution, but acceptable 2D vector drawing. I can perhaps print to a PDF, and then convert that PDF to a DWG. But, hidden line views generate bit-mapped images, not vector. I know there is legacy hidden as a plot output option that creates vectors. But, my objects have round tubing included, and the legacy hidden method draws a zillion tessellation lines, so that anything curved is just a solid black. Actually, I do recall manually erasing tesellation lines from the HPGL in/out process. So perhaps I can just do that with the PDF out/in.
I should also note that I am on v14, but would be interested to hear if later versions have a solution.
Is there any way to create a 2D vector drawing with perspective using BricsCAD commands directly?
-Joe
Comments
-
I just failed with Paperless Printer, and used its SVG output, which is vector format. But, the results are a gigantic file that just shows a large gray square.
0 -
I had forgotten that BricsCAD has separate Save-As and Export commands, with some overlap in terms of file types. I had to use Inkscape as an inermediary. First export a WMF, and then open in Inkscape and save as an EMF.
Note that while there were other formats that seemed to open fine in Inkscape, some didn't have the hidden lines removed. And once I got them in to inkscape, they didn't necessarily save as a successful DXF. But, Inkscape has known issues with saving DXFs. Actually, there seemed to be a number of possible ways to fail. Inkscape will open a SVG, saved by BricsCAD. But, my version of Bricscad will not open a SVG. In the past there were some more options. But, with v14, some import/export features were moved to the separate Communicator program.
I still would prefer a more direct approach that didn't require a 3rd party program.
-Joe Dunfee
0 -
Oops, I spoke too soon. The above approach generates thousands of tessellations lines. And even a simple cube, viewed in perspective generates 3 lines per side. I can understand 2 lines, where two faces touch on the corners. But, why three?
I know there are utilities out there, that will search for and erase redundant lines. So, that may be the next step in the process.
-Joe
0 -
Hi Joe,
in BricsCAD V16 Flatshot was enhanced to support perspective views.0 -
Does it support color of the objects? Actually, the approach I came up with didn't.
-Joe
0 -
I did just now experiment with using the Export feature of v14 to save a PDF. Then, I used one of the online services to convert it back to a DWG. I was able to preserve the colors. Though, for some reason the layers were not preserved, even though I have the Export to PDF options set to do so. It too, results in an extreme number of objects. The edge of a plate, that has only one visible edge, will have 4 lines to represent it. Any dashed lines, have separate lines for each dash, etc. But, the extreme swelling of the file size is what really kills this possibility.
Even the title block was totally messed up in the conversion. The SVG export suffered similar problems, though it did include some portions of the drawing that the PDF converted back to DWG did not. Of course, BricsCAD can't be held responsible for a bad conversion back to DWG, since that is not a feature of v14. However, the extremely large files sizes of the PDF exported from BricsCAD.is one of the problems.
How does the current version of BricsCAD handle this conversion? Are colors, and/or layers preserved?
Perhaps someone with a more current version can post a DWG showing a perspective view of a model, that has different layers, colors, and line types, to see what results?
-Joe
0 -
If you could attach a dwg set up with a view that you are trying to achieve, I would be more than happy to run the flatshot command on it for you to see the results, I have tried the command and it just seems to produce a monotone outline so I'm not sure if there are settings involved to get color, I'm fairly new to Bricscad and a long-term Autocad LT user which doesn't have flatshot.
0 -
It would not really help for me to go through the process. I have investigated this in the past, and for some reason generated views can only be b/w, so I would expect a perspective generated view to suffer the same limitations. And while they have added the ability to transfer the generated view to model space as objects, I am puzzled why they don't simply put them in paper space. And why strip the color or layer information?
I guess they think (and perhaps rightly) that only B/W lines are used by people. There are plenty of drawings I get from customers that was obviously drawn with a black background, as evidence by the yellow color being used for things that should stand out. So, they obviously don't print in color, like I always do.
-Joe
0 -
Hi Joe
I am having the same problem..
I think the export layout command should work but it isn't generating the screen viewport display so I have referred it back to Briccs cad and they are having a look into it for me so will report back on here with any findings.
Cheers from Budapest
Richard
0 -
Flatshot creates an outline drawing of all the elements on screen (hidden lines can be produced), and places them as a block onto the current layer, so it doesn't take into account the layers or colors of those original objects, but it does use the current layer settings or a picked color for the new blocks. So by turning layers off and using the objects layer as current I managed to produce this. Is it this type of thing you are trying to create. There is also an option to send the output to a new drawing.
0 -
So, perhaps it would be possible to write a routine that would do this for each layer for all the objects in the viewport, so that each layer can have the objects moved to their original layer after the flatshot creates them. Of course, the obscured lines wold have to be handled different, or entirely omitted by that process. Even for non-perspective views, this would be the only way to generate good line art, and maintain layers.
Do you know how Flatshot handles curves? Currently, the PDF approach produces such large files because any circle in the view gets converted to perhaps 40 or 50 segments. And as I mentioned before, the edge of a cube may generate 3 or 4 lines that are coincident.
I am evaluating if it is time to upgrade or not. But, my version is so old, it may be close to the price of a new seat, if not exactly.
-Joe
0 -
The image I attached was just a series of extracted circles, but the quality of the circles looks pretty good, if you explode the block the circles are actual circles so there is no segmenting. I thought of a script routine, unfortunately, the flatshot command is dialogue only, but I would have thought that a LISP/VBA routine would be a great way to do it, (it's just beyond my expertise at the moment) but it only needs layers turning on/off and run the flatshot command so in theory at least, something very simple.
0 -
I may be missing something, but combining multiple flatshots is problematic if the solids in one flatshot overlap those in another. I don't see a 'very simple' way to handle this.
0 -
Steven_G, in the case of a perspective view, a circle would not project as a circle. It would not even be an ellipse, just sort of a very round egg shape. In my PDF, each hole in a plate is perhaps close to 200 objects, including triangles that span between the top surface and the bottom of the hole. This is for a hole that would show up as less than 1/32" diameter in paper space. I did use Overkill, to cut out thousands of duplicate, overlapping lines. I just wish there were some way to reduce the tessellation of the holes and round pipes.
Roy, I realize that multiple Flatshots would overlap. So, after creating a view, that view has to be moved to a new spot.
-Joe
0 -
Good point Roy I didn't use anything overlapping, but turning layers off would create new outlines. Joe can you post a simple example where all these extra lines are showing up, just to see what the newer version of bricks cad makes of it. Or just download the demo version and see for yourself.
0 -
So if you would like to generate a 2d section or plan as a dwg generate the section using the section command click the section mark and enter the section’s file name in the property box then hold the cursor over the section arrow, click the command which appears on on the pull out bar click generate section and it produces a file.
0 -
Attached is a drawing I created just to illustrate the issues. The files include the original DWG (A), which has the 3D objects. Then I printed to a PDF(B), which I converted to a DWG(C) using an online converter.
Finally, I copied the objects that went the round trip into my original drawing(A) and added notes. The respective files are all prefixed with the letter in parenthesis.
Thank you all for any advice.
-joe0 -
Your drawing is already a flat drawing, so it's difficult to do the comparison, but attached is how it turns out in Bricscad 2018 using a similar example and an exaggerated field of view to show up the perspective effect giving an elliptical effect to the circles. No extra lines were created or removed this is how it is produced, all I did was explode the resulting block to expose the geometry.
0 -
Actually, my first (A) drawing has a 3D model in model space. The 1st layout tab has what I used to save as a PDF. Then the 2nd tab has the results. I put both the viewport that looks at the 3D model, and on the right side is the 2D version from the converted PDF.
Looking at your own version, I am impressed with the 2d line work. The only limitation is the lack of color or layers.
The older versions of AutoCAD, when I used it extensively, I know that freezing a layer would prevent 3D objects from that layer from obscuring things. But, if you turned that layer off, instead of freezing, then the 3D objects would not be visible, but they would still obscure the objects they were in front of when you used the native hide command.
But, the above behavior was before the day of video card rendering. Now it seems that CAD programs are entirely dependent upon the video card, and seem to only be able to extract a raster image. Turning off a layer does not have objects on that layer still playing a role in obscuring things. I don't know the current situation of that with AutoCAD. Legacy rendering still behaves like the older versions of AutoCAD.
In regards to my idea of writing a program that can do a multi-layer Flatshot, and preserve the layering; Can you tell me how the current Flatshot behaves in regards to off and frozen objects. I am guessing that both off and frozen behave the exact same way. If so, then there is no way to get a Flatshot of the background objects, so that portions that are hidden by an off layer are properly hidden, and my idea is not going to work.
Pehraps BricsCAD will enhance the Flatshot function in the future. Here is what I would like to see.
- Both the Flatshot and Generated View have the ability to preserve the layering, and the color of the original object.
- The use of new layers to show the profile and hidden lines should not be necessary. (though keeping it an option may help compatibility)
- If the user does not want obscured lines shown, then there is no issue. But, if they want the hidden lines, then perhaps they are offered the choice of keeping those lines on the same layer as the original object, but renaming the line type for that segment of line, to hidden. An alternative may be to permit them to put the hidden lines on a newly created layer with "-hidden" appended
- I would love to see an option to create a profile of each object, that has its own properties.
- In the settings, choices for line types and line weight for Profiles, Interior LInes, Tangency lines, and obscured lines.
I will send the above to their support site, as an enhancement request.
Thank you for your effort to help me.
-joe0 -
Ok a couple of different flatshots. Some made by layer from the same view. Also hatched solid with color255 (paper).
A bit tedious if its a large drawing but for small objekts you can also move them around .0 -
Still not clear what exactly you want to achieve.
In the drawing attached here I modified the 'hidden' visual style to display hidden ( = occluded ) edges using a dashed linetype and applied it to the paperspace viewport in layout1. A viewport layer override makes the red solid display as blue in the viewport.
I added screenshots to show how this looks in V18 ( V14 didn't display this correctly).
Are there any other overrides you need?0 -
@Hans De Backer:
AFAIK Joe wants vector-based DWG/PDF output with colored lines (3D objects are color-coded).0 -
Attached is an image of an actual drawing I created using my export to PDF technique. I had to manually color the various elements. I also did a fair amount of work to reduce the total number of objects, since there was a great deal that was overlapping, and dense tessellation lines on round pipe. I also re-modeled the entire assembly, because all the steel structural items had rounded corners. Those round corners would perhaps have doubled the number of lines, because each curve had tessellation lines.
The existing Flatshot in the current version really does a very nice job on the perspective view..., even on the holes. I was not expecting that. There were not overlapping lines, and the total entity count was quite reasonable. The only limitation was in regards to how to show various parts of an assembly in different colors and/or line types.
-Joe
0 -
Patric, I see now how you accomplished your own version. But, I don't think that process can be automated to work automatically. The hatching of the closer objects would be a challenge to automate. Though, perhaps a program could be made to at least create blocks of the flatshots of the various layers. Then, the user can edit each block to add the appropriate hatch solid white color.
-Joe
0 -
Indeed hidden or frozen results in the objects having no effect on other geometry. I don't know what your programming skills are like, but maybe a combination of turning layers off to get the color details for each object, and then an include all (with dashed hidden line) and you can use the hidden lines to delete unwanted areas of the drawing, so all that would be left are the visible lines in the appropriate color, but I honestly have no idea if that is achievable.
0 -
Visually it works just fine using the background color and continuous lines for hidden lines, and making the last flatshot the one that has all layers on, if you use a different layer and color for the visible lines in this last flatshot they are easy to select and delete. However I would have hoped that overkill would delete the segments of lines behind the "hidden line" segments and these could then be deleted leaving just the drawing as you need it, unfortunately overkill doesn't seem to work that way and just ignores the overlapping objects.
0 -
@Hans De Backer my guess is that getting a flatshoot with lines in original layers would not be a huge amount of work and I can see that it would be nice. It has my vote to.
0