-
-
Notifications
You must be signed in to change notification settings - Fork 114
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
[Bug] Export file in PCB Exposure GUI out of the window borders #836
Comments
This is your first time submitting an issue with UVtools 🥳Please review your issue and ensure that the submit template was followed, the information is complete, and not related to any other open issue. It will be reviewed shortly. Debugging is very important and make the program better. Thanks for contributing and making the software better! 🙌 |
I didn't understand this issue.
The UVtoolsCmd can run operations from CLI, check the |
Because you haven't open a file. Uvtools only works if you load your file in. |
I think the problem is the fact you don't understand the concept of UVtools... The reason why you need a prior file is because UVtools need to fetch all data, what is the printer, what is able to do (limitations), what pixel pitch it use (Resolution), what the sizes/dimensions, etc... Without any of that data is not possible for UVtools to do anything because it can't guess what is your printer or file format. Same apply to slicers, you can't slice a file without selecting a printer which contains all it data to be able to slice the STL to the printer. So you have a gerber and want UVtools to translate that "correctly" to your printer LCD/pixels, how do you expect that to happen if you don't supply the proper info for it able to do the conversion math (Millimeters to pixels) and build the file structure? That said you can't just open an random file or a PNG as you did in the screenshots you sent. You need to open a file that you previous sliced and print for the target printer you aiming for! This is not optional! Either use or duplicate an file you printed before, or just slice a new file for your printer and use it as a dummy file. You may see the load file an inconvenience, but think again, if you had to configure printers, formats, parameters and different profiles for each printer you had you will hate it even more. UVtools was made to modify and work under files, not create them from scratch, so it always source all the information from a sliced file that you already have. If you supply the wrong file it's normal that things wont work. |
The error tells about the problem. The SVGX format was made without including the resolution and display size, that information is critical for UVtools. Also SVGX use metric vectors instead of pixels/bitmaps, it's a unique format, this way UVtools have no way to adquire resolution nor trace a image from supplied vector. The only way is by having the missing information. To have such you need to use other slicer, configure a printer with same properties as yours, slice file, open in UVtools and convert to SVGX. To facilitate this you better use PrusaSlicer with my printer configurations, it will save the mess of dealing with parameters and when open on UVtools it will auto convert to SVGX and work under it --> Follow this guide: https://github.com/sn4k3/UVtools/wiki/Setup-PrusaSlicer Note: When UVtools converts to SVGX it will inject the Resolution and Display information on file and then it can always be open back on UVtools.
UVtools is not a slicer, it only reads output files from slicers, this program is a post-process program to work with MSLA/DLP files.
None of those are sliced files and UVtools don't do slicing on it own, so they are not supported as input.
It allow you to change file and image resolution, also display size. In a easy sample and also why it was created: You can use it if you have A and B printer (Using same file format), and you want to print A file on B printer but resolution mismatch and it don't allow to print. This tool allow change resolution to match printer B requirement, cropping or expanding image, however if pixel pitch of A is different from B you have to adjust Display too which will trigger a resize to translate to the correct pixel pitch and ensure correct model portions on B, still if the case this not recommended as resize can distorce model. BUT: If you want to adjust resolution and display size to create something from scratch/layer0, eg: calibration tools, PCB tool, lithophane tool, etc. Using the change resolution tool will never hurt, as long you input the correct information to match the output printer.
That is indeed strange, because menu should open to the right and not left. PS: Never use the demo file, its only there to explore the program if you don't have a file and to remember the user to open his file, but should never be used to real reasons. |
hey, that was not easy! but at least I can once again open gerbers ;-) thank you! |
The UI framework have some bugs and it's more reliable on Windows and macOS, if you wish to contribute for it you can post the issue under their repo: https://github.com/AvaloniaUI/Avalonia/issues you will need to provide much data as you can in order for them track the problem. Including the tricks you need to do for it to be visible.
To use PCB tool under CLI you need to export the configurations of the tool and use it as template. Then you need to modify file to select the gerbers, this can be done easy with a bash script where you can even drag and drop your gerber into it. Here a template: <?xml version="1.0" encoding="utf-8" standalone="no"?>
<OperationPCBExposure xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<LayerRangeSelection>None</LayerRangeSelection>
<LayerIndexStart>0</LayerIndexStart>
<LayerIndexEnd>971</LayerIndexEnd>
<ProfileIsDefault>false</ProfileIsDefault>
<Files>
<PCBExposureFile>
<FilePath>gerber_v4-F_Cu.gbr</FilePath>
<InvertPolarity>false</InvertPolarity>
<SizeScale>1</SizeScale>
</PCBExposureFile>
</Files>
<MergeFiles>false</MergeFiles>
<LayerHeight>0.1</LayerHeight>
<ExposureTime>10</ExposureTime>
<SizeMidpointRounding>AwayFromZero</SizeMidpointRounding>
<OffsetX>0</OffsetX>
<OffsetY>0</OffsetY>
<Mirror>false</Mirror>
<InvertColor>false</InvertColor>
<EnableAntiAliasing>false</EnableAntiAliasing>
</OperationPCBExposure> Save that as a With a simple regex replace you can replace the input file Still I think this is not worth, as you always should confirm the output, if you have to open the UVtools to confirm the result why not run the PCB tool from UI in first place? |
that seems exactly what I was looking for! thank you! |
@dc740 that bug is not related to UVtools but UI framework, It can't be solved on UVtools side. I suggest to open the issue on framework side as I already mention here ⬇️
thirstyone mention that it work fine under macOS, as so Windows. So its a linux problem on the framework. EDIT: I just noticed that the bug was introduced on latest avalonia version. If you use UVtools v4.2.0 it will show correctly (It uses older avalonia version) I will open the ticket with them. |
Thank you for the fast reply. For reference, it was introduced in Avalonia version 11.0.8 and worked fine in 11.0.7: I'm going to investigate how to revert in my local compiled binary and see if that fixes it, but it looks like it. |
You can downgrade Avalonia on your local build, OR downgrade UVtools version to 4.2.0 |
I can confirm that downgrading Avalonia to 11.0.7 works OK locally. Thanks! For anyone else looking to workaround it until the Avalonia bug gets fixed can change 11.0.9 to 11.0.7 references in these two files:
Then compile and the local build will work just fine. (by the way, thank you again!!! this tool is amazing) |
System
Printer and Slicer
Description of the bug
Using the recently installed UVtools in Linux Mint, I can't see export options in PCB Exposure - they are 'shown' to the left, outside the visible window.
How to reproduce
Feature request: a CLI one-liner to save gerber to stl (or, even more preferably, to svgx)
Files
No response
The text was updated successfully, but these errors were encountered: