-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The view angle for SVG export is not ideal #82
Comments
Looks like the line intensity is not changed to the new so perhaps not a good fix, worth a try |
also the x,y,z axis can be removed if this code is removed from the end if the exporters.py file
|
my_reactor.solid.rotate(startVector=(0,1,0), endVector=(0,0,1), angleDegrees=180) |
Perhaps something like this should be put into the Reactor.export_svg() method from cadquery import exporters
with open('rrr.svg', "w") as f:
exporters.exportShape(my_reactor.solid.rotate(startVector=(0,0,1), endVector=(0,1,0), angleDegrees=180), "SVG", f) |
Looks like some new SVG feature on CadQuery will allow all sorts of great SVG export options CadQuery/cadquery#596 |
There are some new features arriving in CQ 2.1 for this https://github.com/CadQuery/cadquery/pull/596/files
|
The viewing angle of the SVG export in CADquery has currently hard coded viewing angle which is not perfect for the Paramak as it is from above.
Here is the default view
If you open up the exporter.py file in you source code for your local install of CADquery mine is saved in '/home/jshim/anaconda3/lib/python3.7/site-packages/cadquery/occ_impl/exporters.py or sometimes in /home/jshim/cadquery/cadquery/occ_impl/exporters.py' then you can change the default hard coded angle
From this
DEFAULT_DIR = gp_Dir(-1.75, 1.1, 5)
To something like this
DEFAULT_DIR = gp_Dir(-2, 5, 1.1)
The result is an improved view angle for the SVG export :-)
This is a a temporary fix as CADQuery will probably support viewing angle as an argument in export_svg in the future and there is an open issue for this CadQuery/cadquery#246
The text was updated successfully, but these errors were encountered: