Move WIKI to new repo

This commit is contained in:
SoftFever
2025-11-24 23:50:54 +08:00
parent 4c1b6445d3
commit f0d79b99eb
321 changed files with 0 additions and 6479 deletions

View File

@@ -1,96 +0,0 @@
# Placeholders Variables
This section describes the general built-in placeholders variables available for use in G-code scripts and configurations.
- [Global Slicing State](#global-slicing-state)
- [Read Only](#read-only)
- [Read Write](#read-write)
- [Slicing State](#slicing-state)
- [Print Statistics](#print-statistics)
- [Objects Info](#objects-info)
- [Dimensions](#dimensions)
- [Temperatures](#temperatures)
- [Timestamps](#timestamps)
- [Presets](#presets)
## Global Slicing State
### Read Only
- **zhop**: Contains Z-hop present at the beginning of the custom G-code block.
### Read Write
- **e_position[]**: Current position of the extruder axis. Only used with absolute extruder addressing.
- **e_restart_extra[]**: Currently planned extra extruder priming after de-retraction.
- **e_retracted[]**: Retraction state at the beginning of the custom G-code block. If the custom G-code moves the extruder axis, it should write to this variable so OrcaSlicer knows where it travels from when it gets control back.
- **position[]**: Current position of the extruder axis. Only used with absolute extruder addressing.
## Slicing State
- **current_extruder**: Zero-based index of currently used extruder.
- **current_object_idx**: Zero-based index of currently printed object.
- **has_wipe_tower**: Whether or not wipe tower is being generated in the print.
- **initial_extruder**: Zero-based index of the first extruder used in the print. Same as initial_tool.
- **initial_tool**: Zero-based index of the first extruder used in the print. Same as initial_extruder.
- **is_extruder_used**: Vector of booleans stating whether a given extruder is used in the print.
- **has_single_extruder_multi_material_priming**: Whether or not single extruder multi-material priming is used in the print.
- **initial_no_support_extruder**: Zero-based index of the first extruder used for printing without support. Same as initial_no_support_tool.
- **in_head_wrap_detect_zone**: Indicates if the first layer overlaps with the head wrap zone.
## Print Statistics
- **extruded_volume**: Total filament volume extruded per extruder during the entire print.
- **extruded_volume_total**: Total volume of filament used during the entire print.
- **extruded_weight**: Total filament weight extruded per extruder during the entire print.
- **extruded_weight_total**: Total weight of filament used during the entire print.
- **total_print_time**: Total time taken for the print.
- **total_layer_count**: Total number of layers in the print.
## Objects Info
- **num_objects**: Total number of objects in the print.
- **num_instances**: Total number of object instances in the print, summed over all objects.
- **scale[]**: Contains a string with the information about what scaling was applied to the individual objects. Indexing of the objects is zero-based (first object has index 0).
- **input_filename_base**: Source filename of the first object, without extension.
- **input_filename**: Full input filename of the first object.
- **plate_name**: Name of the plate sliced.
## Dimensions
- **first_layer_print_convex_hull**: Vector of points of the first layer convex hull. Each element has the following format: '[x, y]' (x and y are floating-point numbers in mm).
- **first_layer_print_min**: Bottom-left corner of first layer bounding box.
- **first_layer_print_max**: Top-right corner of first layer bounding box.
- **first_layer_print_size**: Size of the first layer bounding box.
- **print_bed_min**: Bottom-left corner of print bed bounding box.
- **print_bed_max**: Top-right corner of print bed bounding box.
- **print_bed_size**: Size of the print bed bounding box.
- **first_layer_center_no_wipe_tower**: First layer center without wipe tower.
- **first_layer_height**: Height of the first layer.
## Temperatures
- **bed_temperature**: Vector of bed temperatures for each extruder/filament.
- **bed_temperature_initial_layer**: Vector of initial layer bed temperatures for each extruder/filament. Provides the same value as first_layer_bed_temperature.
- **bed_temperature_initial_layer_single**: Initial layer bed temperature for the initial extruder. Same as bed_temperature_initial_layer[initial_extruder].
- **chamber_temperature**: Vector of chamber temperatures for each extruder/filament.
- **overall_chamber_temperature**: Overall chamber temperature. This value is the maximum chamber temperature of any extruder/filament used.
- **first_layer_bed_temperature**: Vector of first layer bed temperatures for each extruder/filament. Provides the same value as bed_temperature_initial_layer.
- **first_layer_temperature**: Vector of first layer temperatures for each extruder/filament.
## Timestamps
- **timestamp**: String containing current time in yyyyMMdd-hhmmss format.
- **year**: Current year.
- **month**: Current month.
- **day**: Current day.
- **hour**: Current hour.
- **minute**: Current minute.
- **second**: Current second.
## Presets
Each preset's ([Print process settings](home#process-settings), [Filament/Material settings](home#material-settings), [Printer settings](home#printer-settings)) variables can be used in your G-code scripts and configurations.
> [!TIP]
> To know the variable name you can hover your mouse over the variable in the UI.

View File

@@ -1,359 +0,0 @@
# How to Build
This wiki page provides detailed instructions for building OrcaSlicer from source on different operating systems, including Windows, macOS, and Linux.
It includes tool requirements, setup commands, and build steps for each platform.
Whether you're a contributor or just want a custom build, this guide will help you compile OrcaSlicer successfully.
- [Windows 64-bit](#windows-64-bit)
- [Windows Tools Required](#windows-tools-required)
- [Windows Hardware Requirements](#windows-hardware-requirements)
- [Windows Instructions](#windows-instructions)
- [MacOS 64-bit](#macos-64-bit)
- [MacOS Tools Required](#macos-tools-required)
- [MacOS Instructions](#macos-instructions)
- [Debugging in Xcode](#debugging-in-xcode)
- [Linux](#linux)
- [Using Docker](#using-docker)
- [Docker Dependencies](#docker-dependencies)
- [Docker Instructions](#docker-instructions)
- [Troubleshooting](#troubleshooting)
- [Linux Build](#linux-build)
- [Dependencies](#dependencies)
- [Common dependencies across distributions](#common-dependencies-across-distributions)
- [Additional dependencies for specific distributions](#additional-dependencies-for-specific-distributions)
- [Linux Instructions](#linux-instructions)
- [Unit Testing](#unit-testing)
- [Portable User Configuration](#portable-user-configuration)
- [Example folder structure](#example-folder-structure)
## Windows 64-bit
How to building with Visual Studio on Windows 64-bit.
### Windows Tools Required
- [Visual Studio](https://visualstudio.microsoft.com/vs/) 2026, 2022 or Visual Studio 2019
```shell
winget install --id=Microsoft.VisualStudio.Community -e
```
- [CMake](https://cmake.org/)
```shell
winget install --id=Kitware.CMake -e
```
- [Strawberry Perl](https://strawberryperl.com/)
```shell
winget install --id=StrawberryPerl.StrawberryPerl -e
```
- [Git](https://git-scm.com/)
```shell
winget install --id=Git.Git -e
```
- [git-lfs](https://git-lfs.com/)
```shell
winget install --id=GitHub.GitLFS -e
```
> [!TIP]
> GitHub Desktop (optional): A GUI for Git and Git LFS, which already includes both tools.
> ```shell
> winget install --id=GitHub.GitHubDesktop -e
> ```
> [!IMPORTANT]
> Check your CMake version. Run `cmake --version` in your terminal and verify it returns a **4.x** version.
> If you see an older version (e.g. 3.29), it's likely due to another copy in your system's PATH (e.g. from Strawberry Perl).
> You can run where cmake to check the active paths and rearrange your **System Environment Variables** > PATH, ensuring the correct CMake like `C:\Program Files\CMake\bin` appears before others like `C:\Strawberry\c\bin`.
![windows_variables_path](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/develop/windows_variables_path.png?raw=true)
![windows_variables_order](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/develop/windows_variables_order.png?raw=true)
### Windows Hardware Requirements
- Minimum 16 GB RAM
- Minimum 23 GB free disk space
- 64-bit CPU
- 64-bit Windows 10 or later
### Windows Instructions
1. Clone the repository:
- If using GitHub Desktop clone the repository from the GUI.
- If using the command line:
1. Clone the repository:
```shell
git clone https://github.com/OrcaSlicer/OrcaSlicer
```
2. Run lfs to download tools on Windows:
```shell
git lfs pull
```
2. Open the appropriate command prompt:
```MD
x64 Native Tools Command Prompt for VS
```
1. Navigate to correct drive (if needed), e.g.:
```shell
N:
```
2. Change directory to the cloned repository, e.g.:
```shell
cd N:\Repos\OrcaSlicer
```
3. Run the build script:
```shell
build_release_vs.bat
```
![vs_cmd](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/develop/vs_cmd.png?raw=true)
> [!NOTE]
> The build process will take a long time depending on your system but even with high-end hardware it can take up to 40 minutes.
> [!TIP]
> If you encounter issues, you can try to uninstall ZLIB from your Vcpkg library.
1. If successful, you will find the Visual Studio solution file in:
```shell
build\OrcaSlicer.sln
```
2. Open the solution in Visual Studio, set the build configuration to `Release` and run the `Local Windows Debugger`.
![compile_vs_local_debugger](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/develop/compile_vs_local_debugger.png?raw=true)
3. Your resulting executable will be located in:
```shell
\build\src\Release\orca-slicer.exe
```
> [!NOTE]
> The first time you build a branch, it will take a long time.
> Changes to .cpp files are quickly compiled.
> Changes to .hpp files take longer, depending on what you change.
> If you switch back and forth between branches, it also takes a long time to rebuild, even if you haven't made any changes.
> [!TIP]
> If the build fails, try deleting the `build/` and `deps/build/` directories to clear any cached build data. Rebuilding after a clean-up is usually sufficient to resolve most issues.
## MacOS 64-bit
How to building with Xcode on MacOS 64-bit.
### MacOS Tools Required
- Xcode
- CMake (version 3.31.x is mandatory)
- Git
- gettext
- libtool
- automake
- autoconf
- texinfo
> [!TIP]
> You can install most of them by running:
> ```shell
> brew install gettext libtool automake autoconf texinfo
> ```
Homebrew currently only offers the latest version of CMake (e.g. **4.X**), which is not compatible. To install the required version **3.31.X**, follow these steps:
1. Download CMake **3.31.10** from: [https://cmake.org/download/](https://cmake.org/download/)
2. Install the application (drag it to `/Applications`).
3. Add the following line to your shell configuration file (`~/.zshrc` or `~/.bash_profile`):
```sh
export PATH="/Applications/CMake.app/Contents/bin:$PATH"
```
4. Restart the terminal and check the version:
```sh
cmake --version
```
5. Make sure it reports a **3.31.x** version.
> [!IMPORTANT]
> If you've recently upgraded Xcode, be sure to open Xcode at least once and install the required macOS build support.
### MacOS Instructions
1. Clone the repository:
```shell
git clone https://github.com/OrcaSlicer/OrcaSlicer
cd OrcaSlicer
```
2. Build the application:
```shell
./build_release_macos.sh
```
3. Open the application:
```shell
open build/arm64/OrcaSlicer/OrcaSlicer.app
```
### Debugging in Xcode
To build and debug directly in Xcode:
1. Open the Xcode project:
```shell
open build/arm64/OrcaSlicer.xcodeproj
```
2. In the menu bar:
- **Product > Scheme > OrcaSlicer**
- **Product > Scheme > Edit Scheme...**
- Under **Run > Info**, set **Build Configuration** to `RelWithDebInfo`
- Under **Run > Options**, uncheck **Allow debugging when browsing versions**
- **Product > Run**
## Linux
Linux distributions are available in two formats: [using Docker](#using-docker) (recommended) or [building directly](#linux-build) on your system.
### Using Docker
How to build and run OrcaSlicer using Docker.
#### Docker Dependencies
- Docker
- Git
#### Docker Instructions
```shell
git clone https://github.com/OrcaSlicer/OrcaSlicer && cd OrcaSlicer && ./scripts/DockerBuild.sh && ./scripts/DockerRun.sh
```
### Troubleshooting
The `scripts/DockerRun.sh` script includes several commented-out options that can help resolve common issues. Here's a breakdown of what they do:
- `xhost +local:docker`: If you encounter an "Authorization required, but no authorization protocol specified" error, run this command in your terminal before executing `scripts/DockerRun.sh`. This grants Docker containers permission to interact with your X display server.
- `-h $HOSTNAME`: Forces the container's hostname to match your workstation's hostname. This can be useful in certain network configurations.
- `-v /tmp/.X11-unix:/tmp/.X11-unix`: Helps resolve problems with the X display by mounting the X11 Unix socket into the container.
- `--net=host`: Uses the host's network stack, which is beneficial for printer Wi-Fi connectivity and D-Bus communication.
- `--ipc host`: Addresses potential permission issues with X installations that prevent communication with shared memory sockets.
- `-u $USER`: Runs the container as your workstation's username, helping to maintain consistent file permissions.
- `-v $HOME:/home/$USER`: Mounts your home directory into the container, allowing you to easily load and save files.
- `-e DISPLAY=$DISPLAY`: Passes your X display number to the container, enabling the graphical interface.
- `--privileged=true`: Grants the container elevated privileges, which may be necessary for libGL and D-Bus functionalities.
- `-ti`: Attaches a TTY to the container, enabling command-line interaction with OrcaSlicer.
- `--rm`: Automatically removes the container once it exits, keeping your system clean.
- `orcaslicer $*`: Passes any additional parameters from the `scripts/DockerRun.sh` script directly to the OrcaSlicer executable within the container.
By uncommenting and using these options as needed, you can often resolve issues related to display authorization, networking, and file permissions.
### Linux Build
How to build OrcaSlicer on Linux.
#### Dependencies
The build system supports multiple Linux distributions including Ubuntu/Debian and Arch Linux. All required dependencies will be installed automatically by the provided shell script where possible, however you may need to manually install some dependencies.
> [!NOTE]
> Fedora and other distributions are not currently supported, but you can try building manually by installing the required dependencies listed below.
##### Common dependencies across distributions
- autoconf / automake
- cmake
- curl / libcurl4-openssl-dev
- dbus-devel / libdbus-1-dev
- eglexternalplatform-dev / eglexternalplatform-devel
- extra-cmake-modules
- file
- gettext
- git
- glew-devel / libglew-dev
- gstreamer-devel / libgstreamerd-3-dev
- gtk3-devel / libgtk-3-dev
- libmspack-dev / libmspack-devel
- libsecret-devel / libsecret-1-dev
- libspnav-dev / libspnav-devel
- libssl-dev / openssl-devel
- libtool
- libudev-dev
- mesa-libGLU-devel
- ninja-build
- texinfo
- webkit2gtk-devel / libwebkit2gtk-4.0-dev or libwebkit2gtk-4.1-dev
- wget
##### Additional dependencies for specific distributions
- **Ubuntu 22.x/23.x**: libfuse-dev, m4
- **Arch Linux**: mesa, wayland-protocols
#### Linux Instructions
1. **Install system dependencies:**
```shell
./build_linux.sh -u
```
2. **Build dependencies:**
```shell
./build_linux.sh -d
```
3. **Build OrcaSlicer with tests:**
```shell
./build_linux.sh -st
```
4. **Build AppImage (optional):**
```shell
./build_linux.sh -i
```
5. **All-in-one build (recommended):**
```shell
./build_linux.sh -dsti
```
**Additional build options:**
- `-b`: Build in debug mode (mostly broken at runtime for a long time; avoid unless you want to be fixing failed assertions)
- `-c`: Force a clean build
- `-C`: Enable ANSI-colored compile output (GNU/Clang only)
- `-e`: Build RelWithDebInfo (release + symbols)
- `-j N`: Limit builds to N cores (useful for low-memory systems)
- `-1`: Limit builds to one core
- `-l`: Use Clang instead of GCC
- `-p`: Disable precompiled headers (boost ccache hit rate)
- `-r`: Skip RAM and disk checks (for low-memory systems)
> [!NOTE]
> The build script automatically detects your Linux distribution and uses the appropriate package manager (apt, pacman) to install dependencies.
> [!TIP]
> For first-time builds, use `./build_linux.sh -u` to install dependencies, then `./build_linux.sh -dsti` to build everything.
> [!WARNING]
> If you encounter memory issues during compilation, use `-j 1` or `-1` to limit parallel compilation and `-r` to skip memory checks.
#### Unit Testing
See [How to Test](How-to-test) for more details.
---
## Portable User Configuration
If you want OrcaSlicer to use a custom user configuration folder (e.g., for a portable installation), you can simply place a folder named `data_dir` next to the OrcaSlicer executable. OrcaSlicer will automatically use this folder as its configuration directory.
This allows for multiple self-contained installations with separate user data.
> [!TIP]
> This feature is especially useful if you want to run OrcaSlicer from a USB stick or keep different profiles isolated.
### Example folder structure
```shell
OrcaSlicer.exe
data_dir/
```
You dont need to recompile or modify any settings — this works out of the box as long as `data_dir` exists in the same folder as the executable.

View File

@@ -1,434 +0,0 @@
# Guide: Develop Profiles for OrcaSlicer
## Introduction
This guide will help you develop profiles for OrcaSlicer.
## High-level Overview
OrcaSlicer uses JSON files to store profiles. There are four types of profiles:
1. Printer model (type `machine_model`). Example: `Orca 3D Fuse1.json`
2. Printer variant (type `machine`). Example: `Orca 3D Fuse1 0.2 nozzle.json`
3. Filament (type `filament`). Example: `Generic PLA @Orca 3D Fuse1@.json`
4. Process (type `process`). Example: `0.10mm Standard @Orca 3D Fuse1 0.2.json`
Additionally, there is an overall meta file for each vendor (`Orca 3D.json`).
For easier understanding, let's consider a scenario with a printer manufacturer called `Orca 3D`. The manufacturer offers one printer model called `Fuse 1`, which supports 0.2/0.4/0.6/0.8mm nozzles and common market filaments.
In this case:
- Vendor profile: `Orca 3D`
- Printer profile: `Orca 3D Fuse1`
- Printer variant profile: `Orca 3D Fuse1 0.4 nozzle`
- Filament profile: `Generic PLA @Orca 3D Fuse1@`
- Process profile: `0.20mm Standard @Orca 3D Fuse1 0.4`
The profile name should be same as the filename without the `.json` extension in principal.
Naming conventions:
1. Vendor profile: `vendor_name.json`
2. Printer profile: `vendor_name` + `printer_name` + `.json`
3. Printer variant profile: `vendor_name` + `printer_variant_name` + `.json` (where `printer_variant_name` typically includes `printer_name` + `nozzle_diameter`)
4. Filament profile: `filament_vendor_name` + `filament_name` + " @" + `vendor_name` + `printer_name`/`printer_variant_name` + `.json`
5. Process profile: `layer_height` + `preset_name` + " @" + `vendor_name` + `printer_name`/`printer_variant_name` + `.json` (`preset_name` typically includes "standard," "fine," "fast," "draft," etc.)
## File Structure and Templates
Profiles should be structured in the following way under the OrcaSlicer installation directory:
```plaintext
resources\profiles\
├── Orca 3D.json
└── Orca 3D\
├── machine\
│ ├── Orca 3D Fuse1.json
│ ├── Orca 3D Fuse1 0.2 nozzle.json
│ └── Orca 3D Fuse1 0.4 nozzle.json
├── process\
│ ├── 0.10mm Standard @Orca 3D Fuse1 0.2.json
│ └── 0.20mm Standard @Orca 3D Fuse1 0.4.json
└── filament\
└── Generic PLA @Orca 3D Fuse1@.json
```
> [!TIP]
> Use short vendor names in filenames to avoid excessive length.
> [!NOTE]
> Filament profiles are **optional**. Create them only if the vendor has specifically tuned profiles for the given printer. See [Filament profiles](#filament-profiles) for details.
Template files for profiles are available in:
```shell
OrcaSlicer\resources\profiles_template\Template
```
These templates can be used as a starting point for new printer, filament, and process profiles.
## Filament Profiles
OrcaSlicer features a global filament library called `OrcaFilamentLibrary`, which is automatically available for all printers. It includes generic filaments like `Generic PLA @System` and `Generic ABS @System` etc.
Printer vendors can override specific filaments in the global library for certain printer models by creating new filament profiles.
Relationship diagram:
```mermaid
graph TD;
OrcaFilamentLibrary-->Orca_3D_filament;
OrcaFilamentLibrary-->Vendor_A_filament;
OrcaFilamentLibrary-->Vendor_B_filament;
```
> [!IMPORTANT]
> Create new filament profiles only if you have truly specifically tuned the filament for the given printer. Otherwise, use the global library. The global library has a better chance to receive optimizations and updates from OrcaSlicer contributors, which will benefit users of all printers.
### Adding Filament Profiles to the Global Library
In this section, we will discuss how to add a new filament profile into the global library.
If you want to add a new generic profile into the global library, you need to create a new file in the `resources\profiles\OrcaFilamentLibrary\filament` folder. If a base type already exists in the global library, you can use this file as a base profile by inheriting it.
The following sample JSON file shows how to create a new generic filament profile `Generic PLA-GF @System` in the global library.
1. The first step is to create a new file in the `resources\profiles\OrcaFilamentLibrary\filament` folder. The file name should be `Generic PLA-GF @System.json`. Please note that we leave the `compatible_printers` field empty so that it is available for all printers.
```json
{
"type": "filament",
"filament_id": "GFL99",
"setting_id": "GFSA05",
"name": "Generic PLA-GF @System",
"from": "system",
"instantiation": "true",
"inherits": "fdm_filament_pla",
"filament_type": ["PLA-GF"],
"filament_flow_ratio": [
"0.96"
],
"compatible_printers": []
}
```
2. Register the profile in `resources\profiles\OrcaFilamentLibrary.json`:
```json
{
"name": "OrcaFilamentLibrary",
"version": "02.02.00.04",
"force_update": "0",
"description": "Orca Filament Library",
"filament_list": [
// ...
{
"name": "Generic PLA-GF @System",
"sub_path": "filament/Generic PLA-GF @System.json"
}
]
}
```
3. The last step is to validate the newly added filament profiles see [Validate Profiles](#validate-profiles).
> [!NOTE]
> If the filament is compatible with AMS, ensure that the `filament_id` value **does not exceed 8 characters** to maintain AMS compatibility.
> [!TIP]
> **Testing Profile Changes**
>
> When developing profiles, you may notice that changes aren't reflected in OrcaSlicer after editing profile files. This happens because OrcaSlicer caches profiles in the system folder.
> To force OrcaSlicer to load your updated profiles:
> 1. **Access the configuration folder**: Go to **Help** → **Show Configuration Folder**
> ![go-to-configuration-folder](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/develop/go-to-configuration-folder.png?raw=true)
> 2. **Clear the cache**: Delete the `system` folder to remove cached profiles
> ![profile-delete-system-folder](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/develop/profile-delete-system-folder.png?raw=true)
> 3. **Restart OrcaSlicer**: Launch the application to load your updated profiles
> This process forces OrcaSlicer to update its profile cache from the source files in the `resources/profiles/` directory.
### Adding Filament Profiles to Printer Vendor Library
In this section, we will discuss how to add a new filament profile for a certain vendor.
If you want to add a new filament profile, whether it's a brand new profile or a specialized version of a global filament profile for a given printer, you need to create a new file in the `resources\profiles\vendor_name\filament` folder. If a base type already exists in the global library, you can use this file as a base profile by inheriting it.
Below is a sample JSON file showing how to create a specialized `Generic ABS` filament profile for the ToolChanger printer.
Please note that here we must leave the compatible_printers field non-empty, unlike in the global library.
```json
{
"type": "filament",
"setting_id": "GFB99_MTC_0",
"name": "Generic ABS @MyToolChanger",
"from": "system",
"instantiation": "true",
"inherits": "Generic ABS @System",
"filament_cooling_final_speed": [
"3.5"
],
"filament_cooling_initial_speed": [
"10"
],
"filament_cooling_moves": [
"2"
],
"filament_load_time": [
"10.5"
],
"filament_loading_speed": [
"10"
],
"filament_loading_speed_start": [
"50"
],
"filament_multitool_ramming": [
"1"
],
"filament_multitool_ramming_flow": [
"40"
],
"filament_stamping_distance": [
"45"
],
"filament_stamping_loading_speed": [
"29"
],
"filament_unload_time": [
"8.5"
],
"filament_unloading_speed": [
"100"
],
"compatible_printers": [
"MyToolChanger 0.4 nozzle",
"MyToolChanger 0.2 nozzle",
"MyToolChanger 0.6 nozzle",
"MyToolChanger 0.8 nozzle"
]
}
```
> [!NOTE]
> If the filament is compatible with AMS, ensure that the `filament_id` value **does not exceed 8 characters** to maintain AMS compatibility.
## Process Profiles
Process profiles define print quality and behavior. They follow a structure similar to filament profiles:
- A common base file, e.g., `fdm_process_common.json`, acts as the parent.
- Vendor-specific process profiles should inherit from the base using the `inherits` field.
- Profiles are stored under:
```shell
resources\profiles\vendor_name\process\
```
- **There are no global process profiles**.
- Each process profile includes a `"compatible_printers"` field with an array of compatible printer variant names.
Example:
```json
{
"type": "process",
"name": "0.10mm Standard @ExampleVendor Printer 0.2",
"inherits": "fdm_process_common",
"from": "system",
"instantiation": "true",
"compatible_printers": [
"ExampleVendor Printer 0.2 nozzle"
]
}
```
## Printer Model Profiles
- Printer model profiles (type `machine_model`) describe the general printer information.
- Example fields: `nozzle_diameter`, `bed_model`, `bed_texture`, `model_id`, etc.
- Stored in:
```shell
resources\profiles\vendor_name\machine\
```
- Each vendor's folder may contain an image named:
```shell
[machine_model_list.name]_cover.png
```
This image will be used in the UI.
Example model profile:
```json
{
"type": "machine_model",
"name": "Example M5",
"nozzle_diameter": "0.2;0.25;0.4;0.6",
"bed_model": "M5-Example-bed.stl",
"bed_texture": "M5-Example-texture.svg",
"model_id": "V1234",
"family": "Example",
"machine_tech": "FFF",
"default_materials": "Example Generic PLA;Example Generic PETG"
}
```
## Printer Variant Profiles
- Printer variants (type `machine`) define specific nozzle configurations and mechanical details.
- Each variant must inherit from a common base like `fdm_machine_common.json`.
- Must list the compatible nozzle diameter in the `nozzle_diameter` array.
- Example fields include `printer_model`, `printer_variant`, `default_print_profile`, `printable_area`, etc.
Example variant profile:
```json
{
"type": "machine",
"name": "Example M5 0.2 nozzle",
"inherits": "fdm_machine_common",
"from": "system",
"setting_id": "GM001",
"instantiation": "true",
"nozzle_diameter": ["0.2"],
"printer_model": "Example M5",
"printer_variant": "0.2",
"default_filament_profile": ["Example Generic PLA"],
"default_print_profile": "0.10mm Standard 0.2mm nozzle @Example",
"printable_area": ["0x0", "235x0", "235x235", "0x235"],
"nozzle_type": "brass"
}
```
## Models
- The `model` directory under the vendor folder is intended to behave similarly to `machine` profiles.
- Used for additional printer-related 3D models or definitions, stored at:
```shell
resources\profiles\vendor_name\model\
```
## Vendor Meta File
```shell
resources\profiles\vendor_name.json
```
Each vendor must include a JSON file in the `resources\profiles` directory, named `vendor_name.json`. This file lists all available models, variants, processes, and filaments:
Example:
```json
{
"name": "ExampleVendor",
"version": "01.00.00.00",
"force_update": "1",
"description": "Example configuration",
"machine_model_list": [
{
"name": "Example M5",
"sub_path": "machine/Example M5.json"
}
],
"machine_list": [
{
"name": "fdm_machine_common",
"sub_path": "machine/fdm_machine_common.json"
}
],
"process_list": [
{
"name": "fdm_process_common",
"sub_path": "process/fdm_process_common.json"
}
],
"filament_list": [
{
"name": "fdm_filament_common",
"sub_path": "filament/fdm_filament_common.json"
}
]
}
```
## Validate Profiles
You can validate your profiles using both the **OrcaSlicer profile validator** and the **Python validation script**. These tools are designed to check different aspects of the profiles, so both should be executed and pass without errors to ensure full compatibility.
> [!NOTE]
> **✅ Recommendation:** Always run **both** the OrcaSlicer validator and the Python script to ensure all aspects of the profiles are valid.
### 1. OrcaSlicer Profile Validator
You can run OrcaSlicer to verify if the filament you just added is available and usable. You can also use the [Orca profile validator](https://github.com/SoftFever/Orca_tools/releases/tag/1) tool to help debug any errors.
> [!IMPORTANT]
> You need to delete the `%appdata%/OrcaSlicer/system` folder to force OrcaSlicer to reload your lastest changes.
The process is the same if you want to add a new brand filament profile into the global library. You need to create a new file in the `resources\profiles\OrcaFilamentLibrary\filament\brand_name` folder. The only difference is that you should put the file into the brand's own subfolder.
#### Usage
```shell
-h [ --help ] help
-p [ --path ] arg profile folder
-v [ --vendor ] arg Vendor name. Optional, all profiles present in the folder will be validated if not specified
-l [ --log_level ] arg (=2) Log level. Optional, default is 2 (warning). Higher values produce more detailed logs.
```
#### Example
```shell
./OrcaSlicer_profile_validator -p ~/codes/OrcaSlicer/resources/profiles -l 2 -v Custom
```
#### Sample result with errors
```shell
PS D:\codes\OrcaSlicer> ."D:/codes/OrcaSlicer/build/src/Release/OrcaSlicer_profile_validator.exe" --path d:\codes\OrcaSlicer\resources\profiles -l 2 -v Custom
[2024-02-28 21:23:06.102138] [0x0000a4e8] [error] Slic3r::ConfigBase::load_from_json: parse d:\codes\OrcaSlicer\resources\profiles/Custom/machine/fdm_klipper_common.json got a nlohmann::detail::parse_error, reason = [json.exception.parse_error.101] parse error at line 9, column 38: syntax error while parsing object - unexpected string literal; expected '}'
...
Validation failed
```
#### Sample result with success
```shell
PS D:\codes\OrcaSlicer\build\src\RelWithDebInfo> ."D:/codes/OrcaSlicer/build/src/Release/OrcaSlicer_profile_validator.exe" --path d:\codes\OrcaSlicer\resources\profiles -l 2 -v Custom
Validation completed successfully
```
> [!WARNING]
> Use `OrcaSlicer_profile_validator` on Ubuntu and `OrcaSlicer_profile_validator.exe` on Windows.
---
### 2. Python Profile Validation Script
In addition to the Orca validator, you should run the `orca_extra_profile_check.py` script. This script performs additional checks like:
- Validation of `compatible_printers` in filament profiles
- Consistency of filament names
- Validation of default materials in machine profiles (optional)
#### Example command
```shell
python ./orca_extra_profile_check.py
```
You can also enable or disable specific checks:
- `--help`: displays help information
- `--vendor` (optional): checks only the specified vendor. If omitted, all vendors are checked.
- `--check-filaments` (enabled by default): checks `compatible_printers` fields in filament profiles
- `--check-materials`: checks default material names in machine profiles
- `--check-obsolete-keys`: checks for obsolete keys in profiles
#### Sample usage with all checks enabled
```shell
python ./orca_extra_profile_check.py --vendor="vendor_name" --check-filaments --check-materials
```
The script will output the number of errors found and exit with a non-zero status code if any issues are detected.

View File

@@ -1,27 +0,0 @@
# How to Test
This wiki page describes how to build and run tests on Linux. It should eventually provide guidance on how to add tests for a new feature.
## Build Tests
Can be built when you are building Orca Slicer binary by including the `-t` flag for `build_linux.sh`:
```
build_linux.sh -st
```
Test binaries will then appear under `build/tests`. As of this writing, not all tests will be built.
## Run Unit Tests
### Run All
```
ctest --test-dir build/tests
```
### Run a Specific Set
```
ctest --test-dir build/tests/slic3rutils
```

View File

@@ -1,266 +0,0 @@
# How to Contribute to the Wiki
This guide explains how to contribute to the OrcaSlicer wiki.
OrcaSlicer uses GitHub's wiki feature, which lets users and developers create and edit documentation collaboratively.
We encourage developers and users to contribute by updating existing pages and adding new content. This helps keep the documentation accurate and useful.
When adding new features, consider updating the wiki so users can access the latest guidance.
- [Wiki Structure](#wiki-structure)
- [Home](#home)
- [Index and Navigation](#index-and-navigation)
- [File Naming and Organization](#file-naming-and-organization)
- [Orca to Wiki Redirection](#orca-to-wiki-redirection)
- [Formatting and Style](#formatting-and-style)
- [Markdown Formatting](#markdown-formatting)
- [Alerts and Callouts](#alerts-and-callouts)
- [Images](#images)
- [Image Naming](#image-naming)
- [Image Placement](#image-placement)
- [Linking Images](#linking-images)
- [Examples](#examples)
- [Avoid the Following](#avoid-the-following)
- [Resize Images](#resize-images)
- [Image Cropping and Highlighting](#image-cropping-and-highlighting)
- [Recommended Formats](#recommended-formats)
- [Structuring Content](#structuring-content)
- [Commands and Code Blocks](#commands-and-code-blocks)
- [External Links](#external-links)
## Wiki Structure
Each wiki page is a Markdown file located in the `doc` directory of the repository. The wiki is organized into sections that cover different areas of the project.
### Home
The Home page is the starting point for the OrcaSlicer wiki. From there you can navigate to sections and topics related to the project.
When you create a new page or section, link it from the Home page under the appropriate category.
The Home page currently organizes content in these top-level entries:
- ![printer](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/resources/images/printer.svg?raw=true) [Printer Settings](home#printer-settings)
- ![filament](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/resources/images/filament.svg?raw=true) [Material Settings](home#material-settings)
- ![process](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/resources/images/process.svg?raw=true) [Process Settings](home#process-settings)
- ![tab_3d_active](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/resources/images/tab_3d_active.svg?raw=true) [Prepare](home#prepare)
- ![tab_calibration_active](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/resources/images/tab_calibration_active.svg?raw=true) [Calibrations](home#calibrations)
- ![im_code](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/resources/images/im_code.svg?raw=true) [Developer Section](home#developer-section)
Each section can have multiple pages covering specific topics. For example, the [Process Settings](home#process-settings) section includes pages on [quality](home#quality-settings), [support](home#support-settings), and [others](home#others-settings).
#### Index and Navigation
GitHub Wiki uses file names as page identifiers. To link to a page, use the file name without the `.md` extension. If a file lives in a subdirectory, **do not include the subdirectory** in the link; link directly to the file name from the Home page.
For example, if you add `doc/calibration/flow-rate-calib.md`, link it like this:
```markdown
[Flow Rate Calibration](flow-rate-calib)
```
For long pages, include a table of contents at the top to help readers find sections quickly.
```markdown
- [Wiki Structure](#wiki-structure)
- [Home](#home)
- [Index and Navigation](#index-and-navigation)
- [File Naming and Organization](#file-naming-and-organization)
- [Formatting and Style](#formatting-and-style)
```
> [!NOTE]
> If you're adding a new section, follow the existing structure and make sure it doesn't already fit an existing category. Link it from the Home page accordingly.
### File Naming and Organization
When creating new pages, follow these file-naming conventions:
- Use unique file names to avoid conflicts.
- Use descriptive names that reflect the page's content.
- Use kebab-case for filenames (e.g.: `How-to-wiki.md`).
- If a page belongs to a section, include a suffix that clarifies it (for example, calibration pages should end with `-calib.md`, e.g. `flow-rate-calib.md`).
- Place files in the appropriate subdirectory when applicable (e.g.: `doc/calibration/` for calibration-related content).
## Orca to Wiki Redirection
OrcaSlicer can redirect users from the GUI to the appropriate wiki pages, making it easier to find relevant documentation.
The option-to-wiki mapping is defined in [src/slic3r/GUI/Tab.cpp](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/src/slic3r/GUI/Tab.cpp). Any option added with `append_single_option_line` can be mapped to a wiki page using a second string argument.
```cpp
optgroup->append_single_option_line("OPTION_NAME"); // Option without wiki page/redirection
optgroup->append_single_option_line("OPTION_NAME", "WIKI_PAGE"); // Option with wiki page and redirection
```
You can also point to a specific section within a wiki page by appending a fragment identifier (for example `#section-name`).
Example:
```cpp
optgroup->append_single_option_line("seam_gap","quality_settings_seam"); // Wiki page and redirection
optgroup->append_single_option_line("seam_slope_type", "quality_settings_seam#scarf-joint-seam"); // Wiki page and redirection to `Scarf Joint Seam` section
```
## Formatting and Style
Follow these style and formatting conventions when contributing to the wiki.
### Markdown Formatting
The wiki uses standard Markdown syntax for formatting and aims to maintain a consistent style across all pages. Avoid using raw HTML tags and prefer Markdown formatting instead.
Ensure your indentation is consistent, especially for code blocks and lists.
Refer to the [GitHub Markdown Guide](https://guides.github.com/features/mastering-markdown/) for more information on Markdown syntax.
### Alerts and Callouts
Use GitHub's alert syntax to add inline notes and warnings:
```markdown
> [!NOTE]
> Useful information that readers should know.
> [!TIP]
> Helpful advice for doing things more easily.
> [!IMPORTANT]
> Key information required to achieve a goal.
> [!WARNING]
> Urgent information to avoid problems.
> [!CAUTION]
> Warnings about risks or negative outcomes.
```
> [!NOTE]
> Refer to the [GitHub Alerts documentation](https://docs.github.com/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax#alerts) for more details.
## Images
Images are encouraged to enhance the clarity and quality of the wiki content. They help illustrate concepts, provide examples, and improve readability.
> [!CAUTION]
> Do not use images from third-party sources unless you have the proper permissions.
### Image Naming
- Use clear, descriptive filenames that reflect the image content.
- For section-specific images, include the section name or initials (for example `pa-[description].png` for Pressure Advance images).
### Image Placement
- General images should be placed in the `doc/images/` directory.
- Section-specific images should be stored in their corresponding subdirectories (e.g., `doc/images/calibration/` for calibration content).
> [!TIP]
> You can use `\resources\images` images used in the GUI.
### Linking Images
Always use raw GitHub URLs for image links to ensure correct display:
Format = `![`filename`](` + Base URL + filename.extension + Raw tag + `)`
- Base URL:
```markdown
https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/
```
- Raw tag:
```markdown
?raw=true
```
#### Examples
- For an image in `doc/images/` named `calibration.png`:
```markdown
![calibration](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/calibration.png?raw=true)
```
- For an image in a subdirectory like `doc/images/GUI/combobox.png`:
```markdown
![combobox](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/GUI/combobox.png?raw=true)
```
> [!IMPORTANT]
> New or moved images may not appear in previews until the pull request is merged. Double-check paths and update links if you move files.
#### Avoid the Following
- Relative paths
- GitHub Assets/user-content/user-images URLs
- External image links from temporary or unreliable hosts
- Images containing personal or sensitive information
- Using images for content that can be expressed in text, such as equations or code—use Markdown syntax or Mermaid/Math formatting instead.
> [!NOTE]
> When contributing section-specific images, follow the naming conventions and directory structure.
#### Resize Images
Avoid the resize of images and let the Wiki handle it automatically.
If resizing is necessary (e.g., for thumbnails), use the following syntax:
HTML Format = `<img alt="` + filename + `"` + `src="` + Base URL + filename.extension + Raw tag + size limit.
Example:
```html
<img alt="IS_damp_marlin_print_measure" src="https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/InputShaping/IS_damp_marlin_print_measure.jpg?raw=true" height="200">
```
### Image Cropping and Highlighting
To ensure clarity:
- Crop images to focus on relevant areas.
- Use simple annotations (arrows, circles, rectangles) to highlight important parts without overloading the image.
### Recommended Formats
- **JPG:** Suitable for photographs. Avoid for images with text or fine detail due to compression artifacts.
- **PNG:** Ideal for screenshots or images with transparency. Ensure sufficient contrast for light and dark modes.
- **SVG:** Preferred when possible. SVGs support theme adaptation (light/dark mode), making them ideal for icons and diagrams.
## Structuring Content
Each page should have a clear objective. After a short introduction, choose a structure that fits the content:
- **Step-by-step guides:** Use for sequential procedures (for example calibration).
- **GUI-based reference:** Describe settings following OrcaSlicer's UI when sequence isn't required.
Example: explain **Layer Height** before **Initial Layer Height**, since the former is global and the latter only applies to the first layer.
## Commands and Code Blocks
When adding commands or code blocks please use the [Code Block with Syntax Highlighting feature of Markdown](https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/creating-and-highlighting-code-blocks#syntax-highlighting).
- Use triple backticks (```) to enclose code blocks.
- Specify the language for proper highlighting and readability.
````markdown
```json
{
"key": "value"
}
```
````
```json
{
"key": "value"
}
```
## External Links
Be careful when linking to external resources.
Ensure links are relevant and reliable and cite papers or articles when appropriate.

View File

@@ -1,111 +0,0 @@
# Localization and translation guide
The purpose of this guide is to describe how to contribute to the OrcaSlicer translations. We use GNUgettext for extracting string resources from the project and PoEdit for editing translations.
Those can be downloaded here:
- [GNUgettext](https://www.gnu.org/software/gettext/) package contains a set of tools to extract strings from the source code and to create the translation Catalog.
- [PoEdit](https://poedit.net) provides good interface for the translators.
After GNUgettext is installed, it is recommended to add the path to gettext/bin to PATH variable.
Full manual for GNUgettext can be seen here: [http://www.gnu.org/software/gettext/manual/gettext.html](http://www.gnu.org/software/gettext/manual/gettext.html)
### Scenario 1. How do I add a translation or fix an existing translation
1. Get PO-file 'OrcaSlicer_xx.pot' from corresponding sub-folder here:
[https://github.com/OrcaSlicer/OrcaSlicer/tree/master/localization/i18n](https://github.com/OrcaSlicer/OrcaSlicer/tree/master/localization/i18n)
2. Open this file in PoEdit as "Edit a translation"
3. Apply your corrections to the translation
4. Push changed OrcaSlicer_xx.po into the original folder
5. copy OrcaSlicer_xx.mo into resources/i18n/xx and rename it to OrcaSlicer.mo, then push the changed file.
### Scenario 2. How do I add a new language support
1. Get file OrcaSlicer.pot here :
[https://github.com/OrcaSlicer/OrcaSlicer/tree/master/localization/i18n](https://github.com/OrcaSlicer/OrcaSlicer/tree/master/localization/i18n)
2. Open it in PoEdit for "Create new translation"
3. Select Translation Language (for example French).
4. As a result you will have fr.po - the file containing translation to French.
Notice. When the translation is complete you need to:
- Rename the file to OrcaSlicer_fr.po
- Click "Save file" button. OrcaSlicer_fr.mo will be created immediately
- Bambu_Studio_fr.po needs to be copied into the sub-folder fr of [https://github.com/OrcaSlicer/OrcaSlicer/tree/master/localization/i18n](https://github.com/OrcaSlicer/OrcaSlicer/tree/master/localization/i18n), and be pushed
- copy OrcaSlicer_xx.mo into resources/i18n/xx and rename it to OrcaSlicer.mo, then push the changed file.
( name of folder "fr" means "French" - the translation language).
### Scenario 3. How do I add a new text resource when implementing a feature to OrcaSlicer
Each string resource in OrcaSlicer available for translation needs to be explicitly marked using L() macro like this:
```C++
auto msg = L("This message to be localized")
```
To get translated text use one of needed macro/function (`_(s)` or `_CHB(s)` ).
If you add new file resource, add it to the list of files containing macro `L()`
### Scenario 4. How do I use GNUgettext to localize my own application taking OrcaSlicer as an example
1. For convenience create a list of files with this macro `L(s)`. We have
https://github.com/OrcaSlicer/OrcaSlicer/blob/master/localization/i18n/list.txt.
2. Create template file(*.POT) with GNUgettext command:
```shell
xgettext --keyword=L --add-comments=TRN --from-code=UTF-8 --debug -o OrcaSlicer.pot -f list.txt
```
Use flag `--from-code=UTF-8` to specify that the source strings are in UTF-8 encoding
Use flag `--debug` to correctly extract formatted strings(used %d, %s etc.)
3. Create PO- and MO-files for your project as described above.
4. To merge old PO-file with strings from created new POT-file use command:
```shell
msgmerge -N -o new.po old.po new.pot
```
Use option `-N` to not using fuzzy matching when an exact match is not found.
5. To concatenate old PO-file with strings from new PO-file use command:
```shell
msgcat -o new.po old.po
```
6. Create an English translation catalog with command:
```shell
msgen -o new.po old.po
```
> [!NOTE]
> In this Catalog it will be totally same strings for initial text and translated.
When you have Catalog to translation open POT or PO file in PoEdit and start translating.
## General guidelines for OrcaSlicer translators
- We recommend using _PoEdit_ application for translation (as described above). It will help you eliminate most punctuation errors and will show you strings with "random" translations (if the fuzzy parameter was used).
- To check how the translated text looks on the UI elements, test it :) If you use _PoEdit_, all you need to do is save the file. At this point, a MO file will be created. Rename it OrcaSlicer.mo, and you can run OrcaSlicer (see above).
- If you see an encoding error (garbage characters instead of Unicode) somewhere in OrcaSlicer, report it. It is likely not a problem of your translation, but a bug in the software.
- See on which UI elements the translated phrase will be used. Especially if it's a button, it is very important to decide on the translation and not write alternative translations in parentheses, as this will significantly increase the width of the button, which is sometimes highly undesirable:
- If you decide to use autocorrect or any batch processing tool, the output requires very careful proofreading. It is very easy to make it do changes that break things big time.
- **Any formatting parts of the phrases must remain unchanged.** For example, you should not change `%1%` to `%1 %`, you should not change `%%` to `%` (for percent sign) and similar. This will lead to application crashes.
- Please pay attention to spaces, line breaks (\n) and punctuation marks. **Don't add extra line breaks.** This is especially important for parameter names.
- Description of the parameters should not contain units of measurement. For example, "Enable fan if layer print time is less than ~~n seconds~~"
- For units of measurement, use the international system of units. Use "s" instead of "sec".
- If the phrase doesn't have a dot at the end, don't add it. And if it does, then don't forget to :)
- It is useful to stick to the same terminology in the application (especially with basic terms such as "filament" and similar). Stay consistent. Otherwise it will confuse users.

View File

@@ -1,47 +0,0 @@
# Preset and Bundle
This page deals with the explanation for 3 classes in the code.
## [`Preset`](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/src/libslic3r/Preset.hpp)
As the name might suggest this class deals with presets for various things. It defines an enum `Type` which basically tells you what kind of data the present contains. Below are a few explained and there corresponding UI elements
> [!WARNING]
> There is a lot of outdated and legacy code in the code base.
- `TYPE_PRINT`: Refers to a process preset. It's called 'Print' probably due to some legacy code.
![process-preset-full](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/GUI/process-preset-full.png?raw=true)
- `TYPE_FILAMENT`: As the name suggests this preset is for filaments
![filament-preset](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/GUI/filament-preset.png?raw=true)
- `TYPE_PRINTER`: Preset for printers.
![printer-preset](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/GUI/printer-preset.png?raw=true)
There are other preset types but some of them are for SLA. Which is legacy code, since SLA printers are no longer supported. Above 3 are the important types.
## [`PresetBundle`](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/src/libslic3r/PresetBundle.hpp)
This is a bundle containing a few types of `PresetCollection`. One bundle has presets for some printers, filaments and some processes (TYPE_PRINT).
`PresetCollection prints`\
`PresetCollection filaments`\
`PrinterPresetCollection printers`
each one of these contains a collection of processes, filaments and printers respectively.\
> [!IMPORTANT]
> Printers, filaments and processes in the bundle don't all have to be compatible with each other. In fact all the saved presets are stored in one `PresetBundle`. The `PresetBundle` is loaded on start up. The list of filaments and processes shown for a particular printer is a subset of `filaments` and `prints` `PresetCollection`s.
## [`PresetCollection`](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/src/libslic3r/Preset.hpp)
`PrinterPresetCollection` is a class derived from `PresetCollection`.
These contain a collection of presets. The presets could be of any type.\
functions of note here are:
`get_edited_preset()`: returns the current selected preset along with any modifications the user has made.\
`get_selected_preset()`: returns the current selected preset without the modifications the user has made.

View File

@@ -1,28 +0,0 @@
# Application Structure Overview
WIP...
> [!WARNING]
> !! incomplete, possibly inaccurate, being updated with new info !!
## [`Plater`](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/src/slic3r/GUI/Plater.hpp)
Refers to the entire application. The whole view, file loading, project saving and loading is all managed by this class. This class contains members for the model viewer, the sidebar, gcode viewer and everything else.
## [`Sidebar`](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/src/slic3r/GUI/Plater.hpp)
This is relating the the sidebar in the application window
![full-sidebar](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/GUI/full-sidebar.png?raw=true)
## [`ComboBox`](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/src/slic3r/GUI/Widgets/ComboBox.hpp)
The drop down menus where you can see and select presets
![combobox](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/GUI/combobox.png?raw=true)
## [`Tab`](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/src/slic3r/GUI/Tab.hpp)
Refers to the various windows with settings. e.g. the Popup to edit printer or filament preset. Also the section to edit process preset and the object list. These 4 are managed by `TabPrinter`, `TabFilament`, `TabPrint` and `TabPrintModel` respectively.
![tab-popup](https://github.com/OrcaSlicer/OrcaSlicer/blob/main/doc/images/GUI/tab-popup.png?raw=true)

View File

@@ -1,44 +0,0 @@
## Slicing Call Hierarchy
The Slicing logic is not the easiest to locate in the code base. Below is a flow diagram of function calls that are made after clicking the `Slice Plate` button in the UI. Most of the processing happens in different threads. Note the calls after `BackgroundSlicingProcess::start()`, but this is how you can find the slicing logic.
```mermaid
flowchart TD
A["Slice plate"] --> B["void Plater::priv::on_action_slice_plate(SimpleEvent&)"]
B --> C["void Plater::reslice()"]
C --> D["bool Plater::priv::restart_background_process(unsigned int state)"]
D --> E["bool BackgroundSlicingProcess::start()"]
E --> F["void BackgroundSlicingProcess::thread_proc_safe_seh_throw()"]
F --> G["unsigned long BackgroundSlicingProcess::thread_proc_safe_seh()"]
G --> H["void BackgroundSlicingProcess::thread_proc_safe()"]
H --> I["void BackgroundSlicingProcess::thread_proc()"]
I --> J["void BackgroundSlicingProcess::call_process_seh_throw(std::exception_ptr &ex)"]
J --> K["unsigned long BackgroundSlicingProcess::call_process_seh(std::exception_ptr &ex)"]
K --> L["void BackgroundSlicingProcess::call_process(std::exception_ptr &ex)"]
L --> M["void BackgroundSlicingProcess::process_fff()"]
M --> N["void Print::process(long long *time_cost_with_cache, bool use_cache)"]
N --> O["void PrintObject::make_perimeters()"]
O --> P["void PrintObject::slice()"]
%% Labels for libraries
subgraph G1 [libSlic3r_gui]
B
C
D
E
F
G
H
I
J
K
L
M
end
subgraph G2 [libSlic3r]
N
O
P
end
```