Skip to content
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

Fix segmentation fault when running CLI #4702

Merged
merged 4 commits into from
Apr 7, 2024
Merged

Conversation

asokawotulo
Copy link
Contributor

@asokawotulo asokawotulo commented Mar 25, 2024

Fixes: #1194

Changes:

  • Replaced extruder_clearance_max_radius with extruder_clearance_radius to resolve the CLI error
  • Add if (m_plater) before accessing preset_bundle in generate_logo_polygon and before generate_plate_name_texture
  • Add thumbnails to export only if thumbnail callback is defined

@grepson
Copy link

grepson commented Apr 3, 2024

I'm not fluent in cpp, but having a working cli again is a huge thing for my project. Either if it's merged or not @asokawotulo thanks for making this PR!

src/libslic3r/GCode.cpp Outdated Show resolved Hide resolved
@asokawotulo
Copy link
Contributor Author

I'm not fluent in cpp, but having a working cli again is a huge thing for my project. Either if it's merged or not @asokawotulo thanks for making this PR!

Happy I could help @grepson! Out of curiosity, what's the project you're working on and how do you use the CLI?

@grepson
Copy link

grepson commented Apr 5, 2024

I'm not fluent in cpp, but having a working cli again is a huge thing for my project. Either if it's merged or not @asokawotulo thanks for making this PR!

Happy I could help @grepson! Out of curiosity, what's the project you're working on and how do you use the CLI?

@asokawotulo I'm using it to remotely slice prints into gcodes for different printers. I have already completed workflows for PrusaSlicer, SuperSlicer, Cura and thanks to this PR maybe I'll be able to add OrcaSlicer to that ❤️! I have an API written in Typescript that takes some body params and stl to slice, fires up docker container underneath and slices that file.

@asokawotulo
Copy link
Contributor Author

I'm not fluent in cpp, but having a working cli again is a huge thing for my project. Either if it's merged or not @asokawotulo thanks for making this PR!

Happy I could help @grepson! Out of curiosity, what's the project you're working on and how do you use the CLI?

@asokawotulo I'm using it to remotely slice prints into gcodes for different printers. I have already completed workflows for PrusaSlicer, SuperSlicer, Cura and thanks to this PR maybe I'll be able to add OrcaSlicer to that ❤️! I have an API written in Typescript that takes some body params and stl to slice, fires up docker container underneath and slices that file.

@grepson Ohh interesting I'm actually also working on a similar project to remotely slice files, but with just OrcaSlicer since I only have a Bambu printer

I probably could have used Bambu Studio's CLI since that was working when I tested it, but I preferred the idea of using OrcaSlicer. Plus refreshing my C++ skills was a nice bonus

Copy link
Owner

@SoftFever SoftFever left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.
Thank you

@SoftFever SoftFever merged commit fe914e8 into SoftFever:main Apr 7, 2024
powpingdone pushed a commit to powpingdone/OrcaSlicer that referenced this pull request Apr 10, 2024
* fix: replace extruder_clearance_max_radius with extruder_clearance_radius

* fix: add if m_plater before accessing preset_bundle

* fix: generate thumbnail only when callback is defined

* fix: change default gcode thumbnail format to png
powpingdone pushed a commit to powpingdone/OrcaSlicer that referenced this pull request Apr 11, 2024
* fix: replace extruder_clearance_max_radius with extruder_clearance_radius

* fix: add if m_plater before accessing preset_bundle

* fix: generate thumbnail only when callback is defined

* fix: change default gcode thumbnail format to png
SoftFever pushed a commit that referenced this pull request Apr 13, 2024
* fix: replace extruder_clearance_max_radius with extruder_clearance_radius

* fix: add if m_plater before accessing preset_bundle

* fix: generate thumbnail only when callback is defined

* fix: change default gcode thumbnail format to png
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Command line execution does not work
3 participants