Compare commits
14 Commits
v1.4.4
...
v1.0.10-sf
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2b59b6e974 | ||
|
|
8f594471c0 | ||
|
|
0977e3077f | ||
|
|
f087cd0db9 | ||
|
|
5e615feef5 | ||
|
|
5f1725246f | ||
|
|
829fc90e6f | ||
|
|
cc94674e39 | ||
|
|
f16521adf6 | ||
|
|
fc9d18faff | ||
|
|
ff768a6f68 | ||
|
|
9c0f6f1c72 | ||
|
|
7a7369c9ce | ||
|
|
687593f8d2 |
31
.github/ISSUE_TEMPLATE/bug_report.md
vendored
@@ -1,31 +0,0 @@
|
||||
---
|
||||
name: Bug report
|
||||
about: Create a report to help us improve
|
||||
title: ''
|
||||
labels: bug
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
**Describe the bug**
|
||||
A clear and concise description of what the bug is.
|
||||
|
||||
**3mf File for This Bug**
|
||||
If it is related to slicing, please append the 3mf file. It could be extremely helpful to solve the issue.
|
||||
|
||||
**To Reproduce**
|
||||
Steps to reproduce the behavior:
|
||||
1. Go to '...'
|
||||
2. Click on '....'
|
||||
3. Scroll down to '....'
|
||||
4. See error
|
||||
|
||||
**Expected behavior**
|
||||
A clear and concise description of what you expected to happen.
|
||||
|
||||
**Screenshots**
|
||||
If applicable, add screenshots to help explain your problem.
|
||||
|
||||
**Desktop (please complete the following information):**
|
||||
- OS: [e.g. iOS, Windows]
|
||||
- Version [e.g. 22]
|
||||
10
.github/ISSUE_TEMPLATE/custom.md
vendored
@@ -1,10 +0,0 @@
|
||||
---
|
||||
name: Custom issue template
|
||||
about: For generic ideas such as enhancement of a feature, some questions, and etc.
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
|
||||
20
.github/ISSUE_TEMPLATE/feature_request.md
vendored
@@ -1,20 +0,0 @@
|
||||
---
|
||||
name: Feature request
|
||||
about: Suggest an idea for this project
|
||||
title: ''
|
||||
labels: feature
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
**Is your feature request related to a problem? Please describe.**
|
||||
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
||||
|
||||
**Describe the solution you'd like**
|
||||
A clear and concise description of what you want to happen.
|
||||
|
||||
**Describe alternatives you've considered**
|
||||
A clear and concise description of any alternative solutions or features you've considered.
|
||||
|
||||
**Additional context**
|
||||
Add any other context or screenshots about the feature request here.
|
||||
44
.github/workflows/build_linux.yml
vendored
@@ -1,44 +0,0 @@
|
||||
name: Build Linux
|
||||
|
||||
on: [pull_request]
|
||||
|
||||
jobs:
|
||||
appimage-builder:
|
||||
name: Linux AppImage Build
|
||||
|
||||
runs-on: ubuntu-20.04
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install cmake libgl1-mesa-dev libgtk-3-dev libxkbcommon-dev libunwind-dev libfuse2 -y
|
||||
- name: Install dependencies from BuildLinux.sh
|
||||
shell: bash
|
||||
run: sudo ./BuildLinux.sh -ur
|
||||
- name: Fix permissions
|
||||
shell: bash
|
||||
run: sudo chown $USER -R ./
|
||||
- name: build deps
|
||||
id: cache_deps
|
||||
uses: actions/cache@v3
|
||||
env:
|
||||
cache-name: ${{ runner.os }}-cache-bambustudio_deps_x64
|
||||
with:
|
||||
path: ${{ github.workspace }}/deps/build/destdir
|
||||
key: build-${{ env.cache-name }}
|
||||
|
||||
- if: ${{ steps.cache_deps.outputs.cache-hit != 'true' }}
|
||||
name: build deps
|
||||
working-directory: ${{ github.workspace }}
|
||||
continue-on-error: true
|
||||
run: ./BuildLinux.sh -dr
|
||||
|
||||
- name: Build Studio
|
||||
shell: bash
|
||||
run: ./BuildLinux.sh -isr
|
||||
- uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: BambuStudio-SoftFever_Linux
|
||||
path: './build/BambuStudio_ubu64.AppImage'
|
||||
51
.github/workflows/build_mac_arm64.yml
vendored
@@ -1,51 +0,0 @@
|
||||
name: Build Mac arm64
|
||||
|
||||
on: [pull_request]
|
||||
|
||||
jobs:
|
||||
build_win64:
|
||||
name: Build Mac arm64
|
||||
runs-on: macos-12
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Install tools
|
||||
run: |
|
||||
brew install cmake git gettext zstd
|
||||
- run: mkdir -p ${{ github.workspace }}/deps/build
|
||||
# - run: mkdir -p ${{ github.workspace }}/deps/build/BambuStudio_dep
|
||||
|
||||
# - name: build deps
|
||||
# id: cache_deps
|
||||
# uses: actions/cache@v3
|
||||
# env:
|
||||
# cache-name: ${{ runner.os }}-cache-bambustudio_deps_arm64
|
||||
# with:
|
||||
# path: ${{ github.workspace }}/deps/build/BambuStudio_dep
|
||||
# key: build-${{ env.cache-name }}
|
||||
|
||||
# - if: ${{ steps.cache_deps.outputs.cache-hit != 'true' }}
|
||||
# name: build deps
|
||||
# working-directory: ${{ github.workspace }}
|
||||
# continue-on-error: true
|
||||
# run: ./build_release_macos.sh -d -a arm64
|
||||
- name: Download and extract deps
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: |
|
||||
curl -LJO https://github.com/SoftFever/FileSharing/releases/download/2/BambuStudio_dep_arm64_21-01-2023.tar.gz
|
||||
tar -zxvf BambuStudio_dep_arm64_21-01-2023.tar.gz -C ${{ github.workspace }}/deps/build
|
||||
chown -R $(id -u):$(id -g) ${{ github.workspace }}/deps/build/BambuStudio_dep
|
||||
ls -l ${{ github.workspace }}/deps/build/BambuStudio_dep
|
||||
rm BambuStudio_dep_arm64_21-01-2023.tar.gz
|
||||
|
||||
|
||||
- name: Build studio
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: ./build_release_macos.sh -s -n -a arm64
|
||||
|
||||
- name: Upload artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: BambuStudio-SoftFever_Mac
|
||||
path: ${{ github.workspace }}/build/BambuStudio-SoftFever/BambuStudio-SoftFever*.zip
|
||||
52
.github/workflows/build_mac_x64.yml
vendored
@@ -1,52 +0,0 @@
|
||||
name: Build Mac x64
|
||||
|
||||
on: [pull_request]
|
||||
|
||||
jobs:
|
||||
build_win64:
|
||||
name: Build Mac x64
|
||||
runs-on: macos-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Install tools
|
||||
run: |
|
||||
brew install cmake git gettext
|
||||
- run: mkdir -p ${{ github.workspace }}/deps/build
|
||||
- run: mkdir -p ${{ github.workspace }}/deps/build/BambuStudio_dep
|
||||
|
||||
# - name: build deps
|
||||
# id: cache_deps
|
||||
# uses: actions/cache@v3
|
||||
# env:
|
||||
# cache-name: ${{ runner.os }}-cache-bambustudio_deps_x64
|
||||
# with:
|
||||
# path: ${{ github.workspace }}/deps/build/BambuStudio_dep
|
||||
# key: build-${{ env.cache-name }}
|
||||
|
||||
# - if: ${{ steps.cache_deps.outputs.cache-hit != 'true' }}
|
||||
# name: build deps
|
||||
# working-directory: ${{ github.workspace }}
|
||||
# continue-on-error: true
|
||||
# run: ./build_release_macos.sh -d -a x86_64
|
||||
|
||||
- name: Download and extract deps
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: |
|
||||
curl -LJO https://github.com/SoftFever/FileSharing/releases/download/2/BambuStudio_dep_x86_64_21-01-2023.tar.gz
|
||||
tar -zxvf BambuStudio_dep_x86_64_21-01-2023.tar.gz -C ${{ github.workspace }}/deps/build
|
||||
chown -R $(id -u):$(id -g) ${{ github.workspace }}/deps/build/BambuStudio_dep
|
||||
ls -l ${{ github.workspace }}/deps/build/BambuStudio_dep
|
||||
rm BambuStudio_dep_x86_64_21-01-2023.tar.gz
|
||||
|
||||
|
||||
- name: Build studio
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: ./build_release_macos.sh -s -n -a x86_64
|
||||
|
||||
- name: Upload artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: BambuStudio-SoftFever_Mac
|
||||
path: ${{ github.workspace }}/build/BambuStudio-SoftFever/BambuStudio-SoftFever*.zip
|
||||
58
.github/workflows/build_win.yml
vendored
@@ -1,58 +0,0 @@
|
||||
name: Build Win64
|
||||
|
||||
on: [pull_request]
|
||||
|
||||
jobs:
|
||||
build_win64:
|
||||
name: Build Win64
|
||||
runs-on: windows-2019
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: ilammy/msvc-dev-cmd@v1
|
||||
- name: Install perl
|
||||
run: |
|
||||
choco install strawberryperl
|
||||
- run: mkdir ${{ github.workspace }}/deps/build
|
||||
- run: mkdir ${{ github.workspace }}/deps/build/BambuStudio_dep
|
||||
- name: download deps
|
||||
shell: powershell
|
||||
run: '(new-object System.Net.WebClient).DownloadFile("https://github.com/SoftFever/FileSharing/releases/download/2/BambuStudio_dep_21Jan2023.zip", "$env:temp\BambuStudio_dep_21Jan2023.zip")'
|
||||
- name: extract deps
|
||||
working-directory: ${{ github.workspace }}/deps/build
|
||||
shell: cmd
|
||||
run: '"C:/Program Files/7-Zip/7z.exe" x %temp%\BambuStudio_dep_21Jan2023.zip'
|
||||
|
||||
- run: dir "${{ github.workspace }}\deps\build\BambuStudio_dep"
|
||||
|
||||
# - name: build deps
|
||||
# id: cache_deps
|
||||
# uses: actions/cache@v3
|
||||
# env:
|
||||
# cache-name: ${{ runner.os }}-cache-bambustudio_deps
|
||||
# with:
|
||||
# path: ${{ github.workspace }}/deps/build/BambuStudio_dep
|
||||
# key: ${{ runner.os }}-build-${{ env.cache-name }}
|
||||
|
||||
# - if: ${{ steps.cache_deps.outputs.cache-hit != 'true' }}
|
||||
# name: build deps
|
||||
# working-directory: ${{ github.workspace }}
|
||||
# continue-on-error: true
|
||||
# run: .\build_release.bat deps
|
||||
|
||||
# - run: Get-ChildItem ${{ github.workspace }}/deps/build/ -Exclude BambuStudio_dep | Remove-Item -Recurse -Force
|
||||
|
||||
- name: Build studio
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: .\build_release.bat studio
|
||||
|
||||
- name: pack app
|
||||
working-directory: ${{ github.workspace }}/build
|
||||
shell: cmd
|
||||
run: '"C:/Program Files/7-Zip/7z.exe" a -tzip BambuStudio-SoftFever_dev_build.zip ${{ github.workspace }}/build/BambuStudio-SoftFever'
|
||||
|
||||
- name: Upload artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: BambuStudio-SoftFever_Win64
|
||||
path: ${{ github.workspace }}/build/BambuStudio-SoftFever_dev_build.zip
|
||||
260
BuildLinux.sh
@@ -1,260 +0,0 @@
|
||||
#!/bin/bash
|
||||
set -e # exit on first error
|
||||
|
||||
export ROOT=`pwd`
|
||||
export NCORES=`nproc --all`
|
||||
export CMAKE_BUILD_PARALLEL_LEVEL=${NCORES}
|
||||
FOUND_GTK2=$(dpkg -l libgtk* | grep gtk2)
|
||||
FOUND_GTK3=$(dpkg -l libgtk* | grep gtk-3)
|
||||
|
||||
function check_available_memory_and_disk() {
|
||||
FREE_MEM_GB=$(free -g -t | grep 'Mem:' | rev | cut -d" " -f1 | rev)
|
||||
MIN_MEM_GB=10
|
||||
|
||||
FREE_DISK_KB=$(df -k . | tail -1 | awk '{print $4}')
|
||||
MIN_DISK_KB=$((10 * 1024 * 1024))
|
||||
|
||||
if [ ${FREE_MEM_GB} -le ${MIN_MEM_GB} ]; then
|
||||
echo -e "\nERROR: Bambu Studio Builder requires at least ${MIN_MEM_GB}G of 'available' mem (systen has only ${FREE_MEM_GB}G available)"
|
||||
echo && free -h && echo
|
||||
exit 2
|
||||
fi
|
||||
|
||||
if [[ ${FREE_DISK_KB} -le ${MIN_DISK_KB} ]]; then
|
||||
echo -e "\nERROR: Bambu Studio Builder requires at least $(echo $MIN_DISK_KB |awk '{ printf "%.1fG\n", $1/1024/1024; }') (systen has only $(echo ${FREE_DISK_KB} | awk '{ printf "%.1fG\n", $1/1024/1024; }') disk free)"
|
||||
echo && df -h . && echo
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
unset name
|
||||
while getopts ":dsiuhgbr" opt; do
|
||||
case ${opt} in
|
||||
u )
|
||||
UPDATE_LIB="1"
|
||||
;;
|
||||
i )
|
||||
BUILD_IMAGE="1"
|
||||
;;
|
||||
d )
|
||||
BUILD_DEPS="1"
|
||||
;;
|
||||
s )
|
||||
BUILD_BAMBU_STUDIO="1"
|
||||
;;
|
||||
b )
|
||||
BUILD_DEBUG="1"
|
||||
;;
|
||||
g )
|
||||
FOUND_GTK3=""
|
||||
;;
|
||||
r )
|
||||
SKIP_RAM_CHECK="1"
|
||||
;;
|
||||
h ) echo "Usage: ./BuildLinux.sh [-i][-u][-d][-s][-b][-g]"
|
||||
echo " -i: Generate appimage (optional)"
|
||||
echo " -g: force gtk2 build"
|
||||
echo " -b: build in debug mode"
|
||||
echo " -d: build deps (optional)"
|
||||
echo " -s: build bambu-studio (optional)"
|
||||
echo " -u: only update clock & dependency packets (optional and need sudo)"
|
||||
echo " -r: skip free ram check (low ram compiling)"
|
||||
echo "For a first use, you want to 'sudo ./BuildLinux.sh -u'"
|
||||
echo " and then './BuildLinux.sh -dsi'"
|
||||
exit 0
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
if [ $OPTIND -eq 1 ]
|
||||
then
|
||||
echo "Usage: ./BuildLinux.sh [-i][-u][-d][-s][-b][-g]"
|
||||
echo " -i: Generate appimage (optional)"
|
||||
echo " -g: force gtk2 build"
|
||||
echo " -b: build in debug mode"
|
||||
echo " -d: build deps (optional)"
|
||||
echo " -s: build bambu-studio (optional)"
|
||||
echo " -u: only update clock & dependency packets (optional and need sudo)"
|
||||
echo " -r: skip free ram check (low ram compiling)"
|
||||
echo "For a first use, you want to 'sudo ./BuildLinux.sh -u'"
|
||||
echo " and then './BuildLinux.sh -dsi'"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# mkdir build
|
||||
if [ ! -d "build" ]
|
||||
then
|
||||
mkdir build
|
||||
fi
|
||||
|
||||
# Addtional Dev packages for BambuStudio
|
||||
export REQUIRED_DEV_PACKAGES="libmspack-dev libgstreamerd-3-dev libsecret-1-dev libwebkit2gtk-4.0-dev libosmesa6-dev libssl-dev libcurl4-openssl-dev eglexternalplatform-dev libudev-dev libdbus-1-dev extra-cmake-modules"
|
||||
# libwebkit2gtk-4.1-dev ??
|
||||
export DEV_PACKAGES_COUNT=$(echo ${REQUIRED_DEV_PACKAGES} | wc -w)
|
||||
if [ $(dpkg --get-selections | grep -E "$(echo ${REQUIRED_DEV_PACKAGES} | tr ' ' '|')" | wc -l) -lt ${DEV_PACKAGES_COUNT} ]; then
|
||||
sudo apt install -y ${REQUIRED_DEV_PACKAGES} git cmake wget file
|
||||
fi
|
||||
|
||||
#FIXME: require root for -u option
|
||||
if [[ -n "$UPDATE_LIB" ]]
|
||||
then
|
||||
echo -n -e "Updating linux ...\n"
|
||||
# hwclock -s # DeftDawg: Why does SuperSlicer want to do this?
|
||||
apt update
|
||||
if [[ -z "$FOUND_GTK3" ]]
|
||||
then
|
||||
echo -e "\nInstalling: libgtk2.0-dev libglew-dev libudev-dev libdbus-1-dev cmake git\n"
|
||||
apt install -y libgtk2.0-dev libglew-dev libudev-dev libdbus-1-dev cmake git
|
||||
else
|
||||
echo -e "\nFind libgtk-3, installing: libgtk-3-dev libglew-dev libudev-dev libdbus-1-dev cmake git\n"
|
||||
apt install -y libgtk-3-dev libglew-dev libudev-dev libdbus-1-dev cmake git
|
||||
fi
|
||||
# for ubuntu 22.04:
|
||||
ubu_version="$(cat /etc/issue)"
|
||||
if [[ $ubu_version == "Ubuntu 22.04"* ]]
|
||||
then
|
||||
apt install -y curl libssl-dev libcurl4-openssl-dev m4
|
||||
fi
|
||||
if [[ -n "$BUILD_DEBUG" ]]
|
||||
then
|
||||
echo -e "\nInstalling: libssl-dev libcurl4-openssl-dev\n"
|
||||
apt install -y libssl-dev libcurl4-openssl-dev
|
||||
fi
|
||||
echo -e "done\n"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
FOUND_GTK2_DEV=$(dpkg -l libgtk* | grep gtk2.0-dev || echo '')
|
||||
FOUND_GTK3_DEV=$(dpkg -l libgtk* | grep gtk-3-dev || echo '')
|
||||
echo "FOUND_GTK2=$FOUND_GTK2)"
|
||||
if [[ -z "$FOUND_GTK2_DEV" ]]
|
||||
then
|
||||
if [[ -z "$FOUND_GTK3_DEV" ]]
|
||||
then
|
||||
echo "Error, you must install the dependencies before."
|
||||
echo "Use option -u with sudo"
|
||||
exit 0
|
||||
fi
|
||||
fi
|
||||
|
||||
echo "[1/9] Updating submodules..."
|
||||
{
|
||||
# update submodule profiles
|
||||
pushd resources/profiles
|
||||
git submodule update --init
|
||||
popd
|
||||
}
|
||||
|
||||
echo "[2/9] Changing date in version..."
|
||||
{
|
||||
# change date in version
|
||||
sed -i "s/+UNKNOWN/_$(date '+%F')/" version.inc
|
||||
}
|
||||
echo "done"
|
||||
|
||||
# mkdir in deps
|
||||
if [ ! -d "deps/build" ]
|
||||
then
|
||||
mkdir deps/build
|
||||
fi
|
||||
|
||||
if ! [[ -n "$SKIP_RAM_CHECK" ]]
|
||||
then
|
||||
check_available_memory_and_disk
|
||||
fi
|
||||
|
||||
if [[ -n "$BUILD_DEPS" ]]
|
||||
then
|
||||
echo "[3/9] Configuring dependencies..."
|
||||
BUILD_ARGS=""
|
||||
if [[ -n "$FOUND_GTK3_DEV" ]]
|
||||
then
|
||||
BUILD_ARGS="-DDEP_WX_GTK3=ON"
|
||||
fi
|
||||
if [[ -n "$BUILD_DEBUG" ]]
|
||||
then
|
||||
# have to build deps with debug & release or the cmake won't find evrything it needs
|
||||
mkdir deps/build/release
|
||||
pushd deps/build/release
|
||||
cmake ../.. -DDESTDIR="../destdir" $BUILD_ARGS
|
||||
make -j$NCORES
|
||||
popd
|
||||
BUILD_ARGS="${BUILD_ARGS} -DCMAKE_BUILD_TYPE=Debug"
|
||||
fi
|
||||
|
||||
# cmake deps
|
||||
pushd deps/build
|
||||
cmake .. $BUILD_ARGS
|
||||
echo "done"
|
||||
|
||||
# make deps
|
||||
echo "[4/9] Building dependencies..."
|
||||
make -j$NCORES
|
||||
echo "done"
|
||||
|
||||
# rename wxscintilla # TODO: DeftDawg: Does BambuStudio need this?
|
||||
# echo "[5/9] Renaming wxscintilla library..."
|
||||
# pushd destdir/usr/local/lib
|
||||
# if [[ -z "$FOUND_GTK3_DEV" ]]
|
||||
# then
|
||||
# cp libwxscintilla-3.1.a libwx_gtk2u_scintilla-3.1.a
|
||||
# else
|
||||
# cp libwxscintilla-3.1.a libwx_gtk3u_scintilla-3.1.a
|
||||
# fi
|
||||
# popd
|
||||
# echo "done"
|
||||
|
||||
# FIXME: only clean deps if compiling succeeds; otherwise reruns waste tonnes of time!
|
||||
# clean deps
|
||||
# echo "[6/9] Cleaning dependencies..."
|
||||
# rm -rf dep_*
|
||||
popd
|
||||
echo "done"
|
||||
fi
|
||||
|
||||
if [[ -n "$BUILD_BAMBU_STUDIO" ]]
|
||||
then
|
||||
echo "[7/9] Configuring Slic3r..."
|
||||
BUILD_ARGS=""
|
||||
if [[ -n "$FOUND_GTK3_DEV" ]]
|
||||
then
|
||||
BUILD_ARGS="-DSLIC3R_GTK=3"
|
||||
fi
|
||||
if [[ -n "$BUILD_DEBUG" ]]
|
||||
then
|
||||
BUILD_ARGS="${BUILD_ARGS} -DCMAKE_BUILD_TYPE=Debug"
|
||||
else
|
||||
BUILD_ARGS="${BUILD_ARGS} -DBBL_RELEASE_TO_PUBLIC=1"
|
||||
fi
|
||||
|
||||
# cmake
|
||||
pushd build
|
||||
cmake .. -DCMAKE_PREFIX_PATH="$PWD/../deps/build/destdir/usr/local" -DSLIC3R_STATIC=1 ${BUILD_ARGS}
|
||||
echo "done"
|
||||
|
||||
# make Slic3r
|
||||
echo "[8/9] Building Slic3r..."
|
||||
make -j$NCORES BambuStudio # Slic3r
|
||||
|
||||
# make .mo
|
||||
# make gettext_po_to_mo # FIXME: DeftDawg: complains about msgfmt not existing even in SuperSlicer, did this ever work?
|
||||
|
||||
popd
|
||||
echo "done"
|
||||
fi
|
||||
|
||||
if [[ -e $ROOT/build/src/BuildLinuxImage.sh ]]; then
|
||||
# Give proper permissions to script
|
||||
chmod 755 $ROOT/build/src/BuildLinuxImage.sh
|
||||
|
||||
echo "[9/9] Generating Linux app..."
|
||||
pushd build
|
||||
if [[ -n "$BUILD_IMAGE" ]]
|
||||
then
|
||||
$ROOT/build/src/BuildLinuxImage.sh -i
|
||||
else
|
||||
$ROOT/build/src/BuildLinuxImage.sh
|
||||
fi
|
||||
popd
|
||||
echo "done"
|
||||
fi
|
||||
@@ -53,7 +53,6 @@ if (APPLE)
|
||||
if (CMAKE_MACOSX_BUNDLE)
|
||||
set(CMAKE_INSTALL_RPATH @executable_path/../Frameworks)
|
||||
endif()
|
||||
set(CMAKE_OSX_DEPLOYMENT_TARGET "11.3" CACHE STRING "Minimum OS X deployment version" FORCE)
|
||||
endif ()
|
||||
|
||||
# Proposal for C++ unit tests and sandboxes
|
||||
@@ -484,7 +483,16 @@ if (SLIC3R_STATIC AND NOT SLIC3R_STATIC_EXCLUDE_GLEW)
|
||||
set(GLEW_VERBOSE ON)
|
||||
endif()
|
||||
|
||||
find_package(GLEW REQUIRED)
|
||||
find_package(GLEW)
|
||||
if (NOT TARGET GLEW::GLEW)
|
||||
message(STATUS "GLEW not found, using bundled version.")
|
||||
add_library(glew STATIC ${LIBDIR}/glew/src/glew.c)
|
||||
set(GLEW_FOUND TRUE)
|
||||
set(GLEW_INCLUDE_DIRS ${LIBDIR}/glew/include/)
|
||||
target_compile_definitions(glew PUBLIC GLEW_STATIC)
|
||||
target_include_directories(glew PUBLIC ${GLEW_INCLUDE_DIRS})
|
||||
add_library(GLEW::GLEW ALIAS glew)
|
||||
endif ()
|
||||
|
||||
find_package(glfw3 REQUIRED)
|
||||
|
||||
@@ -498,7 +506,6 @@ add_custom_target(gettext_make_pot
|
||||
COMMAND xgettext --keyword=L --keyword=_L --keyword=_u8L --keyword=L_CONTEXT:1,2c --keyword=_L_PLURAL:1,2 --add-comments=TRN --from-code=UTF-8 --no-location --debug --boost
|
||||
-f "${BBL_L18N_DIR}/list.txt"
|
||||
-o "${BBL_L18N_DIR}/BambuStudio.pot"
|
||||
COMMAND hintsToPot ${SLIC3R_RESOURCES_DIR} ${BBL_L18N_DIR}
|
||||
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
|
||||
COMMENT "Generate pot file from strings in the source tree"
|
||||
)
|
||||
@@ -605,7 +612,6 @@ function(bambustudio_copy_dlls target config postfix output_dlls)
|
||||
${CMAKE_PREFIX_PATH}/bin/occt/TKXCAF.dll
|
||||
${CMAKE_PREFIX_PATH}/bin/occt/TKXDESTEP.dll
|
||||
${CMAKE_PREFIX_PATH}/bin/occt/TKXSBase.dll
|
||||
${CMAKE_PREFIX_PATH}/bin/freetype.dll
|
||||
DESTINATION ${_out_dir})
|
||||
|
||||
set(${output_dlls}
|
||||
@@ -640,8 +646,6 @@ function(bambustudio_copy_dlls target config postfix output_dlls)
|
||||
${_out_dir}/TKXDESTEP.dll
|
||||
${_out_dir}/TKXSBase.dll
|
||||
|
||||
${_out_dir}/freetype.dll
|
||||
|
||||
PARENT_SCOPE
|
||||
)
|
||||
|
||||
@@ -652,8 +656,6 @@ endfunction()
|
||||
add_subdirectory(src)
|
||||
set_property(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} PROPERTY VS_STARTUP_PROJECT BambuStudio_app_gui)
|
||||
|
||||
add_dependencies(gettext_make_pot hintsToPot)
|
||||
|
||||
# Perl bindings, currently only used for the unit / integration tests of libslic3r.
|
||||
# Also runs the unit / integration tests.
|
||||
#FIXME Port the tests into C++ to finally get rid of the Perl!
|
||||
@@ -669,11 +671,6 @@ if(SLIC3R_BUILD_TESTS)
|
||||
add_subdirectory(tests)
|
||||
endif()
|
||||
|
||||
if (NOT WIN32 AND NOT APPLE)
|
||||
set(SLIC3R_APP_CMD "bambu-studio")
|
||||
configure_file(${LIBDIR}/platform/unix/build_appimage.sh.in ${CMAKE_CURRENT_BINARY_DIR}/build_appimage.sh @ONLY)
|
||||
endif()
|
||||
|
||||
option(BUILD_BBS_TEST_TOOLS "Build bbs test tools" OFF)
|
||||
if(BUILD_BBS_TEST_TOOLS)
|
||||
add_subdirectory(bbs_test_tools)
|
||||
@@ -695,6 +692,7 @@ elseif (SLIC3R_FHS)
|
||||
DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/icons/hicolor/${SIZE}x${SIZE}/apps RENAME BambuStudio.png
|
||||
)
|
||||
endforeach()
|
||||
install(DIRECTORY ${SLIC3R_RESOURCES_DIR}/udev/ DESTINATION lib/udev/rules.d)
|
||||
elseif (CMAKE_MACOSX_BUNDLE)
|
||||
install(DIRECTORY "${SLIC3R_RESOURCES_DIR}/" DESTINATION "${CMAKE_INSTALL_PREFIX}/BambuStudio.app/Contents/resources")
|
||||
else ()
|
||||
|
||||
@@ -1,71 +0,0 @@
|
||||
# Build Bambu Slicer in a container
|
||||
#
|
||||
# Build an AppImage using rootless Podman (refer to https://github.com/containers/podman/blob/main/docs/tutorials/rootless_tutorial.md):
|
||||
# rm -rf build; podman build . -t bambu-studio-builder && podman run --rm localhost/bambu-studio-builder /bin/bash -c 'tar -c $(find build | grep ubu64.AppImage | head -1)' | tar -xv
|
||||
#
|
||||
# Troubleshooting the build container:
|
||||
# podman run -it --name bambu-studio-builder localhost/bambu-studio-builder /bin/bash
|
||||
#
|
||||
# Debugging the resulting AppImage:
|
||||
# 1) Install `gdb`
|
||||
# 2) In a terminal in the same directory as the AppImage, start it with following:
|
||||
# echo -e "run\nbt\nquit" | gdb ./BambuStudio_ubu64.AppImage
|
||||
# 3) Find related issue using backtrace output for clues and add backtrace to it on github
|
||||
#
|
||||
# Docker alternative AppImage build syntax (use this if you can't install podman):
|
||||
# rm -rf build; docker build . --file Containerfile -t bambu-studio-builder; docker run --rm bambu-studio-builder /bin/bash -c 'tar -c $(find build | grep ubu64.AppImage | head -1)' | tar -xv
|
||||
#
|
||||
#
|
||||
# TODO: bind mount BambuStudio to inside the container instead of COPY to enable faster rebuilds during dev work.
|
||||
|
||||
FROM docker.io/ubuntu:20.04
|
||||
LABEL maintainer "DeftDawg <DeftDawg@gmail.com>"
|
||||
|
||||
# Disable interactive package configuration
|
||||
RUN apt-get update && \
|
||||
echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selections
|
||||
|
||||
# Add a deb-src
|
||||
RUN echo deb-src http://archive.ubuntu.com/ubuntu \
|
||||
$(cat /etc/*release | grep VERSION_CODENAME | cut -d= -f2) main universe>> /etc/apt/sources.list
|
||||
|
||||
RUN apt-get update && apt-get install -y \
|
||||
git \
|
||||
build-essential \
|
||||
autoconf pkgconf m4 \
|
||||
cmake extra-cmake-modules \
|
||||
libglu1-mesa-dev libglu1-mesa-dev \
|
||||
libwayland-dev libxkbcommon-dev wayland-protocols \
|
||||
eglexternalplatform-dev libglew-dev \
|
||||
libgtk-3-dev \
|
||||
libdbus-1-dev \
|
||||
libcairo2-dev \
|
||||
libgtk-3-dev libwebkit2gtk-4.0-dev \
|
||||
libsoup2.4-dev \
|
||||
libgstreamer1.0-dev libgstreamer-plugins-good1.0-dev libgstreamer-plugins-base1.0-dev libgstreamerd-3-dev \
|
||||
libmspack-dev \
|
||||
libosmesa6-dev \
|
||||
libssl-dev libcurl4-openssl-dev libsecret-1-dev \
|
||||
libudev-dev \
|
||||
curl \
|
||||
wget \
|
||||
file \
|
||||
sudo
|
||||
|
||||
COPY ./ BambuStudio
|
||||
|
||||
WORKDIR BambuStudio
|
||||
|
||||
# These can run together, but we run them seperate for podman caching
|
||||
# Update System dependencies
|
||||
RUN ./BuildLinux.sh -u
|
||||
|
||||
# Build dependencies in ./deps
|
||||
RUN ./BuildLinux.sh -d
|
||||
|
||||
# Build slic3r
|
||||
RUN ./BuildLinux.sh -s
|
||||
|
||||
# Build AppImage
|
||||
ENV container podman
|
||||
RUN ./BuildLinux.sh -i
|
||||
232
README.md
@@ -1,222 +1,26 @@
|
||||
|
||||
# Bambu Studio - SoftFever
|
||||
A modified version of Bambu Studio with many handy features.
|
||||
It's fully compatible with Bambulab X1/X1-C/P1P printers.
|
||||
It also supports Anycubic, Anker, Creality, Prusa MK3S, RatRig and Voron printers.
|
||||
You can download it here: https://github.com/SoftFever/BambuStudio-SoftFever/releases
|
||||
A modified version of Bambu Studio.
|
||||
It has following changes:
|
||||
|
||||
## BambuStudio SoftFever change notes:
|
||||
- Support third-party machines:
|
||||
- Voron 2.4
|
||||
- Voron Trident
|
||||
- Voron 0.1
|
||||
- Prusa MK3S
|
||||
- Export to to .gcode file.
|
||||
|
||||
### [V1.4.2 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.4.2):
|
||||
- Change the color theme :)
|
||||
- Fixed a crash issue when selecting vase mode on some machines
|
||||
- Port firmware retraction and Extra length on restart retraction feature from PrusaSlicer
|
||||
- Fine-tune calibration features
|
||||
1. Enforce max volumetric speed in PA line mode
|
||||
2. Ensure print speeds are consistent across all blocks in the flow-rate calibration process. This is to help users calibrate those challenging filaments(such as TPU) by minimizing the influence of printing speed - thanks @psiberfunk for his input on this
|
||||
- New printer models: thanks @erebus04 and @GP3D84
|
||||
1. Tronxy X5SA 400
|
||||
2. Artillery Sidewinder
|
||||
- QoL:
|
||||
1. Now allow exporting g-code for BBL printers
|
||||
2. Fixed a bug that printer connection info was removed after loading a 3mf project
|
||||
fixed an issue that user presets were not loaded when Auto sync user preset option was off in Preference.
|
||||
3.Germany language translation - thanks @hliebscher
|
||||
- Misc fixes:
|
||||
1. Exit calibration mode when a new model is added to the scene(creating a new project after calibration is recommended)
|
||||
2. Skip emitting M106 P2 command if the auxiliary fan is not enabled.
|
||||
3. Fix an issue that previously there was a z-fighting issue when bed models are used for 3rd party printers
|
||||
4. Fixed an issue that max volumetric speed was not correctly calculated if flow-rate was changed per object.
|
||||
5. CICD for Linux build - thanks @fang64
|
||||
Known issues:
|
||||
|
||||
The Calibration menu is missing on some Mac machines. Try restarting the App can usually fix it. See [#120](https://github.com/SoftFever/BambuStudio-SoftFever/issues/120)
|
||||
|
||||
### [V1.4.1 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.4.1):
|
||||
- Added a feature for checking and displaying a notification for a new version
|
||||
- Added RatRig printer profiles, thanks @erebus04 for working this
|
||||
- Added support for the Creality CR-10 Max and Anker M5 printers.
|
||||
- Fixed the issue with profile cloud syncing for third-party printers.
|
||||
- set inner_wall_acceleration to 5000 for Bambu printers
|
||||
- Added support for the first_layer_bed_temperature and first_layer_temperature variables for better compatibility."
|
||||
- Fixed a crashing bug when adding text Mac Intel machine
|
||||
- QoL improvements for naming logic:
|
||||
1. The filename format is now supported when exporting 3mf files.
|
||||
2. If the project is not defined, the model name will be used as the output name.
|
||||
3. The "Untitled" string will no longer be added if the project name is set.
|
||||
4. The "_plate_0" string has been removed from the file name if there is only one plate.
|
||||
|
||||
<details>
|
||||
<summary> 👉 "Click here" for OLD Release Note</summary>
|
||||
|
||||
### [V1.4.0 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.4.0):
|
||||
- Add Layer Time/Layer time(Log) display (NOTE: need more tweaking work for BBL printers as the layer time is skewed by the preparing time)
|
||||
- Add `sandwich`(inner-outer-inner-infill) mode support for Arachne engine.
|
||||
- Change default `wall loop` from 2 to 3
|
||||
- Fix an issue that the last used printer was not remembered after application restart. (Thanks Bambulab engineers, for the quick response and fixing)
|
||||
- Optimized layer height sanity check logic. It will check against `max_layer_height` in the printer settings now. (I can use CHT 1.8 nozzle to print 1.0 mm thick layers now ;) )
|
||||
- Add Prusa MINI+ profile
|
||||
- expose `bed_exclude_area` parameter to 3rd printers
|
||||
- Fix some 3rd party printer related issues introduced in [BambuStudio v01.04.00.17](https://github.com/bambulab/BambuStudio/releases/tag/v01.04.00.17)
|
||||
1. Can't send sliced files to printers
|
||||
2. AMS filaments were added to non-Bambulab printers
|
||||
3. Wrong bed setting was applied
|
||||
|
||||
### [V1.3.4 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.3.4):
|
||||
1. Add a new printer order - sandwich mode:
|
||||
This new order is similar to the outer-wall-first mode in achieving the best dimensional accuracy. This new approach however avoids printing outer walls right after a long travel, which may cause artifacts on the surface in many cases.
|
||||
sandwich-mode1
|
||||
sandwich-mode2
|
||||
2. Support RRF firmware(experimental)
|
||||
3. Fix a compatibility issue for gcode-preview
|
||||
4. Merge upstream changes
|
||||
|
||||
### [V1.3.3 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.3.3):
|
||||
1. Improve top surface quality.
|
||||
Fix a bug that internal solid infills didn't use monotonic when top surface is using monotonic lines
|
||||
2. New feature: filter out tiny gaps.
|
||||
Note: for aesthetic considerations, this setting won't affect top/bottom layers. In other words, gap fills that can be seen from outside won't be filtered out
|
||||
3. PA(pressure advance) now support multi-color printing. A new PA value from the selected filament profile will be applied whenever there is
|
||||
a filament/extruder change action. This change only affects multi-color printing.
|
||||
5. Users can now set float values of layer time in Filament->Cooling tab.
|
||||
6. Allow to set target bed temp to 0
|
||||
7. Fix a bug that layer number is not displayed correctly in klipper UIs
|
||||
8. Force using linear PA model when manual PA override is enabled for Bambu machines
|
||||
9. Remember the last used filament
|
||||
10. Skip checking BL network plugin for third-party printers.
|
||||
### [V1.3.2 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.3.2-sf):
|
||||
1. Support device control view for 3rd party printers
|
||||
2. Port `Small perimeters` feature from PrusaSlicer. I also add an extra option to adjust the small perimeter threshold
|
||||
You might want to reduce speed for small perimeter parts to prevent failures like bellow:
|
||||
3. Add fan speed preview mode
|
||||
4. Fix an issue that print time estimation is inaccurate when `Klipper` g-code style is used.
|
||||
### [V1.3.1 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.3.1-sf):
|
||||
1. Support change bed size and nozzle diameter
|
||||
2. Allow users to specify the bridge infill direction
|
||||
3. bridge_infill_direction1
|
||||
4. bridge_infill_direction2
|
||||
5. Change to ISO view angle for preview image
|
||||
6. Add an option to change Z Hop action: NormalLift/SpiralLift
|
||||
7. Optimise g-code generation for both Bambu printers and 3rd party printers
|
||||
8. Support Klipper Exclude Objects
|
||||
9. Better support for Moonraker's metadata.
|
||||
|
||||
### [V1.2.5.3 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.2.5.3-sf):
|
||||
1. Label objects to support Klipper Exclude Objects feature
|
||||
2. Allow users to change output file name format
|
||||
3. Fix a bug that pressure advance value was not saved in the profile
|
||||
4. Optimize non-Bambu printer profiles
|
||||
5. Remove M900 S0 which is not necessary.
|
||||
|
||||
### [V1.2.5 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.2.5-sf):
|
||||
1. Add options to adjust jerk for different line types
|
||||
2. Add an option to adjust acceleration for travel. Higher acceleration for travel and lower acceleration for the outer wall makes it possible to print faster and nicer.
|
||||
3. Add an option to manually override the Pressure Advance / Linear Advance for each filament.
|
||||
|
||||
### [V1.2.4 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.2.4-sf):
|
||||
1. Allow users to adjust accelerations for inner/outer walls separately.
|
||||
2. Allow users to adjust the bottom surface flow-rate
|
||||
3. Fix an issue that bed temperature for other layers is not set properly. This bug exists in the upstream as well. My PR here(bambulab#319)
|
||||
|
||||
### [V1.2 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.2-sf):
|
||||
1. Allow user to change machine limits
|
||||
2. Allow users to adjust the top surface flow-rate.
|
||||
3. Unlock some cool hidden features in BambuStudio.
|
||||
4. Fix an issue that the software connected to Bambulab's staging server by default. (Only Bambulab machines were affected)
|
||||
|
||||
### [V1.1 changes](https://github.com/SoftFever/BambuStudio-SoftFever/releases/tag/v1.1):
|
||||
1. Support third-party printers:
|
||||
- Voron 2.4
|
||||
- Voron Trident
|
||||
- Voron 0.1
|
||||
- Prusa MK3S
|
||||
2. Export to to .gcode file.
|
||||
3. Send gcode file to printer
|
||||
4. Support single wall mode on first layer
|
||||
5. Support Chamber temperature. This setting can be use in machine start G-Gcode
|
||||
6. Support thumbview for third-party printers
|
||||
</details>
|
||||
|
||||
Demo video: https://youtu.be/vSNE9iGj2II
|
||||
Video: https://youtu.be/zCc7mVwu2xQ
|
||||
|
||||
## NOTE:
|
||||
## 1. For Apple M1 users, please take a look at this [article](https://www.howtogeek.com/803598/app-is-damaged-and-cant-be-opened/ ) about how to run unsigned applications on your machine. Or better, you can build it from the source codes if you want:)
|
||||
Apple requires a subscription(costs 99$ yearly) for developers to sign their app. I don't do a lot of dev work on Mac, and this is a nonprofit open-source project, so I decided not to pay the money ;)
|
||||
|
||||
## 2. If you have troubles to run the build, you might need to install following runtimes:
|
||||
- [MicrosoftEdgeWebView2RuntimeInstallerX64](https://github.com/SoftFever/BambuStudio-SoftFever/releases/download/v1.0.10-sf2/MicrosoftEdgeWebView2RuntimeInstallerX64.exe)
|
||||
- [vcredist2019_x64](https://github.com/SoftFever/BambuStudio-SoftFever/releases/download/v1.0.10-sf2/vcredist2019_x64.exe)
|
||||
|
||||
## 3. BambuStudio use G2/G3 commands by default. You need to turn on ARC support in your printer's firmware use with this slicer.
|
||||
- For Voron and any Klipper based printers:
|
||||
You can enable gcode_arcs(G2/G3) support by adding following section into you printer.cfg file:
|
||||
```
|
||||
[gcode_arcs]
|
||||
resolution: 0.1
|
||||
|
||||
[gcode_macro m201]
|
||||
gcode:
|
||||
{% if 'X' in params or 'Y' in params %}
|
||||
{% set accel = (params.X|default(params.Y)|float,
|
||||
params.Y|default(params.X)|float)|min %}
|
||||
SET_VELOCITY_LIMIT ACCEL={accel} ACCEL_TO_DECEL={accel * 0.5}
|
||||
{% else %}
|
||||
SET_VELOCITY_LIMIT
|
||||
{% endif %}
|
||||
|
||||
[gcode_macro m203]
|
||||
gcode:
|
||||
{% if 'X' in params or 'Y' in params %}
|
||||
{% set speed = (params.X|default(params.Y)|float,
|
||||
params.Y|default(params.X)|float)|min %}
|
||||
SET_VELOCITY_LIMIT VELOCITY={speed}
|
||||
{% else %}
|
||||
SET_VELOCITY_LIMIT
|
||||
{% endif %}
|
||||
|
||||
[gcode_macro M205]
|
||||
gcode:
|
||||
{% if 'X' in params or 'Y' in params %}
|
||||
{% set corner_speed = (params.X|default(params.Y)|float,
|
||||
params.Y|default(params.X)|float)|min %}
|
||||
SET_VELOCITY_LIMIT SQUARE_CORNER_VELOCITY={corner_speed}
|
||||
{% else %}
|
||||
SET_VELOCITY_LIMIT
|
||||
{% endif %}
|
||||
|
||||
[gcode_macro M900]
|
||||
gcode:
|
||||
SET_PRESSURE_ADVANCE ADVANCE={params.K}
|
||||
|
||||
```
|
||||
|
||||
~~ It's also recommended to add followinging dummy macros to make Klipper happy ~~
|
||||
Update: latest Klipper has supported G17 command. Don't add following macro if you are running on latest Klipper.
|
||||
```
|
||||
# Make BambuStudio happy
|
||||
[gcode_macro G17]
|
||||
gcode:
|
||||
|
||||
```
|
||||
|
||||
- For Prusa MK3S:
|
||||
ARC movement are supported by default.
|
||||
|
||||
|
||||
# Gallery
|
||||

|
||||

|
||||

|
||||

|
||||

|
||||

|
||||

|
||||

|
||||

|
||||
|
||||

|
||||

|
||||

|
||||

|
||||

|
||||

|
||||
|
||||
Image credits:
|
||||
1. Voron 2.4 and Trident: vorondesign.com
|
||||
1. Voron 2.4: vorondesign.com
|
||||
2. Voron bed texture: VoronUsers/bryansj
|
||||
3. Voron 0.1: myself
|
||||
4. Prusa MK3S: Prusa3d
|
||||
|
||||
@@ -272,5 +76,5 @@ Slic3r is licensed under the GNU Affero General Public License, version 3. Slic3
|
||||
|
||||
The GNU Affero General Public License, version 3 ensures that if you use any part of this software in any way (even behind a web server), your software must be released under the same license.
|
||||
|
||||
The bambu networking plugin is based on non-free libraries. It is optional to the Bambu Studio and provides extended functionalities for users.
|
||||
The BambuNetworking and BambuTunnel plugins are based on non-free libraries. They are optional to the Bambu Studio and provides extended functionalities for users.
|
||||
|
||||
|
||||
|
Before Width: | Height: | Size: 98 KiB |
|
Before Width: | Height: | Size: 136 KiB |
|
Before Width: | Height: | Size: 41 KiB |
|
Before Width: | Height: | Size: 42 KiB |
|
Before Width: | Height: | Size: 76 KiB |
|
Before Width: | Height: | Size: 52 KiB |
|
Before Width: | Height: | Size: 68 KiB |
|
Before Width: | Height: | Size: 131 KiB |
|
Before Width: | Height: | Size: 126 KiB |
|
Before Width: | Height: | Size: 74 KiB |
|
Before Width: | Height: | Size: 211 KiB |
|
Before Width: | Height: | Size: 26 KiB |
|
Before Width: | Height: | Size: 75 KiB |
|
Before Width: | Height: | Size: 62 KiB |
|
Before Width: | Height: | Size: 729 KiB |
|
Before Width: | Height: | Size: 48 KiB |
|
Before Width: | Height: | Size: 83 KiB |
|
Before Width: | Height: | Size: 228 KiB |
|
Before Width: | Height: | Size: 214 KiB |
|
Before Width: | Height: | Size: 353 KiB |
|
Before Width: | Height: | Size: 217 KiB |
|
Before Width: | Height: | Size: 305 KiB |
|
Before Width: | Height: | Size: 158 KiB |
@@ -10,10 +10,7 @@ src/slic3r/GUI/Gizmos/GizmoObjectManipulation.cpp
|
||||
src/slic3r/GUI/Gizmos/GLGizmoAdvancedCut.cpp
|
||||
src/slic3r/GUI/Gizmos/GLGizmoSimplify.cpp
|
||||
src/slic3r/GUI/Gizmos/GLGizmoFaceDetector.cpp
|
||||
src/slic3r/GUI/Gizmos/GLGizmoSeam.cpp
|
||||
src/slic3r/GUI/Gizmos/GLGizmoSeam.hpp
|
||||
src/slic3r/GUI/Gizmos/GLGizmoText.cpp
|
||||
src/slic3r/GUI/Gizmos/GLGizmoText.hpp
|
||||
src/slic3r/GUI/Gizmos/GLGizmoModifier.cpp
|
||||
src/slic3r/GUI/GUI.cpp
|
||||
src/slic3r/GUI/GUI_App.cpp
|
||||
src/slic3r/GUI/GUI_Init.cpp
|
||||
@@ -25,8 +22,6 @@ src/slic3r/GUI/GUI_ObjectTable.hpp
|
||||
src/slic3r/GUI/GUI_ObjectTableSettings.cpp
|
||||
src/slic3r/GUI/GUI_ObjectTableSettings.hpp
|
||||
src/slic3r/GUI/GUI_Preview.cpp
|
||||
src/slic3r/GUI/HintNotification.cpp
|
||||
src/slic3r/GUI/IMSlider.cpp
|
||||
src/slic3r/GUI/Widgets/SideTools.cpp
|
||||
src/slic3r/GUI/Widgets/AMSControl.cpp
|
||||
src/slic3r/GUI/ImGuiWrapper.cpp
|
||||
@@ -38,16 +33,10 @@ src/slic3r/GUI/Jobs/PlaterJob.cpp
|
||||
src/slic3r/GUI/Jobs/RotoptimizeJob.cpp
|
||||
src/slic3r/GUI/Jobs/BindJob.cpp
|
||||
src/slic3r/GUI/Jobs/PrintJob.cpp
|
||||
src/slic3r/GUI/Jobs/SendJob.cpp
|
||||
src/slic3r/GUI/Jobs/UpgradeNetworkJob.cpp
|
||||
src/slic3r/GUI/AboutDialog.cpp
|
||||
src/slic3r/GUI/AMSMaterialsSetting.cpp
|
||||
src/slic3r/GUI/ExtrusionCalibration.cpp
|
||||
src/slic3r/GUI/AMSMappingPopup.cpp
|
||||
src/slic3r/GUI/AMSSetting.cpp
|
||||
src/slic3r/GUI/BBLTopbar.cpp
|
||||
src/slic3r/GUI/DownloadProgressDialog.cpp
|
||||
src/slic3r/GUI/RecenterDialog.cpp
|
||||
src/slic3r/GUI/BackgroundSlicingProcess.cpp
|
||||
src/slic3r/GUI/BedShapeDialog.cpp
|
||||
src/slic3r/GUI/BedShapeDialog.hpp
|
||||
@@ -60,12 +49,10 @@ src/slic3r/GUI/GLCanvas3D.cpp
|
||||
src/slic3r/GUI/Calibration.cpp
|
||||
src/slic3r/GUI/CameraPopup.cpp
|
||||
src/slic3r/GUI/ConnectPrinter.cpp
|
||||
src/slic3r/GUI/DebugToolDialog.cpp
|
||||
src/slic3r/GUI/HMSPanel.cpp
|
||||
src/slic3r/GUI/MainFrame.cpp
|
||||
src/slic3r/GUI/MediaPlayCtrl.cpp
|
||||
src/slic3r/GUI/MediaFilePanel.cpp
|
||||
src/slic3r/GUI/ImageGrid.cpp
|
||||
src/slic3r/GUI/Printer/PrinterFileSystem.cpp
|
||||
src/slic3r/GUI/Mouse3DController.cpp
|
||||
src/slic3r/GUI/StatusPanel.cpp
|
||||
src/slic3r/GUI/Monitor.cpp
|
||||
@@ -75,7 +62,6 @@ src/slic3r/GUI/NotificationManager.cpp
|
||||
src/slic3r/GUI/ObjectDataViewModel.cpp
|
||||
src/slic3r/GUI/OpenGLManager.cpp
|
||||
src/slic3r/GUI/OptionsGroup.cpp
|
||||
src/slic3r/GUI/PrintOptionsDialog.cpp
|
||||
src/slic3r/GUI/ParamsPanel.cpp
|
||||
src/slic3r/GUI/PartPlate.cpp
|
||||
src/slic3r/GUI/Plater.cpp
|
||||
@@ -89,8 +75,6 @@ src/slic3r/GUI/Search.cpp
|
||||
src/slic3r/GUI/Selection.cpp
|
||||
src/slic3r/GUI/SelectMachine.cpp
|
||||
src/slic3r/GUI/SendSystemInfoDialog.cpp
|
||||
src/slic3r/GUI/SendToPrinter.cpp
|
||||
src/slic3r/GUI/SetBedTypeDialog.cpp
|
||||
src/slic3r/GUI/BindDialog.cpp
|
||||
src/slic3r/GUI/Tab.cpp
|
||||
src/slic3r/GUI/Tab.hpp
|
||||
@@ -103,9 +87,6 @@ src/slic3r/GUI/WebUserLoginDialog.cpp
|
||||
src/slic3r/GUI/WebGuideDialog.cpp
|
||||
src/slic3r/GUI/KBShortcutsDialog.hpp
|
||||
src/slic3r/GUI/KBShortcutsDialog.cpp
|
||||
src/slic3r/GUI/ReleaseNote.cpp
|
||||
src/slic3r/GUI/ReleaseNote.hpp
|
||||
src/slic3r/GUI/UpgradePanel.cpp
|
||||
src/slic3r/Utils/FixModelByWin10.cpp
|
||||
src/slic3r/Utils/PresetUpdater.cpp
|
||||
src/slic3r/Utils/Http.cpp
|
||||
|
||||
@@ -2,12 +2,12 @@
|
||||
#include <fstream>
|
||||
#include <math.h>
|
||||
#include <map>
|
||||
#include <string.h>
|
||||
|
||||
namespace BambuStudio {
|
||||
|
||||
//BBS: only check wodth when dE is longer than this value
|
||||
const double CHECK_WIDTH_E_THRESHOLD = 0.0025;
|
||||
const double WIDTH_THRESHOLD = 0.02;
|
||||
const double WIDTH_THRESHOLD = 0.012;
|
||||
const double RADIUS_THRESHOLD = 0.005;
|
||||
|
||||
const double filament_diameter = 1.75;
|
||||
@@ -19,11 +19,6 @@ const std::string Wipe_Start_Tag = " WIPE_START";
|
||||
const std::string Wipe_End_Tag = " WIPE_END";
|
||||
const std::string Layer_Change_Tag = " CHANGE_LAYER";
|
||||
const std::string Height_Tag = " LAYER_HEIGHT: ";
|
||||
const std::string filament_flow_ratio_tag = " filament_flow_ratio";
|
||||
const std::string nozzle_temperature_Tag = " nozzle_temperature =";
|
||||
const std::string nozzle_temperature_initial_layer_Tag = " nozzle_temperature_initial_layer";
|
||||
const std::string Z_HEIGHT_TAG = " Z_HEIGHT: ";
|
||||
const std::string Initial_Layer_Ptint_Height_Tag = " initial_layer_print_height =";
|
||||
|
||||
GCodeCheckResult GCodeChecker::parse_file(const std::string& path)
|
||||
{
|
||||
@@ -110,19 +105,6 @@ GCodeCheckResult GCodeChecker::parse_comment(GCodeLine& line)
|
||||
// extrusion role tag
|
||||
if (starts_with(comment, Extrusion_Role_Tag)) {
|
||||
m_role = string_to_role(comment.substr(Extrusion_Role_Tag.length()));
|
||||
if (m_role == erExternalPerimeter) {
|
||||
|
||||
if (z_height == initial_layer_height && nozzle_temp != nozzle_temperature_initial_layer[filament_id]) {
|
||||
std::cout << "invalid filament nozzle initial layer temperature comment with invalid value!" << std::endl;
|
||||
return GCodeCheckResult::ParseFailed;
|
||||
}
|
||||
|
||||
if (z_height != initial_layer_height && nozzle_temp != nozzle_temperature[filament_id]) {
|
||||
std::cout << "invalid filament nozzle temperature comment with invalid value!" << std::endl;
|
||||
return GCodeCheckResult::ParseFailed;
|
||||
}
|
||||
}
|
||||
|
||||
} else if (starts_with(comment, Wipe_Start_Tag)) {
|
||||
m_wiping = true;
|
||||
} else if (starts_with(comment, Wipe_End_Tag)) {
|
||||
@@ -141,41 +123,7 @@ GCodeCheckResult GCodeChecker::parse_comment(GCodeLine& line)
|
||||
}
|
||||
} else if (starts_with(comment, Layer_Change_Tag)) {
|
||||
m_layer_num++;
|
||||
} else if (starts_with(comment, filament_flow_ratio_tag))
|
||||
{
|
||||
std::string str = comment.substr(filament_flow_ratio_tag.size()+3);
|
||||
if (!parse_double_from_str(str, filament_flow_ratio))
|
||||
{
|
||||
std::cout << "invalid filament flow ratio comment with invalid value!" << std::endl;
|
||||
return GCodeCheckResult::ParseFailed;
|
||||
}
|
||||
}
|
||||
else if (starts_with(comment, nozzle_temperature_Tag)) {
|
||||
std::string str = comment.substr(nozzle_temperature_Tag.size() + 1);
|
||||
if (!parse_double_from_str(str, nozzle_temperature)) {
|
||||
std::cout << "invalid nozzle temperature comment with invalid value!" << std::endl;
|
||||
return GCodeCheckResult::ParseFailed;
|
||||
}
|
||||
}
|
||||
else if (starts_with(comment, nozzle_temperature_initial_layer_Tag)) {
|
||||
std::string str = comment.substr(nozzle_temperature_initial_layer_Tag.size() + 3);
|
||||
if (!parse_double_from_str(str, nozzle_temperature_initial_layer)) {
|
||||
std::cout << "invalid nozzle temperature initial layer comment with invalid value!" << std::endl;
|
||||
return GCodeCheckResult::ParseFailed;
|
||||
}
|
||||
} else if (starts_with(comment, Z_HEIGHT_TAG)) {
|
||||
std::string str = comment.substr(Z_HEIGHT_TAG.size());
|
||||
if (!parse_double_from_str(str, z_height)) {
|
||||
std::cout << "invalid z height comment with invalid value!" << std::endl;
|
||||
return GCodeCheckResult::ParseFailed;
|
||||
}
|
||||
} else if (starts_with(comment, Initial_Layer_Ptint_Height_Tag)) {
|
||||
std::string str = comment.substr(Initial_Layer_Ptint_Height_Tag.size());
|
||||
if (!parse_double_from_str(str, initial_layer_height)) {
|
||||
std::cout << "invalid initial layer height comment with invalid value!" << std::endl;
|
||||
return GCodeCheckResult::ParseFailed;
|
||||
}
|
||||
}
|
||||
|
||||
return GCodeCheckResult::Success;
|
||||
}
|
||||
@@ -205,32 +153,11 @@ GCodeCheckResult GCodeChecker::parse_command(GCodeLine& gcode_line)
|
||||
{
|
||||
case 82: { ret = parse_M82(gcode_line); break; } // Set to Absolute extrusion
|
||||
case 83: { ret = parse_M83(gcode_line); break; } // Set to Relative extrusion
|
||||
case 104: {
|
||||
ret = parse_M104_M109(gcode_line);
|
||||
break;
|
||||
} // Set to nozzle temperature
|
||||
case 109: {
|
||||
ret = parse_M104_M109(gcode_line);
|
||||
break;
|
||||
} // Set to nozzle temperature
|
||||
default: { break; }
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 'T':{
|
||||
|
||||
int pt = ::atoi(&cmd[1]);
|
||||
if (pt == 1000 || pt == 1100 || pt == 255) {
|
||||
break;
|
||||
}
|
||||
|
||||
if (pt < 0 || pt > 254 || pt >= filament_flow_ratio.size()) {
|
||||
std::cout << "Invalid T command"<<std::endl;
|
||||
ret = GCodeCheckResult::ParseFailed;
|
||||
break;
|
||||
}
|
||||
filament_id = pt;
|
||||
flow_ratio = filament_flow_ratio[pt];
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
@@ -262,7 +189,6 @@ GCodeCheckResult GCodeChecker::parse_axis(GCodeLine& gcode_line)
|
||||
case 'F': axis = F; break;
|
||||
case 'I': axis = I; break;
|
||||
case 'J': axis = J; break;
|
||||
case 'P': axis = P; break;
|
||||
default:
|
||||
//BBS: invalid command which has invalid axis
|
||||
std::cout << "Invalid gcode because of invalid axis!" << std::endl;
|
||||
@@ -340,7 +266,8 @@ GCodeCheckResult GCodeChecker::parse_G2_G3(GCodeLine& gcode_line)
|
||||
return GCodeCheckResult::ParseFailed;
|
||||
}
|
||||
//BBS: invalid G2_G3 command which has no X and Y axis at same time
|
||||
if (!gcode_line.has(X) && !gcode_line.has(Y) && !gcode_line.has(I) && !gcode_line.has(J)) {
|
||||
if (!gcode_line.has(X) &&
|
||||
!gcode_line.has(Y)) {
|
||||
if (!gcode_line.has(X) || !gcode_line.has(P) || (int)gcode_line.get(P) != 1) {
|
||||
std::cout << "Invalid G2_G3 gcode because of no X and Y axis at same time!" << std::endl;
|
||||
return GCodeCheckResult::ParseFailed;
|
||||
@@ -431,30 +358,11 @@ GCodeCheckResult GCodeChecker::parse_M83(const GCodeLine& gcode_line)
|
||||
return GCodeCheckResult::Success;
|
||||
}
|
||||
|
||||
GCodeCheckResult GCodeChecker::parse_M104_M109(const GCodeLine &gcode_line)
|
||||
{
|
||||
const char *c = gcode_line.m_raw.c_str();
|
||||
const char *rs = strchr(c,'S');
|
||||
|
||||
std::string str=rs;
|
||||
str = str.substr(1);
|
||||
for (int i = 0; i < str.size(); i++) {
|
||||
if (str[i] == ' ')
|
||||
str=str.substr(0,i);
|
||||
}
|
||||
if (!parse_double_from_str(str, nozzle_temp)) {
|
||||
std::cout << "invalid nozzle temperature comment with invalid value!" << std::endl;
|
||||
return GCodeCheckResult::ParseFailed;
|
||||
}
|
||||
|
||||
return GCodeCheckResult::Success;
|
||||
}
|
||||
|
||||
double GCodeChecker::calculate_G1_width(const std::array<double, 3>& source,
|
||||
const std::array<double, 3>& target,
|
||||
double e, double height, bool is_bridge) const
|
||||
{
|
||||
double volume = (e / flow_ratio) * Pi * (filament_diameter / 2.0f) * (filament_diameter / 2.0f);
|
||||
double volume = e * Pi * (filament_diameter/2.0f) * (filament_diameter/2.0f);
|
||||
std::array<double, 3> delta = { target[0] - source[0],
|
||||
target[1] - source[1],
|
||||
target[2] - source[2] };
|
||||
@@ -481,9 +389,8 @@ double GCodeChecker::calculate_G2_G3_width(const std::array<double, 2>& source,
|
||||
(radian < 0 ? -radian : 2 * Pi - radian);
|
||||
double radius = sqrt(v1[0] * v1[0] + v1[1] * v1[1]);
|
||||
double length = radius * radian;
|
||||
double volume = (e / flow_ratio) * Pi * (filament_diameter / 2) * (filament_diameter / 2);
|
||||
double volume = e * Pi * (filament_diameter/2) * (filament_diameter/2);
|
||||
double mm3_per_mm = volume / length;
|
||||
|
||||
return is_bridge? 2 * sqrt(mm3_per_mm/Pi) :
|
||||
(mm3_per_mm / height) + height * (1 - 0.25 * Pi);
|
||||
}
|
||||
@@ -574,15 +481,12 @@ GCodeCheckResult GCodeChecker::check_G0_G1_width(const GCodeLine& line)
|
||||
std::array<double, 3> target = { m_end_position[X], m_end_position[Y], m_end_position[Z] };
|
||||
|
||||
bool is_bridge = m_role == erOverhangPerimeter || m_role == erBridgeInfill;
|
||||
if (!is_bridge) {
|
||||
double width_real = calculate_G1_width(source, target, delta_pos[E], m_height, is_bridge);
|
||||
if (fabs(width_real - m_width) > WIDTH_THRESHOLD) {
|
||||
std::cout << "Invalid G0_G1 because has abnormal line width." << std::endl;
|
||||
std::cout << "Width: " << m_width << " Width_real: " << width_real << std::endl;
|
||||
return GCodeCheckResult::CheckFailed;
|
||||
}
|
||||
double width_real = calculate_G1_width(source, target, delta_pos[E], m_height, is_bridge);
|
||||
if (fabs(width_real - m_width) > WIDTH_THRESHOLD) {
|
||||
std::cout << "Invalid G0_G1 because has abnormal line width." << std::endl;
|
||||
std::cout << "Width: " << m_width << " Width_real: " << width_real << std::endl;
|
||||
return GCodeCheckResult::CheckFailed;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return GCodeCheckResult::Success;
|
||||
@@ -652,16 +556,12 @@ GCodeCheckResult GCodeChecker::check_G2_G3_width(const GCodeLine& line)
|
||||
m_role != erGapFill &&
|
||||
delta_e > CHECK_WIDTH_E_THRESHOLD) {
|
||||
bool is_bridge = m_role == erOverhangPerimeter || m_role == erBridgeInfill;
|
||||
|
||||
if (!is_bridge) {
|
||||
double width_real = calculate_G2_G3_width(source, target, center, is_ccw, delta_e, m_height, is_bridge);
|
||||
if (fabs(width_real - m_width) > WIDTH_THRESHOLD) {
|
||||
std::cout << "Invalid G2_G3 because has abnormal line width." << std::endl;
|
||||
std::cout << "Width: " << m_width << " Width_real: " << width_real << std::endl;
|
||||
return GCodeCheckResult::CheckFailed;
|
||||
}
|
||||
double width_real = calculate_G2_G3_width(source, target, center, is_ccw, delta_e, m_height, is_bridge);
|
||||
if (fabs(width_real - m_width) > WIDTH_THRESHOLD) {
|
||||
std::cout << "Invalid G2_G3 because has abnormal line width." << std::endl;
|
||||
std::cout << "Width: " << m_width << " Width_real: " << width_real << std::endl;
|
||||
return GCodeCheckResult::CheckFailed;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return GCodeCheckResult::Success;
|
||||
|
||||
@@ -108,7 +108,6 @@ private:
|
||||
GCodeCheckResult parse_G92(GCodeLine& gcode_line);
|
||||
GCodeCheckResult parse_M82(const GCodeLine& gcode_line);
|
||||
GCodeCheckResult parse_M83(const GCodeLine& gcode_line);
|
||||
GCodeCheckResult parse_M104_M109(const GCodeLine &gcode_line);
|
||||
|
||||
GCodeCheckResult parse_comment(GCodeLine& gcode_line);
|
||||
|
||||
@@ -161,38 +160,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
static bool parse_double_from_str(const std::string &input, std::vector<double> &out)
|
||||
{
|
||||
|
||||
std::string cmd=input;
|
||||
size_t read = 0;
|
||||
|
||||
while (cmd.size() >= 5)
|
||||
{
|
||||
int pt = 0;
|
||||
for (pt = 0; pt < cmd.size(); pt++) {
|
||||
char temp = cmd[pt];
|
||||
if (temp == ',')
|
||||
{
|
||||
try {
|
||||
double num = std::stod(cmd.substr(0, pt), &read);
|
||||
|
||||
out.push_back(num);
|
||||
cmd = cmd.substr(pt+1);
|
||||
break;
|
||||
} catch (...) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
double num = std::stod(cmd, &read);
|
||||
out.push_back(num);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
private:
|
||||
EPositioningType m_global_positioning_type = EPositioningType::Absolute;
|
||||
EPositioningType m_e_local_positioning_type = EPositioningType::Absolute;
|
||||
@@ -207,14 +174,6 @@ private:
|
||||
int m_layer_num = 0;
|
||||
double m_height = 0.0;
|
||||
double m_width = 0.0;
|
||||
double z_height=0.0f;
|
||||
double initial_layer_height=0.0f;
|
||||
int filament_id;
|
||||
double flow_ratio = 0;
|
||||
double nozzle_temp = 0.0f;
|
||||
std::vector<double> filament_flow_ratio;
|
||||
std::vector<double> nozzle_temperature;
|
||||
std::vector<double> nozzle_temperature_initial_layer;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
@@ -3,21 +3,12 @@ cd deps
|
||||
mkdir build
|
||||
cd build
|
||||
set DEPS=%CD%/BambuStudio_dep
|
||||
if "%1"=="studio" (
|
||||
GOTO :studio
|
||||
)
|
||||
echo "building deps.."
|
||||
cmake ../ -G "Visual Studio 16 2019" -DDESTDIR="%CD%/BambuStudio_dep" -DCMAKE_BUILD_TYPE=Release
|
||||
cmake --build . --config Release --target ALL_BUILD -- -m
|
||||
|
||||
if "%1"=="deps" exit /b 0
|
||||
|
||||
:studio
|
||||
echo "building studio..."
|
||||
cd %WP%
|
||||
mkdir build
|
||||
cd build
|
||||
|
||||
cmake .. -G "Visual Studio 16 2019" -DBBL_RELEASE_TO_PUBLIC=1 -DCMAKE_PREFIX_PATH="%DEPS%/usr/local" -DCMAKE_INSTALL_PREFIX="./BambuStudio-SoftFever" -DCMAKE_BUILD_TYPE=Release -DWIN10SDK_PATH="C:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0"
|
||||
cmake .. -G "Visual Studio 16 2019" -DBBL_RELEASE_TO_PUBLIC=0 -DCMAKE_PREFIX_PATH="%DEPS%/usr/local" -DCMAKE_INSTALL_PREFIX="./BambuStudio-SoftFever" -DCMAKE_BUILD_TYPE=Release -DWIN10SDK_PATH="C:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0"
|
||||
cmake --build . --config Release --target ALL_BUILD -- -m
|
||||
cmake --build . --target install --config Release
|
||||
@@ -1,85 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
while getopts ":a:sdhn" opt; do
|
||||
case ${opt} in
|
||||
d )
|
||||
export BUILD_TARGET="deps"
|
||||
;;
|
||||
a )
|
||||
export ARCH="$OPTARG"
|
||||
;;
|
||||
s )
|
||||
export BUILD_TARGET="studio"
|
||||
;;
|
||||
n )
|
||||
export NIGHTLY_BUILD="1"
|
||||
;;
|
||||
h ) echo "Usage: ./build_release_macos.sh [-d]"
|
||||
echo " -d: Build deps only"
|
||||
echo " -a: Set ARCHITECTURE (arm64 or x86_64)"
|
||||
echo " -s: Build studio only"
|
||||
echo " -n: Nightly build"
|
||||
exit 0
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
if [ -z "$ARCH" ]
|
||||
then
|
||||
export ARCH=$(uname -m)
|
||||
fi
|
||||
|
||||
echo "Arch: $ARCH"
|
||||
echo "BUILD_TARGET: $BUILD_TARGET"
|
||||
|
||||
brew --prefix libiconv
|
||||
brew --prefix zstd
|
||||
export LIBRARY_PATH=$LIBRARY_PATH:$(brew --prefix zstd)/lib/
|
||||
|
||||
WD="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
cd $WD/deps
|
||||
mkdir -p build
|
||||
cd build
|
||||
DEPS=$PWD/BambuStudio_dep
|
||||
mkdir -p $DEPS
|
||||
if [ "studio." != $BUILD_TARGET. ];
|
||||
then
|
||||
echo "building deps..."
|
||||
echo "cmake ../ -DDESTDIR=$DEPS -DOPENSSL_ARCH=darwin64-${ARCH}-cc -DCMAKE_BUILD_TYPE=Release -DCMAKE_OSX_ARCHITECTURES:STRING=${ARCH}"
|
||||
cmake ../ -DDESTDIR="$DEPS" -DOPENSSL_ARCH="darwin64-${ARCH}-cc" -DCMAKE_BUILD_TYPE=Release -DCMAKE_OSX_ARCHITECTURES:STRING=${ARCH}
|
||||
cmake --build . --config Release --target all
|
||||
fi
|
||||
|
||||
|
||||
if [ "deps." == "$BUILD_TARGET". ];
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
cd $WD
|
||||
mkdir -p build
|
||||
cd build
|
||||
echo "building studio..."
|
||||
cmake .. -GXcode -DBBL_RELEASE_TO_PUBLIC=1 -DCMAKE_PREFIX_PATH="$DEPS/usr/local" -DCMAKE_INSTALL_PREFIX="$PWD/BambuStudio-SoftFever" -DCMAKE_BUILD_TYPE=Release -DCMAKE_MACOSX_RPATH=ON -DCMAKE_INSTALL_RPATH="$DEPS/usr/local" -DCMAKE_MACOSX_BUNDLE=ON -DCMAKE_OSX_ARCHITECTURES=${ARCH}
|
||||
cmake --build . --config Release --target ALL_BUILD
|
||||
mkdir -p BambuStudio-SoftFever
|
||||
cd BambuStudio-SoftFever
|
||||
rm -r ./BambuStudio-SoftFever.app
|
||||
cp -pR ../src/Release/BambuStudio.app ./BambuStudio-SoftFever.app
|
||||
resources_path=$(readlink ./BambuStudio-SoftFever.app/Contents/Resources)
|
||||
rm ./BambuStudio-SoftFever.app/Contents/Resources
|
||||
cp -R $resources_path ./BambuStudio-SoftFever.app/Contents/Resources
|
||||
# delete .DS_Store file
|
||||
find ./BambuStudio-SoftFever.app/ -name '.DS_Store' -delete
|
||||
# extract version
|
||||
export ver="_dev"
|
||||
echo $PWD
|
||||
if [ "1." != "$NIGHTLY_BUILD". ];
|
||||
then
|
||||
ver=$(grep '^#define SoftFever_VERSION' ../src/libslic3r/libslic3r_version.h | cut -d ' ' -f3)
|
||||
ver="_V${ver//\"}"
|
||||
fi
|
||||
|
||||
|
||||
zip -FSr BambuStudio-SoftFever${ver}_Mac_${ARCH}.zip BambuStudio-SoftFever.app
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
set WP=%CD%
|
||||
cd deps
|
||||
mkdir build
|
||||
cd build
|
||||
set DEPS=%CD%/BambuStudio_dep
|
||||
cmake ../ -G "Visual Studio 16 2019" -DDESTDIR="%CD%/BambuStudio_dep" -DCMAKE_BUILD_TYPE=Release
|
||||
cmake --build . --config Release --target ALL_BUILD -- -m
|
||||
|
||||
cd %WP%
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. -G "Visual Studio 16 2019" -DBBL_RELEASE_TO_PUBLIC=1 -DCMAKE_PREFIX_PATH="%DEPS%/usr/local" -DCMAKE_INSTALL_PREFIX="./BambuStudio-SoftFever" -DCMAKE_BUILD_TYPE=RelWithDebInfo -DWIN10SDK_PATH="C:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0"
|
||||
cmake --build . --config RelWithDebInfo --target ALL_BUILD -- -m
|
||||
@REM cmake --build . --target install --config RelWithDebInfo
|
||||
@@ -94,20 +94,19 @@ endif()
|
||||
|
||||
function(__glew_set_find_library_suffix shared_or_static)
|
||||
if((UNIX AND NOT APPLE) AND "${shared_or_static}" MATCHES "SHARED")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".so")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".so" PARENT_SCOPE)
|
||||
elseif((UNIX AND NOT APPLE) AND "${shared_or_static}" MATCHES "STATIC")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".a" PARENT_SCOPE)
|
||||
elseif(APPLE AND "${shared_or_static}" MATCHES "SHARED")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".dylib;.so")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".dylib;.so" PARENT_SCOPE)
|
||||
elseif(APPLE AND "${shared_or_static}" MATCHES "STATIC")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".a" PARENT_SCOPE)
|
||||
elseif(WIN32 AND "${shared_or_static}" MATCHES "SHARED")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".lib")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".lib" PARENT_SCOPE)
|
||||
elseif(WIN32 AND "${shared_or_static}" MATCHES "STATIC")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".lib;.a;.dll.a")
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".lib;.a;.dll.a" PARENT_SCOPE)
|
||||
endif()
|
||||
|
||||
set(CMAKE_FIND_LIBRARY_SUFFIXES "${CMAKE_FIND_LIBRARY_SUFFIXES}" PARENT_SCOPE)
|
||||
if(GLEW_VERBOSE)
|
||||
message(STATUS "FindGLEW: CMAKE_FIND_LIBRARY_SUFFIXES for ${shared_or_static}: ${CMAKE_FIND_LIBRARY_SUFFIXES}")
|
||||
endif()
|
||||
|
||||
@@ -42,10 +42,5 @@ set(VERSION_OK FALSE)
|
||||
endif ()
|
||||
endif ()
|
||||
endif ()
|
||||
# Check for GDK Wayland support
|
||||
include(CheckSymbolExists)
|
||||
set(CMAKE_REQUIRED_INCLUDES ${GTK3_INCLUDE_DIRS})
|
||||
check_symbol_exists(GDK_WINDOWING_WAYLAND "gdk/gdk.h" wxHAVE_GDK_WAYLAND)
|
||||
check_symbol_exists(GDK_WINDOWING_X11 "gdk/gdk.h" wxHAVE_GDK_X11)
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(GTK3 DEFAULT_MSG GTK3_INCLUDE_DIRS GTK3_LIBRARIES VERSION_OK)
|
||||
|
||||
@@ -293,7 +293,7 @@ if(NOT TBB_FOUND)
|
||||
# Create targets
|
||||
##################################
|
||||
|
||||
if(NOT CMAKE_VERSION VERSION_LESS 3.0 AND TBB_FOUND AND NOT TARGET TBB::tbb)
|
||||
if(NOT CMAKE_VERSION VERSION_LESS 3.0 AND TBB_FOUND)
|
||||
add_library(TBB::tbb UNKNOWN IMPORTED)
|
||||
set_target_properties(TBB::tbb PROPERTIES
|
||||
INTERFACE_COMPILE_DEFINITIONS "${TBB_DEFINITIONS}"
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
<key>CFBundleIconFile</key>
|
||||
<string>${MACOSX_BUNDLE_ICON_FILE}</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>com.bambulab.bambu-studio</string>
|
||||
<string>${MACOSX_BUNDLE_GUI_IDENTIFIER}</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleLongVersionString</key>
|
||||
@@ -26,96 +26,10 @@
|
||||
<string>????</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>${MACOSX_BUNDLE_BUNDLE_VERSION}</string>
|
||||
<key>CFBundleDocumentTypes</key>
|
||||
<array>
|
||||
<dict>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array>
|
||||
<string>stl</string>
|
||||
<string>STL</string>
|
||||
</array>
|
||||
<key>CFBundleTypeIconFile</key>
|
||||
<string>stl.icns</string>
|
||||
<key>CFBundleTypeName</key>
|
||||
<string>STL</string>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Viewer</string>
|
||||
<key>LISsAppleDefaultForType</key>
|
||||
<true/>
|
||||
<key>LSHandlerRank</key>
|
||||
<string>Alternate</string>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array>
|
||||
<string>obj</string>
|
||||
<string>OBJ</string>
|
||||
</array>
|
||||
<key>CFBundleTypeIconFile</key>
|
||||
<string>BambuStudio.icns</string>
|
||||
<key>CFBundleTypeName</key>
|
||||
<string>STL</string>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Viewer</string>
|
||||
<key>LISsAppleDefaultForType</key>
|
||||
<true/>
|
||||
<key>LSHandlerRank</key>
|
||||
<string>Alternate</string>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array>
|
||||
<string>amf</string>
|
||||
<string>AMF</string>
|
||||
</array>
|
||||
<key>CFBundleTypeIconFile</key>
|
||||
<string>BambuStudio.icns</string>
|
||||
<key>CFBundleTypeName</key>
|
||||
<string>AMF</string>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Viewer</string>
|
||||
<key>LISsAppleDefaultForType</key>
|
||||
<true/>
|
||||
<key>LSHandlerRank</key>
|
||||
<string>Alternate</string>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array>
|
||||
<string>3mf</string>
|
||||
<string>3MF</string>
|
||||
</array>
|
||||
<key>CFBundleTypeIconFile</key>
|
||||
<string>BambuStudio.icns</string>
|
||||
<key>CFBundleTypeName</key>
|
||||
<string>3MF</string>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Viewer</string>
|
||||
<key>LISsAppleDefaultForType</key>
|
||||
<true/>
|
||||
<key>LSHandlerRank</key>
|
||||
<string>Alternate</string>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array>
|
||||
<string>gcode</string>
|
||||
<string>GCODE</string>
|
||||
</array>
|
||||
<key>CFBundleTypeIconFile</key>
|
||||
<string>gcode.icns</string>
|
||||
<key>CFBundleTypeName</key>
|
||||
<string>GCODE</string>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Viewer</string>
|
||||
<key>LISsAppleDefaultForType</key>
|
||||
<true/>
|
||||
<key>LSHandlerRank</key>
|
||||
<string>Alternate</string>
|
||||
</dict>
|
||||
</array>
|
||||
<key>CSResourcesFileMapped</key>
|
||||
<true/>
|
||||
<key>NSRequiresAquaSystemAppearance</key>
|
||||
<true/>
|
||||
<key>NSHumanReadableCopyright</key>
|
||||
<string>${MACOSX_BUNDLE_COPYRIGHT}</string>
|
||||
</dict>
|
||||
|
||||
54
deps/Blosc/Blosc.cmake
vendored
@@ -6,43 +6,23 @@ else()
|
||||
set(_build_static ON)
|
||||
endif()
|
||||
|
||||
if(IS_CROSS_COMPILE AND APPLE)
|
||||
bambustudio_add_cmake_project(Blosc
|
||||
#URL https://github.com/Blosc/c-blosc/archive/refs/tags/v1.17.0.zip
|
||||
#URL_HASH SHA256=7463a1df566704f212263312717ab2c36b45d45cba6cd0dccebf91b2cc4b4da9
|
||||
URL https://github.com/tamasmeszaros/c-blosc/archive/refs/heads/v1.17.0_tm.zip
|
||||
URL_HASH SHA256=dcb48bf43a672fa3de6a4b1de2c4c238709dad5893d1e097b8374ad84b1fc3b3
|
||||
DEPENDS ${ZLIB_PKG}
|
||||
# Patching upstream does not work this way with git version 2.28 installed on mac worker
|
||||
# PATCH_COMMAND ${GIT_EXECUTABLE} apply --ignore-space-change --whitespace=fix ${CMAKE_CURRENT_LIST_DIR}/blosc-mods.patch
|
||||
CMAKE_ARGS
|
||||
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
|
||||
-DBUILD_SHARED=${_build_shared}
|
||||
-DBUILD_STATIC=${_build_static}
|
||||
-DBUILD_TESTS=OFF
|
||||
-DBUILD_BENCHMARKS=OFF
|
||||
-DPREFER_EXTERNAL_ZLIB=ON
|
||||
-DDEACTIVATE_SSE2=ON
|
||||
-DDEACTIVATE_AVX2=ON
|
||||
)
|
||||
else()
|
||||
bambustudio_add_cmake_project(Blosc
|
||||
#URL https://github.com/Blosc/c-blosc/archive/refs/tags/v1.17.0.zip
|
||||
#URL_HASH SHA256=7463a1df566704f212263312717ab2c36b45d45cba6cd0dccebf91b2cc4b4da9
|
||||
URL https://github.com/tamasmeszaros/c-blosc/archive/refs/heads/v1.17.0_tm.zip
|
||||
URL_HASH SHA256=dcb48bf43a672fa3de6a4b1de2c4c238709dad5893d1e097b8374ad84b1fc3b3
|
||||
DEPENDS ${ZLIB_PKG}
|
||||
# Patching upstream does not work this way with git version 2.28 installed on mac worker
|
||||
# PATCH_COMMAND ${GIT_EXECUTABLE} apply --ignore-space-change --whitespace=fix ${CMAKE_CURRENT_LIST_DIR}/blosc-mods.patch
|
||||
CMAKE_ARGS
|
||||
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
|
||||
-DBUILD_SHARED=${_build_shared}
|
||||
-DBUILD_STATIC=${_build_static}
|
||||
-DBUILD_TESTS=OFF
|
||||
-DBUILD_BENCHMARKS=OFF
|
||||
-DPREFER_EXTERNAL_ZLIB=ON
|
||||
)
|
||||
endif()
|
||||
bambustudio_add_cmake_project(Blosc
|
||||
#URL https://github.com/Blosc/c-blosc/archive/refs/tags/v1.17.0.zip
|
||||
#URL_HASH SHA256=7463a1df566704f212263312717ab2c36b45d45cba6cd0dccebf91b2cc4b4da9
|
||||
URL https://github.com/tamasmeszaros/c-blosc/archive/refs/heads/v1.17.0_tm.zip
|
||||
URL_HASH SHA256=dcb48bf43a672fa3de6a4b1de2c4c238709dad5893d1e097b8374ad84b1fc3b3
|
||||
DEPENDS ${ZLIB_PKG}
|
||||
# Patching upstream does not work this way with git version 2.28 installed on mac worker
|
||||
# PATCH_COMMAND ${GIT_EXECUTABLE} apply --ignore-space-change --whitespace=fix ${CMAKE_CURRENT_LIST_DIR}/blosc-mods.patch
|
||||
CMAKE_ARGS
|
||||
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
|
||||
-DBUILD_SHARED=${_build_shared}
|
||||
-DBUILD_STATIC=${_build_static}
|
||||
-DBUILD_TESTS=OFF
|
||||
-DBUILD_BENCHMARKS=OFF
|
||||
-DPREFER_EXTERNAL_ZLIB=ON
|
||||
)
|
||||
|
||||
if (MSVC)
|
||||
add_debug_dep(dep_Blosc)
|
||||
endif ()
|
||||
67
deps/Boost/Boost.cmake
vendored
@@ -67,6 +67,16 @@ include(ProcessorCount)
|
||||
ProcessorCount(NPROC)
|
||||
file(TO_NATIVE_PATH ${DESTDIR}/usr/local/ _prefix)
|
||||
|
||||
set(_boost_flags "")
|
||||
if (UNIX)
|
||||
set(_boost_flags "cflags=-fPIC;cxxflags=-fPIC")
|
||||
elseif(APPLE)
|
||||
set(_boost_flags
|
||||
"cflags=-fPIC -mmacosx-version-min=${DEP_OSX_TARGET};"
|
||||
"cxxflags=-fPIC -mmacosx-version-min=${DEP_OSX_TARGET};"
|
||||
"mflags=-fPIC -mmacosx-version-min=${DEP_OSX_TARGET};"
|
||||
"mmflags=-fPIC -mmacosx-version-min=${DEP_OSX_TARGET}")
|
||||
endif()
|
||||
|
||||
set(_boost_variants "")
|
||||
if(CMAKE_BUILD_TYPE)
|
||||
@@ -90,38 +100,8 @@ if (NOT _boost_variants)
|
||||
set(_boost_variants release)
|
||||
endif()
|
||||
|
||||
if (IS_CROSS_COMPILE AND APPLE)
|
||||
if (${CMAKE_OSX_ARCHITECTURES} MATCHES "arm")
|
||||
message(STATUS "Compiling Boost for arm64.")
|
||||
message(STATUS "Compiling Boost with toolset ${_boost_toolset}.")
|
||||
message(STATUS "Compiling Boost with libs ${_libs}.")
|
||||
message(STATUS "Compiling Boost with variant ${_boost_variants}.")
|
||||
message(STATUS "Compiling Boost with _bootstrap_cmd ${_bootstrap_cmd}.")
|
||||
message(STATUS "_boost_linkflags = ${_boost_linkflags}")
|
||||
set(_arch_flags "-arch arm64")
|
||||
set(_boost_linkflags "linkflags=${_arch_flags}")
|
||||
message(STATUS "_cmake_args_osx_arch = '${_cmake_args_osx_arch}'")
|
||||
elseif (${CMAKE_OSX_ARCHITECTURES} MATCHES "x86_64")
|
||||
message(STATUS "Compiling Boost for x86_64.")
|
||||
set(_arch_flags "-arch x86_64")
|
||||
endif()
|
||||
set(_boost_linkflags "linkflags=${_arch_flags}")
|
||||
endif ()
|
||||
|
||||
set(_boost_flags "")
|
||||
if(APPLE)
|
||||
set(_boost_flags
|
||||
"cflags=-fPIC ${_arch_flags} -mmacosx-version-min=${DEP_OSX_TARGET};"
|
||||
"cxxflags=-fPIC ${_arch_flags} -mmacosx-version-min=${DEP_OSX_TARGET};"
|
||||
"mflags=-fPIC ${_arch_flags} -mmacosx-version-min=${DEP_OSX_TARGET};"
|
||||
"mmflags=-fPIC ${_arch_flags} -mmacosx-version-min=${DEP_OSX_TARGET}")
|
||||
elseif (UNIX)
|
||||
set(_boost_flags "cflags=-fPIC;cxxflags=-fPIC")
|
||||
endif()
|
||||
|
||||
set(_build_cmd ${_build_cmd}
|
||||
${_boost_flags}
|
||||
${_boost_linkflags}
|
||||
-j${NPROC}
|
||||
${_libs}
|
||||
--layout=versioned
|
||||
@@ -137,14 +117,9 @@ set(_build_cmd ${_build_cmd}
|
||||
|
||||
set(_install_cmd ${_build_cmd} --prefix=${_prefix} install)
|
||||
|
||||
if (NOT IS_CROSS_COMPILE OR NOT APPLE OR BUILD_SHARED_LIBS)
|
||||
message(STATUS "Standard boost build with bootstrap command '${_bootstrap_cmd}'")
|
||||
message(STATUS "Standard boost build with patch command '${_patch_command}'")
|
||||
message(STATUS "Standard boost build with build command '${_build_cmd}'")
|
||||
message(STATUS "Standard boost build with install command '${_install_cmd}'")
|
||||
ExternalProject_Add(
|
||||
dep_Boost
|
||||
URL "https://boostorg.jfrog.io/artifactory/main/release/1.75.0/source/boost_1_75_0.tar.gz"
|
||||
URL "https://boostorg.jfrog.io/artifactory/main/release/1.75.0/source/boost_1_75_0.tar.gz"
|
||||
URL_HASH SHA256=aeb26f80e80945e82ee93e5939baebdca47b9dee80a07d3144be1e1a6a66dd6a
|
||||
DOWNLOAD_DIR ${DEP_DOWNLOAD_DIR}/Boost
|
||||
CONFIGURE_COMMAND "${_bootstrap_cmd}"
|
||||
@@ -154,26 +129,7 @@ ExternalProject_Add(
|
||||
INSTALL_COMMAND "${_install_cmd}"
|
||||
)
|
||||
|
||||
else()
|
||||
|
||||
ExternalProject_Add(
|
||||
dep_Boost
|
||||
URL "https://boostorg.jfrog.io/artifactory/main/release/1.75.0/source/boost_1_75_0.tar.gz"
|
||||
URL_HASH SHA256=aeb26f80e80945e82ee93e5939baebdca47b9dee80a07d3144be1e1a6a66dd6a
|
||||
DOWNLOAD_DIR ${DEP_DOWNLOAD_DIR}/Boost
|
||||
CONFIGURE_COMMAND ./bootstrap.sh
|
||||
--with-toolset=clang
|
||||
--with-libraries=date_time,filesystem,iostreams,locale,log,regex,system,thread
|
||||
"--prefix=${DESTDIR}/usr/local"
|
||||
# PATCH_COMMAND ${_patch_command}
|
||||
BUILD_COMMAND "${_build_cmd}"
|
||||
BUILD_IN_SOURCE ON
|
||||
INSTALL_COMMAND "${_install_cmd}"
|
||||
)
|
||||
endif()
|
||||
|
||||
if ("${CMAKE_SIZEOF_VOID_P}" STREQUAL "8")
|
||||
message(STATUS "Patch the boost::polygon library with a custom one.")
|
||||
# Patch the boost::polygon library with a custom one.
|
||||
ExternalProject_Add(dep_boost_polygon
|
||||
EXCLUDE_FROM_ALL ON
|
||||
@@ -185,7 +141,6 @@ if ("${CMAKE_SIZEOF_VOID_P}" STREQUAL "8")
|
||||
DEPENDS dep_Boost
|
||||
CONFIGURE_COMMAND ""
|
||||
BUILD_COMMAND ""
|
||||
${_cmake_args_osx_arch}
|
||||
INSTALL_COMMAND ${CMAKE_COMMAND} -E copy_directory
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/dep_boost_polygon-prefix/src/dep_boost_polygon/include/boost/polygon"
|
||||
"${DESTDIR}/usr/local/include/boost/polygon"
|
||||
|
||||
44
deps/CMakeLists.txt
vendored
@@ -40,25 +40,6 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||
option(DEP_WX_GTK3 "Build wxWidgets against GTK3" OFF)
|
||||
endif()
|
||||
|
||||
set(IS_CROSS_COMPILE FALSE)
|
||||
|
||||
if (APPLE)
|
||||
set(CMAKE_FIND_FRAMEWORK LAST)
|
||||
set(CMAKE_FIND_APPBUNDLE LAST)
|
||||
list(FIND CMAKE_OSX_ARCHITECTURES ${CMAKE_SYSTEM_PROCESSOR} _arch_idx)
|
||||
message(STATUS "prusaslicer_add_cmake_project for Apple")
|
||||
if (CMAKE_OSX_ARCHITECTURES AND _arch_idx LESS 0)
|
||||
message(STATUS "prusaslicer_add_cmake_project for Apple crosscompiling")
|
||||
set(IS_CROSS_COMPILE TRUE)
|
||||
set(CMAKE_CXX_COMPILER_ID "Clang")
|
||||
string(REPLACE ";" "$<SEMICOLON>" CMAKE_OSX_ARCHS "${CMAKE_OSX_ARCHITECTURES}")
|
||||
set(_cmake_osx_arch -DCMAKE_OSX_ARCHITECTURES:STRING=${CMAKE_OSX_ARCHS})
|
||||
set(_cmake_args_osx_arch CMAKE_ARGS -DCMAKE_OSX_ARCHITECTURES:STRING=${CMAKE_OSX_ARCHS})
|
||||
message(STATUS "Detect Cross-compilation. Will build for target ${CMAKE_OSX_ARCHS}" )
|
||||
endif ()
|
||||
endif ()
|
||||
|
||||
|
||||
# On developer machines, it can be enabled to speed up compilation and suppress warnings coming from IGL.
|
||||
# FIXME:
|
||||
# Enabling this option is not safe. IGL will compile itself with its own version of Eigen while
|
||||
@@ -96,7 +77,6 @@ function(bambustudio_add_cmake_project projectname)
|
||||
set(_build_j "/m")
|
||||
endif ()
|
||||
|
||||
if (NOT IS_CROSS_COMPILE OR NOT APPLE)
|
||||
ExternalProject_Add(
|
||||
dep_${projectname}
|
||||
EXCLUDE_FROM_ALL ON
|
||||
@@ -112,7 +92,6 @@ if (NOT IS_CROSS_COMPILE OR NOT APPLE)
|
||||
-DCMAKE_CXX_COMPILER:STRING=${CMAKE_CXX_COMPILER}
|
||||
-DCMAKE_TOOLCHAIN_FILE:STRING=${CMAKE_TOOLCHAIN_FILE}
|
||||
-DBUILD_SHARED_LIBS:BOOL=OFF
|
||||
${_cmake_osx_arch}
|
||||
"${_configs_line}"
|
||||
${DEP_CMAKE_OPTS}
|
||||
${P_ARGS_CMAKE_ARGS}
|
||||
@@ -120,26 +99,6 @@ if (NOT IS_CROSS_COMPILE OR NOT APPLE)
|
||||
BUILD_COMMAND ${CMAKE_COMMAND} --build . --config Release -- ${_build_j}
|
||||
INSTALL_COMMAND ${CMAKE_COMMAND} --build . --target install --config Release
|
||||
)
|
||||
else()
|
||||
ExternalProject_Add(
|
||||
dep_${projectname}
|
||||
EXCLUDE_FROM_ALL ON
|
||||
INSTALL_DIR ${DESTDIR}/usr/local
|
||||
DOWNLOAD_DIR ${DEP_DOWNLOAD_DIR}/${projectname}
|
||||
${_gen}
|
||||
CMAKE_ARGS
|
||||
-DCMAKE_INSTALL_PREFIX:STRING=${DESTDIR}/usr/local
|
||||
-DBUILD_SHARED_LIBS:BOOL=OFF
|
||||
${_cmake_osx_arch}
|
||||
"${_configs_line}"
|
||||
${DEP_CMAKE_OPTS}
|
||||
${P_ARGS_CMAKE_ARGS}
|
||||
${P_ARGS_UNPARSED_ARGUMENTS}
|
||||
BUILD_COMMAND ${CMAKE_COMMAND} --build . --config Release -- ${_build_j}
|
||||
INSTALL_COMMAND ${CMAKE_COMMAND} --build . --target install --config Release
|
||||
)
|
||||
|
||||
endif()
|
||||
|
||||
endfunction(bambustudio_add_cmake_project)
|
||||
|
||||
@@ -158,7 +117,6 @@ if (MSVC)
|
||||
endif ()
|
||||
elseif (APPLE)
|
||||
message("OS X SDK Path: ${CMAKE_OSX_SYSROOT}")
|
||||
set(CMAKE_OSX_DEPLOYMENT_TARGET "11.3" CACHE STRING "Minimum OS X deployment version" FORCE)
|
||||
if (CMAKE_OSX_DEPLOYMENT_TARGET)
|
||||
set(DEP_OSX_TARGET "${CMAKE_OSX_DEPLOYMENT_TARGET}")
|
||||
message("OS X Deployment Target: ${DEP_OSX_TARGET}")
|
||||
@@ -233,7 +191,6 @@ include(JPEG/JPEG.cmake)
|
||||
include(TIFF/TIFF.cmake)
|
||||
include(wxWidgets/wxWidgets.cmake)
|
||||
include(OCCT/OCCT.cmake)
|
||||
include(FREETYPE/FREETYPE.cmake)
|
||||
|
||||
set(_dep_list
|
||||
dep_Boost
|
||||
@@ -262,7 +219,6 @@ else()
|
||||
endif()
|
||||
|
||||
list(APPEND _dep_list "dep_OCCT")
|
||||
list(APPEND _dep_list "dep_FREETYPE")
|
||||
|
||||
add_custom_target(deps ALL DEPENDS ${_dep_list})
|
||||
|
||||
|
||||
4
deps/CURL/CURL.cmake
vendored
@@ -31,8 +31,8 @@ elseif (APPLE)
|
||||
|
||||
${_curl_platform_flags}
|
||||
|
||||
#-DCMAKE_USE_SECTRANSP:BOOL=ON
|
||||
-DCMAKE_USE_OPENSSL:BOOL=ON
|
||||
-DCMAKE_USE_SECTRANSP:BOOL=ON
|
||||
-DCMAKE_USE_OPENSSL:BOOL=OFF
|
||||
|
||||
-DCURL_CA_PATH:STRING=none
|
||||
)
|
||||
|
||||
29
deps/FREETYPE/FREETYPE.cmake
vendored
@@ -1,29 +0,0 @@
|
||||
if(WIN32)
|
||||
set(library_build_shared "1")
|
||||
else()
|
||||
set(library_build_shared "0")
|
||||
endif()
|
||||
|
||||
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||
set(_ft_disable_zlib "-D FT_DISABLE_ZLIB=FALSE")
|
||||
else()
|
||||
set(_ft_disable_zlib "-D FT_DISABLE_ZLIB=TRUE")
|
||||
endif()
|
||||
|
||||
bambustudio_add_cmake_project(FREETYPE
|
||||
URL https://mirror.ossplanet.net/nongnu/freetype/freetype-2.12.1.tar.gz
|
||||
URL_HASH SHA256=efe71fd4b8246f1b0b1b9bfca13cfff1c9ad85930340c27df469733bbb620938
|
||||
#DEPENDS ${ZLIB_PKG}
|
||||
#"${_patch_step}"
|
||||
CMAKE_ARGS
|
||||
-D BUILD_SHARED_LIBS=${library_build_shared}
|
||||
${_ft_disable_zlib}
|
||||
-D FT_DISABLE_BZIP2=TRUE
|
||||
-D FT_DISABLE_PNG=TRUE
|
||||
-D FT_DISABLE_HARFBUZZ=TRUE
|
||||
-D FT_DISABLE_BROTLI=TRUE
|
||||
)
|
||||
|
||||
if(MSVC)
|
||||
add_debug_dep(dep_FREETYPE)
|
||||
endif()
|
||||
19
deps/GLEW/glew/CMakeLists.txt
vendored
@@ -3,17 +3,12 @@ project(GLEW)
|
||||
|
||||
find_package(OpenGL REQUIRED)
|
||||
|
||||
if(OpenGL_EGL_FOUND)
|
||||
message(STATUS "building GLEW for EGL (hope that wxWidgets agrees, otherwise you won't have any output!)")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DGLEW_EGL")
|
||||
endif()
|
||||
|
||||
add_library(GLEW src/glew.c)
|
||||
target_include_directories(GLEW PRIVATE include/)
|
||||
target_link_libraries(GLEW PUBLIC OpenGL::GL)
|
||||
add_library(glew src/glew.c)
|
||||
target_include_directories(glew PRIVATE include/)
|
||||
target_link_libraries(glew PUBLIC OpenGL::GL)
|
||||
|
||||
if (NOT BUILD_SHARED_LIBS)
|
||||
target_compile_definitions(GLEW PUBLIC GLEW_STATIC)
|
||||
target_compile_definitions(glew PUBLIC GLEW_STATIC)
|
||||
endif ()
|
||||
|
||||
include(GNUInstallDirs)
|
||||
@@ -23,12 +18,14 @@ install(
|
||||
${PROJECT_SOURCE_DIR}/include/GL/glew.h
|
||||
${PROJECT_SOURCE_DIR}/include/GL/wglew.h
|
||||
${PROJECT_SOURCE_DIR}/include/GL/glxew.h
|
||||
${PROJECT_SOURCE_DIR}/include/GL/eglew.h
|
||||
DESTINATION
|
||||
${CMAKE_INSTALL_INCLUDEDIR}/GL
|
||||
)
|
||||
|
||||
install(TARGETS GLEW GLEW
|
||||
add_library(GLEW INTERFACE)
|
||||
target_link_libraries(GLEW INTERFACE glew)
|
||||
|
||||
install(TARGETS glew GLEW
|
||||
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
|
||||
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
|
||||
138
deps/GLEW/glew/README.md
vendored
@@ -1,82 +1,53 @@
|
||||
# GLEW - The OpenGL Extension Wrangler Library
|
||||
THIS IS NOT THE COMPLETE GLEW DISTRIBUTION. ONLY FILES NEEDED FOR COMPILING GLEW INTO SLIC3R WERE PUT INTO THE SLIC3R SOURCE DISTRIBUTION.
|
||||
|
||||
The OpenGL Extension Wrangler Library (GLEW) is a cross-platform open-source C/C++ extension loading library. GLEW provides efficient run-time mechanisms for determining which OpenGL extensions are supported on the target platform. OpenGL core and extension functionality is exposed in a single header file. GLEW has been tested on a variety of operating systems, including Windows, Linux, Mac OS X, FreeBSD, Irix, and Solaris.
|
||||
A CMAKE CONFIG EXPORT IS ADDED TO ENABLE FIND PACKAGE TO FIND DEBUG BUILD ON MSVC
|
||||
|
||||
# GLEW - The OpenGL Extension Wrangler Library
|
||||
|
||||

|
||||
|
||||
http://glew.sourceforge.net/
|
||||
|
||||
https://github.com/nigels-com/glew
|
||||
https://github.com.cnpmjs.org/nigels-com/glew
|
||||
|
||||
[](https://travis-ci.org/nigels-com/glew)
|
||||
[](https://gitter.im/nigels-com/glew?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
|
||||
[](https://sourceforge.net/projects/glew/files/latest/download)
|
||||
|
||||
## Table of Contents
|
||||
|
||||
* [Downloads](#downloads)
|
||||
* [Recent snapshots](#recent-snapshots)
|
||||
* [Build](#build)
|
||||
* [Linux and Mac](#linux-and-mac)
|
||||
* [Using GNU Make](#using-gnu-make)
|
||||
* [Install build tools](#install-build-tools)
|
||||
* [Build](#build-1)
|
||||
* [Linux EGL](#linux-egl)
|
||||
* [Linux OSMesa](#linux-osmesa)
|
||||
* [Linux mingw-w64](#linux-mingw-w64)
|
||||
* [Using cmake](#using-cmake)
|
||||
* [Install build tools](#install-build-tools-1)
|
||||
* [Build](#build-2)
|
||||
* [Windows](#windows)
|
||||
* [Visual Studio](#visual-studio)
|
||||
* [MSYS/Mingw](#msysmingw)
|
||||
* [MSYS2/Mingw-w64](#msys2mingw-w64)
|
||||
* [glewinfo](#glewinfo)
|
||||
* [Code Generation](#code-generation)
|
||||
* [Authors](#authors)
|
||||
* [Contributions](#contributions)
|
||||
* [Copyright and Licensing](#copyright-and-licensing)
|
||||
|
||||
## Downloads
|
||||
|
||||
Current release is [2.1.0](https://sourceforge.net/projects/glew/files/glew/2.1.0/).
|
||||
Current release is [2.0.0](https://sourceforge.net/projects/glew/files/glew/2.0.0/).
|
||||
[(Change Log)](http://glew.sourceforge.net/log.html)
|
||||
|
||||
Sources available as
|
||||
[ZIP](https://sourceforge.net/projects/glew/files/glew/2.1.0/glew-2.1.0.zip/download) or
|
||||
[TGZ](https://sourceforge.net/projects/glew/files/glew/2.1.0/glew-2.1.0.tgz/download).
|
||||
Sources available as
|
||||
[ZIP](https://sourceforge.net/projects/glew/files/glew/2.0.0/glew-2.0.0.zip/download) or
|
||||
[TGZ](https://sourceforge.net/projects/glew/files/glew/2.0.0/glew-2.0.0.tgz/download).
|
||||
|
||||
Windows binaries for [32-bit and 64-bit](https://sourceforge.net/projects/glew/files/glew/2.1.0/glew-2.1.0-win32.zip/download).
|
||||
Windows binaries for [32-bit and 64-bit](https://sourceforge.net/projects/glew/files/glew/2.0.0/glew-2.0.0-win32.zip/download).
|
||||
|
||||
### Recent snapshots
|
||||
|
||||
Snapshots may contain new features, bug-fixes or new OpenGL extensions ahead of tested, official releases.
|
||||
|
||||
[glew-20200115.tgz](https://sourceforge.net/projects/glew/files/glew/snapshots/glew-20200115.tgz/download) *GLEW 2.2.0 RC3: fixes*
|
||||
[glew-20160708.tgz](http://sourceforge.net/projects/glew/files/glew/snapshots/glew-20160708.tgz/download)
|
||||
*GLEW 2.0.0 RC: Core context, EGL support, no MX*
|
||||
|
||||
[glew-20190928.tgz](https://sourceforge.net/projects/glew/files/glew/snapshots/glew-20190928.tgz/download) *GLEW 2.2.0 RC2: New extensions, bug fixes*
|
||||
[glew-20160402.tgz](http://sourceforge.net/projects/glew/files/glew/snapshots/glew-20160402.tgz/download)
|
||||
*GLEW 2.0.0 RC: Core context, EGL support, no MX*
|
||||
|
||||
## Build
|
||||
|
||||
It is highly recommended to build from a tgz or zip release snapshot.
|
||||
The code generation workflow is a complex brew of gnu make, perl and python, that works best on Linux or Mac.
|
||||
The code generation is known to work on Windows using [MSYS2](https://www.msys2.org/).
|
||||
For most end-users of GLEW the official releases are the best choice, with first class support.
|
||||
From a downloaded tarball or zip archive:
|
||||
|
||||
### Linux and Mac
|
||||
|
||||
#### Using GNU Make
|
||||
|
||||
GNU make is the primary build system for GLEW, historically.
|
||||
It includes targets for building the sources and headers, for maintenance purposes.
|
||||
|
||||
##### Install build tools
|
||||
|
||||
Debian/Ubuntu/Mint: `$ sudo apt-get install build-essential libxmu-dev libxi-dev libgl-dev`
|
||||
Debian/Ubuntu/Mint: `$ sudo apt-get install build-essential libxmu-dev libxi-dev libgl-dev libosmesa-dev git`
|
||||
|
||||
RedHat/CentOS/Fedora: `$ sudo yum install libXmu-devel libXi-devel libGL-devel`
|
||||
|
||||
FreeBSD: `# pkg install xorg lang/gcc git cmake gmake bash python perl5`
|
||||
RedHat/CentOS/Fedora: `$ sudo yum install libXmu-devel libXi-devel libGL-devel git`
|
||||
|
||||
##### Build
|
||||
|
||||
@@ -84,46 +55,24 @@ FreeBSD: `# pkg install xorg lang/gcc git cmake gmake bash python perl5`
|
||||
$ sudo make install
|
||||
$ make clean
|
||||
|
||||
Targets: `all, glew.lib (sub-targets: glew.lib.shared, glew.lib.static), glew.bin, clean, install, uninstall`
|
||||
Targets: `all, glew.lib, glew.bin, clean, install, uninstall`
|
||||
|
||||
Variables: `SYSTEM=linux-clang, GLEW_DEST=/usr/local, STRIP=`
|
||||
|
||||
_Note: you may need to call `make` in the **auto** folder first_
|
||||
|
||||
##### Linux EGL
|
||||
|
||||
$ sudo apt install libegl1-mesa-dev
|
||||
$ make SYSTEM=linux-egl
|
||||
|
||||
##### Linux OSMesa
|
||||
|
||||
$ sudo apt install libosmesa-dev
|
||||
$ make SYSTEM=linux-osmesa
|
||||
|
||||
##### Linux mingw-w64
|
||||
|
||||
$ sudo apt install mingw-w64
|
||||
$ make SYSTEM=linux-mingw32
|
||||
$ make SYSTEM=linux-mingw64
|
||||
|
||||
#### Using cmake
|
||||
|
||||
The cmake build is mostly contributer maintained.
|
||||
Due to the multitude of use cases this is maintained on a _best effort_ basis.
|
||||
Pull requests are welcome.
|
||||
|
||||
*CMake 2.8.12 or higher is required.*
|
||||
|
||||
##### Install build tools
|
||||
|
||||
Debian/Ubuntu/Mint: `$ sudo apt-get install build-essential libxmu-dev libxi-dev libgl-dev cmake git`
|
||||
Debian/Ubuntu/Mint: `$ sudo apt-get install build-essential libXmu-dev libXi-dev libgl-dev git cmake`
|
||||
|
||||
RedHat/CentOS/Fedora: `$ sudo yum install libXmu-devel libXi-devel libGL-devel cmake git`
|
||||
RedHat/CentOS/Fedora: `$ sudo yum install libXmu-devel libXi-devel libGL-devel git cmake`
|
||||
|
||||
##### Build
|
||||
|
||||
$ cd build
|
||||
$ cmake ./cmake
|
||||
$ cmake ./cmake
|
||||
$ make -j4
|
||||
|
||||
| Target | Description |
|
||||
@@ -147,9 +96,9 @@ RedHat/CentOS/Fedora: `$ sudo yum install libXmu-devel libXi-devel libGL-devel c
|
||||
|
||||
#### Visual Studio
|
||||
|
||||
Use the provided Visual Studio project file in build/vc15/
|
||||
Use the provided Visual Studio project file in build/vc12/
|
||||
|
||||
Projects for vc6, vc10, vc12 and vc14 are also provided
|
||||
Projects for vc6 and vc10 are also provided
|
||||
|
||||
#### MSYS/Mingw
|
||||
|
||||
@@ -169,7 +118,7 @@ Available from [Msys2](http://msys2.github.io/) and/or [Mingw-w64](http://mingw-
|
||||
|
||||
Requirements: bash, make, gcc
|
||||
|
||||
$ pacman -S gcc make mingw-w64-i686-gcc mingw-w64-x86_64-gcc
|
||||
$ pacman -S gcc make mingw-w64-i686-gcc mingw-w64-x86_64-gcc
|
||||
$ make
|
||||
$ make install
|
||||
$ make install.all
|
||||
@@ -179,8 +128,8 @@ Alternative toolchain: `SYSTEM=msys, SYSTEM=msys-win32, SYSTEM=msys-win64`
|
||||
## glewinfo
|
||||
|
||||
`glewinfo` is a command-line tool useful for inspecting the capabilities of an
|
||||
OpenGL implementation and GLEW support for that. Please include `glewinfo.txt`
|
||||
with bug reports, as appropriate.
|
||||
OpenGL implementation and GLEW support for that. Please include the output of
|
||||
`glewinfo` with bug reports, as appropriate.
|
||||
|
||||
---------------------------
|
||||
GLEW Extension Info
|
||||
@@ -200,12 +149,12 @@ with bug reports, as appropriate.
|
||||
glDrawRangeElements: OK
|
||||
glTexImage3D: OK
|
||||
glTexSubImage3D: OK
|
||||
|
||||
|
||||
...
|
||||
|
||||
## Code Generation
|
||||
|
||||
A Unix or Mac environment is needed for building GLEW from scratch to
|
||||
A Unix or Mac environment is neded for building GLEW from scratch to
|
||||
include new extensions, or customize the code generation. The extension
|
||||
data is regenerated from the top level source directory with:
|
||||
|
||||
@@ -216,43 +165,32 @@ download a pre-generated (unsupported) snapshot:
|
||||
|
||||
https://sourceforge.net/projects/glew/files/glew/snapshots/
|
||||
|
||||
Travis-built snapshots are also available:
|
||||
|
||||
https://glew.s3.amazonaws.com/index.html
|
||||
|
||||
## Authors
|
||||
|
||||
GLEW is currently maintained by [Nigel Stewart](https://github.com/nigels-com)
|
||||
GLEW is currently maintained by [Nigel Stewart](https://github.com.cnpmjs.org/nigels-com)
|
||||
with bug fixes, new OpenGL extension support and new releases.
|
||||
|
||||
GLEW was developed by [Milan Ikits](http://www.cs.utah.edu/~ikits/)
|
||||
and [Marcelo Magallon](http://wwwvis.informatik.uni-stuttgart.de/~magallon/).
|
||||
Aaron Lefohn, Joe Kniss, and Chris Wyman were the first users and also
|
||||
assisted with the design and debugging process.
|
||||
assisted with the design and debugging process.
|
||||
|
||||
The acronym GLEW originates from Aaron Lefohn.
|
||||
Pasi Kärkkäinen identified and fixed several problems with
|
||||
GLX and SDL. Nate Robins created the `wglinfo` utility, to
|
||||
which modifications were made by Michael Wimmer.
|
||||
|
||||
## Contributions
|
||||
|
||||
GLEW welcomes community contributions. Typically these are co-ordinated
|
||||
via [Issues](https://github.com/nigels-com/glew/issues) or
|
||||
[Pull Requests](https://github.com/nigels-com/glew/pulls) in the
|
||||
GitHub web interface.
|
||||
|
||||
Be sure to mention platform and compiler toolchain details when filing
|
||||
a bug report. The output of `glewinfo` can be quite useful for discussion
|
||||
also.
|
||||
|
||||
Generally GLEW is usually released once a year, around the time of the Siggraph
|
||||
computer graphics conference. If you're not using the current release
|
||||
version of GLEW, be sure to check if the issue or bug is fixed there.
|
||||
which modifications were made by Michael Wimmer.
|
||||
|
||||
## Copyright and Licensing
|
||||
|
||||
GLEW is originally derived from the EXTGL project by Lev Povalahev.
|
||||
The source code is licensed under the
|
||||
[Modified BSD License](http://glew.sourceforge.net/glew.txt), the
|
||||
The source code is licensed under the
|
||||
[Modified BSD License](http://glew.sourceforge.net/glew.txt), the
|
||||
[Mesa 3-D License](http://glew.sourceforge.net/mesa.txt) (MIT) and the
|
||||
[Khronos License](http://glew.sourceforge.net/khronos.txt) (MIT).
|
||||
|
||||
The automatic code generation scripts are released under the
|
||||
The automatic code generation scripts are released under the
|
||||
[GNU GPL](http://glew.sourceforge.net/gpl.txt).
|
||||
|
||||
2
deps/GLEW/glew/VERSION
vendored
@@ -1 +1 @@
|
||||
2.2.0
|
||||
1.13.0
|
||||
3051
deps/GLEW/glew/include/GL/eglew.h
vendored
6856
deps/GLEW/glew/include/GL/glew.h
vendored
203
deps/GLEW/glew/include/GL/glxew.h
vendored
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
** The OpenGL Extension Wrangler Library
|
||||
** Copyright (C) 2008-2019, Nigel Stewart <nigels[]users sourceforge net>
|
||||
** Copyright (C) 2008-2015, Nigel Stewart <nigels[]users sourceforge net>
|
||||
** Copyright (C) 2002-2008, Milan Ikits <milan ikits[]ieee org>
|
||||
** Copyright (C) 2002-2008, Marcelo E. Magallon <mmagallo[]debian org>
|
||||
** Copyright (C) 2002, Lev Povalahev
|
||||
@@ -98,12 +98,7 @@
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/Xutil.h>
|
||||
#include <X11/Xmd.h>
|
||||
|
||||
#ifndef GLEW_INCLUDE
|
||||
# include <GL/glew.h>
|
||||
#else
|
||||
# include GLEW_INCLUDE
|
||||
#endif
|
||||
#include <GL/glew.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
@@ -397,7 +392,7 @@ typedef Bool ( * PFNGLXMAKEASSOCIATEDCONTEXTCURRENTAMDPROC) (GLXContext ctx);
|
||||
#ifndef GLX_ARB_context_flush_control
|
||||
#define GLX_ARB_context_flush_control 1
|
||||
|
||||
#define GLX_CONTEXT_RELEASE_BEHAVIOR_NONE_ARB 0
|
||||
#define GLX_CONTEXT_RELEASE_BEHAVIOR_NONE_ARB 0x0000
|
||||
#define GLX_CONTEXT_RELEASE_BEHAVIOR_ARB 0x2097
|
||||
#define GLX_CONTEXT_RELEASE_BEHAVIOR_FLUSH_ARB 0x2098
|
||||
|
||||
@@ -410,13 +405,13 @@ typedef Bool ( * PFNGLXMAKEASSOCIATEDCONTEXTCURRENTAMDPROC) (GLXContext ctx);
|
||||
#ifndef GLX_ARB_create_context
|
||||
#define GLX_ARB_create_context 1
|
||||
|
||||
#define GLX_CONTEXT_DEBUG_BIT_ARB 0x00000001
|
||||
#define GLX_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB 0x00000002
|
||||
#define GLX_CONTEXT_DEBUG_BIT_ARB 0x0001
|
||||
#define GLX_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB 0x0002
|
||||
#define GLX_CONTEXT_MAJOR_VERSION_ARB 0x2091
|
||||
#define GLX_CONTEXT_MINOR_VERSION_ARB 0x2092
|
||||
#define GLX_CONTEXT_FLAGS_ARB 0x2094
|
||||
|
||||
typedef GLXContext ( * PFNGLXCREATECONTEXTATTRIBSARBPROC) (Display* dpy, GLXFBConfig config, GLXContext share_context, Bool direct, const int* attrib_list);
|
||||
typedef GLXContext ( * PFNGLXCREATECONTEXTATTRIBSARBPROC) (Display* dpy, GLXFBConfig config, GLXContext share_context, Bool direct, const int *attrib_list);
|
||||
|
||||
#define glXCreateContextAttribsARB GLXEW_GET_FUN(__glewXCreateContextAttribsARB)
|
||||
|
||||
@@ -424,17 +419,6 @@ typedef GLXContext ( * PFNGLXCREATECONTEXTATTRIBSARBPROC) (Display* dpy, GLXFBCo
|
||||
|
||||
#endif /* GLX_ARB_create_context */
|
||||
|
||||
/* -------------------- GLX_ARB_create_context_no_error -------------------- */
|
||||
|
||||
#ifndef GLX_ARB_create_context_no_error
|
||||
#define GLX_ARB_create_context_no_error 1
|
||||
|
||||
#define GLX_CONTEXT_OPENGL_NO_ERROR_ARB 0x31B3
|
||||
|
||||
#define GLXEW_ARB_create_context_no_error GLXEW_GET_VAR(__GLXEW_ARB_create_context_no_error)
|
||||
|
||||
#endif /* GLX_ARB_create_context_no_error */
|
||||
|
||||
/* --------------------- GLX_ARB_create_context_profile -------------------- */
|
||||
|
||||
#ifndef GLX_ARB_create_context_profile
|
||||
@@ -616,20 +600,6 @@ typedef void ( * PFNGLXRELEASETEXIMAGEATIPROC) (Display *dpy, GLXPbuffer pbuf, i
|
||||
|
||||
#endif /* GLX_EXT_buffer_age */
|
||||
|
||||
/* ------------------------ GLX_EXT_context_priority ----------------------- */
|
||||
|
||||
#ifndef GLX_EXT_context_priority
|
||||
#define GLX_EXT_context_priority 1
|
||||
|
||||
#define GLX_CONTEXT_PRIORITY_LEVEL_EXT 0x3100
|
||||
#define GLX_CONTEXT_PRIORITY_HIGH_EXT 0x3101
|
||||
#define GLX_CONTEXT_PRIORITY_MEDIUM_EXT 0x3102
|
||||
#define GLX_CONTEXT_PRIORITY_LOW_EXT 0x3103
|
||||
|
||||
#define GLXEW_EXT_context_priority GLXEW_GET_VAR(__GLXEW_EXT_context_priority)
|
||||
|
||||
#endif /* GLX_EXT_context_priority */
|
||||
|
||||
/* ------------------- GLX_EXT_create_context_es2_profile ------------------ */
|
||||
|
||||
#ifndef GLX_EXT_create_context_es2_profile
|
||||
@@ -688,13 +658,11 @@ typedef XID GLXContextID;
|
||||
|
||||
typedef void ( * PFNGLXFREECONTEXTEXTPROC) (Display* dpy, GLXContext context);
|
||||
typedef GLXContextID ( * PFNGLXGETCONTEXTIDEXTPROC) (const GLXContext context);
|
||||
typedef Display* ( * PFNGLXGETCURRENTDISPLAYEXTPROC) (void);
|
||||
typedef GLXContext ( * PFNGLXIMPORTCONTEXTEXTPROC) (Display* dpy, GLXContextID contextID);
|
||||
typedef int ( * PFNGLXQUERYCONTEXTINFOEXTPROC) (Display* dpy, GLXContext context, int attribute, int* value);
|
||||
typedef int ( * PFNGLXQUERYCONTEXTINFOEXTPROC) (Display* dpy, GLXContext context, int attribute,int *value);
|
||||
|
||||
#define glXFreeContextEXT GLXEW_GET_FUN(__glewXFreeContextEXT)
|
||||
#define glXGetContextIDEXT GLXEW_GET_FUN(__glewXGetContextIDEXT)
|
||||
#define glXGetCurrentDisplayEXT GLXEW_GET_FUN(__glewXGetCurrentDisplayEXT)
|
||||
#define glXImportContextEXT GLXEW_GET_FUN(__glewXImportContextEXT)
|
||||
#define glXQueryContextInfoEXT GLXEW_GET_FUN(__glewXQueryContextInfoEXT)
|
||||
|
||||
@@ -702,26 +670,6 @@ typedef int ( * PFNGLXQUERYCONTEXTINFOEXTPROC) (Display* dpy, GLXContext context
|
||||
|
||||
#endif /* GLX_EXT_import_context */
|
||||
|
||||
/* ---------------------------- GLX_EXT_libglvnd --------------------------- */
|
||||
|
||||
#ifndef GLX_EXT_libglvnd
|
||||
#define GLX_EXT_libglvnd 1
|
||||
|
||||
#define GLX_VENDOR_NAMES_EXT 0x20F6
|
||||
|
||||
#define GLXEW_EXT_libglvnd GLXEW_GET_VAR(__GLXEW_EXT_libglvnd)
|
||||
|
||||
#endif /* GLX_EXT_libglvnd */
|
||||
|
||||
/* ----------------------- GLX_EXT_no_config_context ----------------------- */
|
||||
|
||||
#ifndef GLX_EXT_no_config_context
|
||||
#define GLX_EXT_no_config_context 1
|
||||
|
||||
#define GLXEW_EXT_no_config_context GLXEW_GET_VAR(__GLXEW_EXT_no_config_context)
|
||||
|
||||
#endif /* GLX_EXT_no_config_context */
|
||||
|
||||
/* -------------------------- GLX_EXT_scene_marker ------------------------- */
|
||||
|
||||
#ifndef GLX_EXT_scene_marker
|
||||
@@ -793,10 +741,8 @@ typedef void ( * PFNGLXSWAPINTERVALEXTPROC) (Display* dpy, GLXDrawable drawable,
|
||||
#define GLX_TEXTURE_1D_EXT 0x20DB
|
||||
#define GLX_TEXTURE_2D_EXT 0x20DC
|
||||
#define GLX_TEXTURE_RECTANGLE_EXT 0x20DD
|
||||
#define GLX_FRONT_EXT 0x20DE
|
||||
#define GLX_FRONT_LEFT_EXT 0x20DE
|
||||
#define GLX_FRONT_RIGHT_EXT 0x20DF
|
||||
#define GLX_BACK_EXT 0x20E0
|
||||
#define GLX_BACK_LEFT_EXT 0x20E0
|
||||
#define GLX_BACK_RIGHT_EXT 0x20E1
|
||||
#define GLX_AUX0_EXT 0x20E2
|
||||
@@ -810,8 +756,8 @@ typedef void ( * PFNGLXSWAPINTERVALEXTPROC) (Display* dpy, GLXDrawable drawable,
|
||||
#define GLX_AUX8_EXT 0x20EA
|
||||
#define GLX_AUX9_EXT 0x20EB
|
||||
|
||||
typedef void ( * PFNGLXBINDTEXIMAGEEXTPROC) (Display* dpy, GLXDrawable drawable, int buffer, const int* attrib_list);
|
||||
typedef void ( * PFNGLXRELEASETEXIMAGEEXTPROC) (Display* dpy, GLXDrawable drawable, int buffer);
|
||||
typedef void ( * PFNGLXBINDTEXIMAGEEXTPROC) (Display* display, GLXDrawable drawable, int buffer, const int *attrib_list);
|
||||
typedef void ( * PFNGLXRELEASETEXIMAGEEXTPROC) (Display* display, GLXDrawable drawable, int buffer);
|
||||
|
||||
#define glXBindTexImageEXT GLXEW_GET_FUN(__glewXBindTexImageEXT)
|
||||
#define glXReleaseTexImageEXT GLXEW_GET_FUN(__glewXReleaseTexImageEXT)
|
||||
@@ -904,7 +850,7 @@ typedef void ( * PFNGLXCOPYSUBBUFFERMESAPROC) (Display* dpy, GLXDrawable drawabl
|
||||
#ifndef GLX_MESA_pixmap_colormap
|
||||
#define GLX_MESA_pixmap_colormap 1
|
||||
|
||||
typedef GLXPixmap ( * PFNGLXCREATEGLXPIXMAPMESAPROC) (Display* dpy, XVisualInfo* visual, Pixmap pixmap, Colormap cmap);
|
||||
typedef GLXPixmap ( * PFNGLXCREATEGLXPIXMAPMESAPROC) (Display* dpy, XVisualInfo *visual, Pixmap pixmap, Colormap cmap);
|
||||
|
||||
#define glXCreateGLXPixmapMESA GLXEW_GET_FUN(__glewXCreateGLXPixmapMESA)
|
||||
|
||||
@@ -928,11 +874,12 @@ typedef GLXPixmap ( * PFNGLXCREATEGLXPIXMAPMESAPROC) (Display* dpy, XVisualInfo*
|
||||
#define GLX_RENDERER_OPENGL_COMPATIBILITY_PROFILE_VERSION_MESA 0x818B
|
||||
#define GLX_RENDERER_OPENGL_ES_PROFILE_VERSION_MESA 0x818C
|
||||
#define GLX_RENDERER_OPENGL_ES2_PROFILE_VERSION_MESA 0x818D
|
||||
#define GLX_RENDERER_ID_MESA 0x818E
|
||||
|
||||
typedef Bool ( * PFNGLXQUERYCURRENTRENDERERINTEGERMESAPROC) (int attribute, unsigned int* value);
|
||||
typedef const char* ( * PFNGLXQUERYCURRENTRENDERERSTRINGMESAPROC) (int attribute);
|
||||
typedef Bool ( * PFNGLXQUERYRENDERERINTEGERMESAPROC) (Display* dpy, int screen, int renderer, int attribute, unsigned int* value);
|
||||
typedef const char* ( * PFNGLXQUERYRENDERERSTRINGMESAPROC) (Display* dpy, int screen, int renderer, int attribute);
|
||||
typedef Bool ( * PFNGLXQUERYRENDERERINTEGERMESAPROC) (Display* dpy, int screen, int renderer, int attribute, unsigned int *value);
|
||||
typedef const char* ( * PFNGLXQUERYRENDERERSTRINGMESAPROC) (Display *dpy, int screen, int renderer, int attribute);
|
||||
|
||||
#define glXQueryCurrentRendererIntegerMESA GLXEW_GET_FUN(__glewXQueryCurrentRendererIntegerMESA)
|
||||
#define glXQueryCurrentRendererStringMESA GLXEW_GET_FUN(__glewXQueryCurrentRendererStringMESA)
|
||||
@@ -948,7 +895,7 @@ typedef const char* ( * PFNGLXQUERYRENDERERSTRINGMESAPROC) (Display* dpy, int sc
|
||||
#ifndef GLX_MESA_release_buffers
|
||||
#define GLX_MESA_release_buffers 1
|
||||
|
||||
typedef Bool ( * PFNGLXRELEASEBUFFERSMESAPROC) (Display* dpy, GLXDrawable drawable);
|
||||
typedef Bool ( * PFNGLXRELEASEBUFFERSMESAPROC) (Display* dpy, GLXDrawable d);
|
||||
|
||||
#define glXReleaseBuffersMESA GLXEW_GET_FUN(__glewXReleaseBuffersMESA)
|
||||
|
||||
@@ -1039,21 +986,6 @@ typedef Bool ( * PFNGLXDELAYBEFORESWAPNVPROC) (Display* dpy, GLXDrawable drawabl
|
||||
|
||||
#endif /* GLX_NV_float_buffer */
|
||||
|
||||
/* ------------------------ GLX_NV_multigpu_context ------------------------ */
|
||||
|
||||
#ifndef GLX_NV_multigpu_context
|
||||
#define GLX_NV_multigpu_context 1
|
||||
|
||||
#define GLX_CONTEXT_MULTIGPU_ATTRIB_NV 0x20AA
|
||||
#define GLX_CONTEXT_MULTIGPU_ATTRIB_SINGLE_NV 0x20AB
|
||||
#define GLX_CONTEXT_MULTIGPU_ATTRIB_AFR_NV 0x20AC
|
||||
#define GLX_CONTEXT_MULTIGPU_ATTRIB_MULTICAST_NV 0x20AD
|
||||
#define GLX_CONTEXT_MULTIGPU_ATTRIB_MULTI_DISPLAY_MULTICAST_NV 0x20AE
|
||||
|
||||
#define GLXEW_NV_multigpu_context GLXEW_GET_VAR(__GLXEW_NV_multigpu_context)
|
||||
|
||||
#endif /* GLX_NV_multigpu_context */
|
||||
|
||||
/* ---------------------- GLX_NV_multisample_coverage ---------------------- */
|
||||
|
||||
#ifndef GLX_NV_multisample_coverage
|
||||
@@ -1073,8 +1005,8 @@ typedef Bool ( * PFNGLXDELAYBEFORESWAPNVPROC) (Display* dpy, GLXDrawable drawabl
|
||||
|
||||
#define GLX_NUM_VIDEO_SLOTS_NV 0x20F0
|
||||
|
||||
typedef int ( * PFNGLXBINDVIDEODEVICENVPROC) (Display* dpy, unsigned int video_slot, unsigned int video_device, const int* attrib_list);
|
||||
typedef unsigned int* ( * PFNGLXENUMERATEVIDEODEVICESNVPROC) (Display* dpy, int screen, int* nelements);
|
||||
typedef int ( * PFNGLXBINDVIDEODEVICENVPROC) (Display* dpy, unsigned int video_slot, unsigned int video_device, const int *attrib_list);
|
||||
typedef unsigned int* ( * PFNGLXENUMERATEVIDEODEVICESNVPROC) (Display *dpy, int screen, int *nelements);
|
||||
|
||||
#define glXBindVideoDeviceNV GLXEW_GET_FUN(__glewXBindVideoDeviceNV)
|
||||
#define glXEnumerateVideoDevicesNV GLXEW_GET_FUN(__glewXEnumerateVideoDevicesNV)
|
||||
@@ -1083,17 +1015,6 @@ typedef unsigned int* ( * PFNGLXENUMERATEVIDEODEVICESNVPROC) (Display* dpy, int
|
||||
|
||||
#endif /* GLX_NV_present_video */
|
||||
|
||||
/* ------------------ GLX_NV_robustness_video_memory_purge ----------------- */
|
||||
|
||||
#ifndef GLX_NV_robustness_video_memory_purge
|
||||
#define GLX_NV_robustness_video_memory_purge 1
|
||||
|
||||
#define GLX_GENERATE_RESET_ON_VIDEO_MEMORY_PURGE_NV 0x20F7
|
||||
|
||||
#define GLXEW_NV_robustness_video_memory_purge GLXEW_GET_VAR(__GLXEW_NV_robustness_video_memory_purge)
|
||||
|
||||
#endif /* GLX_NV_robustness_video_memory_purge */
|
||||
|
||||
/* --------------------------- GLX_NV_swap_group --------------------------- */
|
||||
|
||||
#ifndef GLX_NV_swap_group
|
||||
@@ -1101,9 +1022,9 @@ typedef unsigned int* ( * PFNGLXENUMERATEVIDEODEVICESNVPROC) (Display* dpy, int
|
||||
|
||||
typedef Bool ( * PFNGLXBINDSWAPBARRIERNVPROC) (Display* dpy, GLuint group, GLuint barrier);
|
||||
typedef Bool ( * PFNGLXJOINSWAPGROUPNVPROC) (Display* dpy, GLXDrawable drawable, GLuint group);
|
||||
typedef Bool ( * PFNGLXQUERYFRAMECOUNTNVPROC) (Display* dpy, int screen, GLuint* count);
|
||||
typedef Bool ( * PFNGLXQUERYMAXSWAPGROUPSNVPROC) (Display* dpy, int screen, GLuint* maxGroups, GLuint* maxBarriers);
|
||||
typedef Bool ( * PFNGLXQUERYSWAPGROUPNVPROC) (Display* dpy, GLXDrawable drawable, GLuint* group, GLuint* barrier);
|
||||
typedef Bool ( * PFNGLXQUERYFRAMECOUNTNVPROC) (Display* dpy, int screen, GLuint *count);
|
||||
typedef Bool ( * PFNGLXQUERYMAXSWAPGROUPSNVPROC) (Display* dpy, int screen, GLuint *maxGroups, GLuint *maxBarriers);
|
||||
typedef Bool ( * PFNGLXQUERYSWAPGROUPNVPROC) (Display* dpy, GLXDrawable drawable, GLuint *group, GLuint *barrier);
|
||||
typedef Bool ( * PFNGLXRESETFRAMECOUNTNVPROC) (Display* dpy, int screen);
|
||||
|
||||
#define glXBindSwapBarrierNV GLXEW_GET_FUN(__glewXBindSwapBarrierNV)
|
||||
@@ -1144,9 +1065,9 @@ typedef void ( * PFNGLXFREEMEMORYNVPROC) (void *pointer);
|
||||
typedef XID GLXVideoCaptureDeviceNV;
|
||||
|
||||
typedef int ( * PFNGLXBINDVIDEOCAPTUREDEVICENVPROC) (Display* dpy, unsigned int video_capture_slot, GLXVideoCaptureDeviceNV device);
|
||||
typedef GLXVideoCaptureDeviceNV* ( * PFNGLXENUMERATEVIDEOCAPTUREDEVICESNVPROC) (Display* dpy, int screen, int* nelements);
|
||||
typedef GLXVideoCaptureDeviceNV * ( * PFNGLXENUMERATEVIDEOCAPTUREDEVICESNVPROC) (Display* dpy, int screen, int *nelements);
|
||||
typedef void ( * PFNGLXLOCKVIDEOCAPTUREDEVICENVPROC) (Display* dpy, GLXVideoCaptureDeviceNV device);
|
||||
typedef int ( * PFNGLXQUERYVIDEOCAPTUREDEVICENVPROC) (Display* dpy, GLXVideoCaptureDeviceNV device, int attribute, int* value);
|
||||
typedef int ( * PFNGLXQUERYVIDEOCAPTUREDEVICENVPROC) (Display* dpy, GLXVideoCaptureDeviceNV device, int attribute, int *value);
|
||||
typedef void ( * PFNGLXRELEASEVIDEOCAPTUREDEVICENVPROC) (Display* dpy, GLXVideoCaptureDeviceNV device);
|
||||
|
||||
#define glXBindVideoCaptureDeviceNV GLXEW_GET_FUN(__glewXBindVideoCaptureDeviceNV)
|
||||
@@ -1176,11 +1097,11 @@ typedef void ( * PFNGLXRELEASEVIDEOCAPTUREDEVICENVPROC) (Display* dpy, GLXVideoC
|
||||
#define GLX_VIDEO_OUT_STACKED_FIELDS_2_1_NV 0x20CC
|
||||
|
||||
typedef int ( * PFNGLXBINDVIDEOIMAGENVPROC) (Display* dpy, GLXVideoDeviceNV VideoDevice, GLXPbuffer pbuf, int iVideoBuffer);
|
||||
typedef int ( * PFNGLXGETVIDEODEVICENVPROC) (Display* dpy, int screen, int numVideoDevices, GLXVideoDeviceNV* pVideoDevice);
|
||||
typedef int ( * PFNGLXGETVIDEOINFONVPROC) (Display* dpy, int screen, GLXVideoDeviceNV VideoDevice, unsigned long* pulCounterOutputPbuffer, unsigned long* pulCounterOutputVideo);
|
||||
typedef int ( * PFNGLXGETVIDEODEVICENVPROC) (Display* dpy, int screen, int numVideoDevices, GLXVideoDeviceNV *pVideoDevice);
|
||||
typedef int ( * PFNGLXGETVIDEOINFONVPROC) (Display* dpy, int screen, GLXVideoDeviceNV VideoDevice, unsigned long *pulCounterOutputPbuffer, unsigned long *pulCounterOutputVideo);
|
||||
typedef int ( * PFNGLXRELEASEVIDEODEVICENVPROC) (Display* dpy, int screen, GLXVideoDeviceNV VideoDevice);
|
||||
typedef int ( * PFNGLXRELEASEVIDEOIMAGENVPROC) (Display* dpy, GLXPbuffer pbuf);
|
||||
typedef int ( * PFNGLXSENDPBUFFERTOVIDEONVPROC) (Display* dpy, GLXPbuffer pbuf, int iBufferType, unsigned long* pulCounterPbuffer, GLboolean bBlock);
|
||||
typedef int ( * PFNGLXSENDPBUFFERTOVIDEONVPROC) (Display* dpy, GLXPbuffer pbuf, int iBufferType, unsigned long *pulCounterPbuffer, GLboolean bBlock);
|
||||
|
||||
#define glXBindVideoImageNV GLXEW_GET_FUN(__glewXBindVideoImageNV)
|
||||
#define glXGetVideoDeviceNV GLXEW_GET_FUN(__glewXGetVideoDeviceNV)
|
||||
@@ -1292,12 +1213,12 @@ typedef Bool ( * PFNGLXWAITFORSBCOMLPROC) (Display* dpy, GLXDrawable drawable, i
|
||||
typedef XID GLXFBConfigIDSGIX;
|
||||
typedef struct __GLXFBConfigRec *GLXFBConfigSGIX;
|
||||
|
||||
typedef GLXFBConfigSGIX* ( * PFNGLXCHOOSEFBCONFIGSGIXPROC) (Display* dpy, int screen, int* attrib_list, int* nelements);
|
||||
typedef GLXContext ( * PFNGLXCREATECONTEXTWITHCONFIGSGIXPROC) (Display* dpy, GLXFBConfigSGIX config, int render_type, GLXContext share_list, Bool direct);
|
||||
typedef GLXPixmap ( * PFNGLXCREATEGLXPIXMAPWITHCONFIGSGIXPROC) (Display* dpy, GLXFBConfigSGIX config, Pixmap pixmap);
|
||||
typedef int ( * PFNGLXGETFBCONFIGATTRIBSGIXPROC) (Display* dpy, GLXFBConfigSGIX config, int attribute, int* value);
|
||||
typedef GLXFBConfigSGIX ( * PFNGLXGETFBCONFIGFROMVISUALSGIXPROC) (Display* dpy, XVisualInfo* vis);
|
||||
typedef XVisualInfo* ( * PFNGLXGETVISUALFROMFBCONFIGSGIXPROC) (Display* dpy, GLXFBConfigSGIX config);
|
||||
typedef GLXFBConfigSGIX* ( * PFNGLXCHOOSEFBCONFIGSGIXPROC) (Display *dpy, int screen, const int *attrib_list, int *nelements);
|
||||
typedef GLXContext ( * PFNGLXCREATECONTEXTWITHCONFIGSGIXPROC) (Display* dpy, GLXFBConfig config, int render_type, GLXContext share_list, Bool direct);
|
||||
typedef GLXPixmap ( * PFNGLXCREATEGLXPIXMAPWITHCONFIGSGIXPROC) (Display* dpy, GLXFBConfig config, Pixmap pixmap);
|
||||
typedef int ( * PFNGLXGETFBCONFIGATTRIBSGIXPROC) (Display* dpy, GLXFBConfigSGIX config, int attribute, int *value);
|
||||
typedef GLXFBConfigSGIX ( * PFNGLXGETFBCONFIGFROMVISUALSGIXPROC) (Display* dpy, XVisualInfo *vis);
|
||||
typedef XVisualInfo* ( * PFNGLXGETVISUALFROMFBCONFIGSGIXPROC) (Display *dpy, GLXFBConfig config);
|
||||
|
||||
#define glXChooseFBConfigSGIX GLXEW_GET_FUN(__glewXChooseFBConfigSGIX)
|
||||
#define glXCreateContextWithConfigSGIX GLXEW_GET_FUN(__glewXCreateContextWithConfigSGIX)
|
||||
@@ -1411,10 +1332,10 @@ typedef GLXHyperpipeNetworkSGIX * ( * PFNGLXQUERYHYPERPIPENETWORKSGIXPROC) (Disp
|
||||
typedef XID GLXPbufferSGIX;
|
||||
typedef struct { int type; unsigned long serial; Bool send_event; Display *display; GLXDrawable drawable; int event_type; int draw_type; unsigned int mask; int x, y; int width, height; int count; } GLXBufferClobberEventSGIX;
|
||||
|
||||
typedef GLXPbufferSGIX ( * PFNGLXCREATEGLXPBUFFERSGIXPROC) (Display* dpy, GLXFBConfigSGIX config, unsigned int width, unsigned int height, int* attrib_list);
|
||||
typedef void ( * PFNGLXDESTROYGLXPBUFFERSGIXPROC) (Display* dpy, GLXPbufferSGIX pbuf);
|
||||
typedef void ( * PFNGLXGETSELECTEDEVENTSGIXPROC) (Display* dpy, GLXDrawable drawable, unsigned long* mask);
|
||||
typedef void ( * PFNGLXQUERYGLXPBUFFERSGIXPROC) (Display* dpy, GLXPbufferSGIX pbuf, int attribute, unsigned int* value);
|
||||
typedef GLXPbuffer ( * PFNGLXCREATEGLXPBUFFERSGIXPROC) (Display* dpy, GLXFBConfig config, unsigned int width, unsigned int height, int *attrib_list);
|
||||
typedef void ( * PFNGLXDESTROYGLXPBUFFERSGIXPROC) (Display* dpy, GLXPbuffer pbuf);
|
||||
typedef void ( * PFNGLXGETSELECTEDEVENTSGIXPROC) (Display* dpy, GLXDrawable drawable, unsigned long *mask);
|
||||
typedef void ( * PFNGLXQUERYGLXPBUFFERSGIXPROC) (Display* dpy, GLXPbuffer pbuf, int attribute, unsigned int *value);
|
||||
typedef void ( * PFNGLXSELECTEVENTSGIXPROC) (Display* dpy, GLXDrawable drawable, unsigned long mask);
|
||||
|
||||
#define glXCreateGLXPbufferSGIX GLXEW_GET_FUN(__glewXCreateGLXPbufferSGIX)
|
||||
@@ -1432,8 +1353,8 @@ typedef void ( * PFNGLXSELECTEVENTSGIXPROC) (Display* dpy, GLXDrawable drawable,
|
||||
#ifndef GLX_SGIX_swap_barrier
|
||||
#define GLX_SGIX_swap_barrier 1
|
||||
|
||||
typedef void ( * PFNGLXBINDSWAPBARRIERSGIXPROC) (Display* dpy, GLXDrawable drawable, int barrier);
|
||||
typedef Bool ( * PFNGLXQUERYMAXSWAPBARRIERSSGIXPROC) (Display* dpy, int screen, int* max);
|
||||
typedef void ( * PFNGLXBINDSWAPBARRIERSGIXPROC) (Display *dpy, GLXDrawable drawable, int barrier);
|
||||
typedef Bool ( * PFNGLXQUERYMAXSWAPBARRIERSSGIXPROC) (Display *dpy, int screen, int *max);
|
||||
|
||||
#define glXBindSwapBarrierSGIX GLXEW_GET_FUN(__glewXBindSwapBarrierSGIX)
|
||||
#define glXQueryMaxSwapBarriersSGIX GLXEW_GET_FUN(__glewXQueryMaxSwapBarriersSGIX)
|
||||
@@ -1447,7 +1368,7 @@ typedef Bool ( * PFNGLXQUERYMAXSWAPBARRIERSSGIXPROC) (Display* dpy, int screen,
|
||||
#ifndef GLX_SGIX_swap_group
|
||||
#define GLX_SGIX_swap_group 1
|
||||
|
||||
typedef void ( * PFNGLXJOINSWAPGROUPSGIXPROC) (Display* dpy, GLXDrawable drawable, GLXDrawable member);
|
||||
typedef void ( * PFNGLXJOINSWAPGROUPSGIXPROC) (Display *dpy, GLXDrawable drawable, GLXDrawable member);
|
||||
|
||||
#define glXJoinSwapGroupSGIX GLXEW_GET_FUN(__glewXJoinSwapGroupSGIX)
|
||||
|
||||
@@ -1466,8 +1387,8 @@ typedef void ( * PFNGLXJOINSWAPGROUPSGIXPROC) (Display* dpy, GLXDrawable drawabl
|
||||
typedef int ( * PFNGLXBINDCHANNELTOWINDOWSGIXPROC) (Display* display, int screen, int channel, Window window);
|
||||
typedef int ( * PFNGLXCHANNELRECTSGIXPROC) (Display* display, int screen, int channel, int x, int y, int w, int h);
|
||||
typedef int ( * PFNGLXCHANNELRECTSYNCSGIXPROC) (Display* display, int screen, int channel, GLenum synctype);
|
||||
typedef int ( * PFNGLXQUERYCHANNELDELTASSGIXPROC) (Display* display, int screen, int channel, int* x, int* y, int* w, int* h);
|
||||
typedef int ( * PFNGLXQUERYCHANNELRECTSGIXPROC) (Display* display, int screen, int channel, int* dx, int* dy, int* dw, int* dh);
|
||||
typedef int ( * PFNGLXQUERYCHANNELDELTASSGIXPROC) (Display* display, int screen, int channel, int *x, int *y, int *w, int *h);
|
||||
typedef int ( * PFNGLXQUERYCHANNELRECTSGIXPROC) (Display* display, int screen, int channel, int *dx, int *dy, int *dw, int *dh);
|
||||
|
||||
#define glXBindChannelToWindowSGIX GLXEW_GET_FUN(__glewXBindChannelToWindowSGIX)
|
||||
#define glXChannelRectSGIX GLXEW_GET_FUN(__glewXChannelRectSGIX)
|
||||
@@ -1551,7 +1472,7 @@ typedef int ( * PFNGLXWAITVIDEOSYNCSGIPROC) (int divisor, int remainder, unsigne
|
||||
#ifndef GLX_SUN_get_transparent_index
|
||||
#define GLX_SUN_get_transparent_index 1
|
||||
|
||||
typedef Status ( * PFNGLXGETTRANSPARENTINDEXSUNPROC) (Display* dpy, Window overlay, Window underlay, unsigned long* pTransparentIndex);
|
||||
typedef Status ( * PFNGLXGETTRANSPARENTINDEXSUNPROC) (Display* dpy, Window overlay, Window underlay, unsigned long *pTransparentIndex);
|
||||
|
||||
#define glXGetTransparentIndexSUN GLXEW_GET_FUN(__glewXGetTransparentIndexSUN)
|
||||
|
||||
@@ -1579,8 +1500,13 @@ typedef int ( * PFNGLXVIDEORESIZESUNPROC) (Display* display, GLXDrawable window,
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
#ifdef GLEW_MX
|
||||
#define GLXEW_FUN_EXPORT GLEW_FUN_EXPORT
|
||||
#define GLXEW_VAR_EXPORT
|
||||
#else
|
||||
#define GLXEW_FUN_EXPORT GLEW_FUN_EXPORT
|
||||
#define GLXEW_VAR_EXPORT GLEW_VAR_EXPORT
|
||||
#endif /* GLEW_MX */
|
||||
|
||||
GLXEW_FUN_EXPORT PFNGLXGETCURRENTDISPLAYPROC __glewXGetCurrentDisplay;
|
||||
|
||||
@@ -1620,7 +1546,6 @@ GLXEW_FUN_EXPORT PFNGLXRELEASETEXIMAGEATIPROC __glewXReleaseTexImageATI;
|
||||
|
||||
GLXEW_FUN_EXPORT PFNGLXFREECONTEXTEXTPROC __glewXFreeContextEXT;
|
||||
GLXEW_FUN_EXPORT PFNGLXGETCONTEXTIDEXTPROC __glewXGetContextIDEXT;
|
||||
GLXEW_FUN_EXPORT PFNGLXGETCURRENTDISPLAYEXTPROC __glewXGetCurrentDisplayEXT;
|
||||
GLXEW_FUN_EXPORT PFNGLXIMPORTCONTEXTEXTPROC __glewXImportContextEXT;
|
||||
GLXEW_FUN_EXPORT PFNGLXQUERYCONTEXTINFOEXTPROC __glewXQueryContextInfoEXT;
|
||||
|
||||
@@ -1733,6 +1658,12 @@ GLXEW_FUN_EXPORT PFNGLXGETTRANSPARENTINDEXSUNPROC __glewXGetTransparentIndexSUN;
|
||||
|
||||
GLXEW_FUN_EXPORT PFNGLXGETVIDEORESIZESUNPROC __glewXGetVideoResizeSUN;
|
||||
GLXEW_FUN_EXPORT PFNGLXVIDEORESIZESUNPROC __glewXVideoResizeSUN;
|
||||
|
||||
#if defined(GLEW_MX)
|
||||
struct GLXEWContextStruct
|
||||
{
|
||||
#endif /* GLEW_MX */
|
||||
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_VERSION_1_0;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_VERSION_1_1;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_VERSION_1_2;
|
||||
@@ -1742,7 +1673,6 @@ GLXEW_VAR_EXPORT GLboolean __GLXEW_3DFX_multisample;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_AMD_gpu_association;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_ARB_context_flush_control;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_ARB_create_context;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_ARB_create_context_no_error;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_ARB_create_context_profile;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_ARB_create_context_robustness;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_ARB_fbconfig_float;
|
||||
@@ -1755,14 +1685,11 @@ GLXEW_VAR_EXPORT GLboolean __GLXEW_ARB_vertex_buffer_object;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_ATI_pixel_format_float;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_ATI_render_texture;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_buffer_age;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_context_priority;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_create_context_es2_profile;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_create_context_es_profile;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_fbconfig_packed_float;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_framebuffer_sRGB;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_import_context;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_libglvnd;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_no_config_context;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_scene_marker;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_stereo_tree;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_EXT_swap_control;
|
||||
@@ -1782,10 +1709,8 @@ GLXEW_VAR_EXPORT GLboolean __GLXEW_NV_copy_buffer;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_NV_copy_image;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_NV_delay_before_swap;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_NV_float_buffer;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_NV_multigpu_context;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_NV_multisample_coverage;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_NV_present_video;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_NV_robustness_video_memory_purge;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_NV_swap_group;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_NV_vertex_array_range;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_NV_video_capture;
|
||||
@@ -1809,18 +1734,34 @@ GLXEW_VAR_EXPORT GLboolean __GLXEW_SGI_swap_control;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_SGI_video_sync;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_SUN_get_transparent_index;
|
||||
GLXEW_VAR_EXPORT GLboolean __GLXEW_SUN_video_resize;
|
||||
|
||||
#ifdef GLEW_MX
|
||||
}; /* GLXEWContextStruct */
|
||||
#endif /* GLEW_MX */
|
||||
|
||||
/* ------------------------------------------------------------------------ */
|
||||
|
||||
#ifdef GLEW_MX
|
||||
|
||||
typedef struct GLXEWContextStruct GLXEWContext;
|
||||
GLEWAPI GLenum GLEWAPIENTRY glxewContextInit (GLXEWContext *ctx);
|
||||
GLEWAPI GLboolean GLEWAPIENTRY glxewContextIsSupported (const GLXEWContext *ctx, const char *name);
|
||||
|
||||
#define glxewInit() glxewContextInit(glxewGetContext())
|
||||
#define glxewIsSupported(x) glxewContextIsSupported(glxewGetContext(), x)
|
||||
|
||||
#define GLXEW_GET_VAR(x) (*(const GLboolean*)&(glxewGetContext()->x))
|
||||
#define GLXEW_GET_FUN(x) x
|
||||
|
||||
#else /* GLEW_MX */
|
||||
|
||||
GLEWAPI GLenum GLEWAPIENTRY glxewInit ();
|
||||
GLEWAPI GLboolean GLEWAPIENTRY glxewIsSupported (const char *name);
|
||||
|
||||
#ifndef GLXEW_GET_VAR
|
||||
#define GLXEW_GET_VAR(x) (*(const GLboolean*)&x)
|
||||
#endif
|
||||
|
||||
#ifndef GLXEW_GET_FUN
|
||||
#define GLXEW_GET_FUN(x) x
|
||||
#endif
|
||||
|
||||
#endif /* GLEW_MX */
|
||||
|
||||
GLEWAPI GLboolean GLEWAPIENTRY glxewGetExtension (const char *name);
|
||||
|
||||
|
||||
152
deps/GLEW/glew/include/GL/wglew.h
vendored
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
** The OpenGL Extension Wrangler Library
|
||||
** Copyright (C) 2008-2019, Nigel Stewart <nigels[]users sourceforge net>
|
||||
** Copyright (C) 2008-2015, Nigel Stewart <nigels[]users sourceforge net>
|
||||
** Copyright (C) 2002-2008, Milan Ikits <milan ikits[]ieee org>
|
||||
** Copyright (C) 2002-2008, Marcelo E. Magallon <mmagallo[]debian org>
|
||||
** Copyright (C) 2002, Lev Povalahev
|
||||
@@ -67,6 +67,9 @@
|
||||
# ifndef WIN32_LEAN_AND_MEAN
|
||||
# define WIN32_LEAN_AND_MEAN 1
|
||||
# endif
|
||||
# ifdef NOGDI
|
||||
# undef NOGDI
|
||||
# endif
|
||||
#include <windows.h>
|
||||
# undef WIN32_LEAN_AND_MEAN
|
||||
#endif
|
||||
@@ -188,7 +191,7 @@ typedef BOOL (WINAPI * PFNWGLSAVEBUFFERREGIONARBPROC) (HANDLE hRegion, int x, in
|
||||
#ifndef WGL_ARB_context_flush_control
|
||||
#define WGL_ARB_context_flush_control 1
|
||||
|
||||
#define WGL_CONTEXT_RELEASE_BEHAVIOR_NONE_ARB 0
|
||||
#define WGL_CONTEXT_RELEASE_BEHAVIOR_NONE_ARB 0x0000
|
||||
#define WGL_CONTEXT_RELEASE_BEHAVIOR_ARB 0x2097
|
||||
#define WGL_CONTEXT_RELEASE_BEHAVIOR_FLUSH_ARB 0x2098
|
||||
|
||||
@@ -201,13 +204,14 @@ typedef BOOL (WINAPI * PFNWGLSAVEBUFFERREGIONARBPROC) (HANDLE hRegion, int x, in
|
||||
#ifndef WGL_ARB_create_context
|
||||
#define WGL_ARB_create_context 1
|
||||
|
||||
#define WGL_CONTEXT_DEBUG_BIT_ARB 0x00000001
|
||||
#define WGL_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB 0x00000002
|
||||
#define WGL_CONTEXT_DEBUG_BIT_ARB 0x0001
|
||||
#define WGL_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB 0x0002
|
||||
#define WGL_CONTEXT_MAJOR_VERSION_ARB 0x2091
|
||||
#define WGL_CONTEXT_MINOR_VERSION_ARB 0x2092
|
||||
#define WGL_CONTEXT_LAYER_PLANE_ARB 0x2093
|
||||
#define WGL_CONTEXT_FLAGS_ARB 0x2094
|
||||
#define ERROR_INVALID_VERSION_ARB 0x2095
|
||||
#define ERROR_INVALID_PROFILE_ARB 0x2096
|
||||
|
||||
typedef HGLRC (WINAPI * PFNWGLCREATECONTEXTATTRIBSARBPROC) (HDC hDC, HGLRC hShareContext, const int* attribList);
|
||||
|
||||
@@ -217,17 +221,6 @@ typedef HGLRC (WINAPI * PFNWGLCREATECONTEXTATTRIBSARBPROC) (HDC hDC, HGLRC hShar
|
||||
|
||||
#endif /* WGL_ARB_create_context */
|
||||
|
||||
/* -------------------- WGL_ARB_create_context_no_error -------------------- */
|
||||
|
||||
#ifndef WGL_ARB_create_context_no_error
|
||||
#define WGL_ARB_create_context_no_error 1
|
||||
|
||||
#define WGL_CONTEXT_OPENGL_NO_ERROR_ARB 0x31B3
|
||||
|
||||
#define WGLEW_ARB_create_context_no_error WGLEW_GET_VAR(__WGLEW_ARB_create_context_no_error)
|
||||
|
||||
#endif /* WGL_ARB_create_context_no_error */
|
||||
|
||||
/* --------------------- WGL_ARB_create_context_profile -------------------- */
|
||||
|
||||
#ifndef WGL_ARB_create_context_profile
|
||||
@@ -235,7 +228,6 @@ typedef HGLRC (WINAPI * PFNWGLCREATECONTEXTATTRIBSARBPROC) (HDC hDC, HGLRC hShar
|
||||
|
||||
#define WGL_CONTEXT_CORE_PROFILE_BIT_ARB 0x00000001
|
||||
#define WGL_CONTEXT_COMPATIBILITY_PROFILE_BIT_ARB 0x00000002
|
||||
#define ERROR_INVALID_PROFILE_ARB 0x2096
|
||||
#define WGL_CONTEXT_PROFILE_MASK_ARB 0x9126
|
||||
|
||||
#define WGLEW_ARB_create_context_profile WGLEW_GET_VAR(__WGLEW_ARB_create_context_profile)
|
||||
@@ -288,7 +280,7 @@ typedef const char* (WINAPI * PFNWGLGETEXTENSIONSSTRINGARBPROC) (HDC hdc);
|
||||
#define ERROR_INVALID_PIXEL_TYPE_ARB 0x2043
|
||||
#define ERROR_INCOMPATIBLE_DEVICE_CONTEXTS_ARB 0x2054
|
||||
|
||||
typedef HDC (WINAPI * PFNWGLGETCURRENTREADDCARBPROC) (void);
|
||||
typedef HDC (WINAPI * PFNWGLGETCURRENTREADDCARBPROC) (VOID);
|
||||
typedef BOOL (WINAPI * PFNWGLMAKECONTEXTCURRENTARBPROC) (HDC hDrawDC, HDC hReadDC, HGLRC hglrc);
|
||||
|
||||
#define wglGetCurrentReadDCARB WGLEW_GET_FUN(__wglewGetCurrentReadDCARB)
|
||||
@@ -397,9 +389,9 @@ typedef int (WINAPI * PFNWGLRELEASEPBUFFERDCARBPROC) (HPBUFFERARB hPbuffer, HDC
|
||||
#define WGL_TRANSPARENT_ALPHA_VALUE_ARB 0x203A
|
||||
#define WGL_TRANSPARENT_INDEX_VALUE_ARB 0x203B
|
||||
|
||||
typedef BOOL (WINAPI * PFNWGLCHOOSEPIXELFORMATARBPROC) (HDC hdc, const int* piAttribIList, const FLOAT* pfAttribFList, UINT nMaxFormats, int* piFormats, UINT* nNumFormats);
|
||||
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBFVARBPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int* piAttributes, FLOAT* pfValues);
|
||||
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBIVARBPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int* piAttributes, int* piValues);
|
||||
typedef BOOL (WINAPI * PFNWGLCHOOSEPIXELFORMATARBPROC) (HDC hdc, const int* piAttribIList, const FLOAT *pfAttribFList, UINT nMaxFormats, int *piFormats, UINT *nNumFormats);
|
||||
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBFVARBPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int* piAttributes, FLOAT *pfValues);
|
||||
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBIVARBPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int* piAttributes, int *piValues);
|
||||
|
||||
#define wglChoosePixelFormatARB WGLEW_GET_FUN(__wglewChoosePixelFormatARB)
|
||||
#define wglGetPixelFormatAttribfvARB WGLEW_GET_FUN(__wglewGetPixelFormatAttribfvARB)
|
||||
@@ -517,19 +509,6 @@ typedef BOOL (WINAPI * PFNWGLSETPBUFFERATTRIBARBPROC) (HPBUFFERARB hPbuffer, con
|
||||
|
||||
#endif /* WGL_ATI_render_texture_rectangle */
|
||||
|
||||
/* --------------------------- WGL_EXT_colorspace -------------------------- */
|
||||
|
||||
#ifndef WGL_EXT_colorspace
|
||||
#define WGL_EXT_colorspace 1
|
||||
|
||||
#define WGL_COLORSPACE_SRGB_EXT 0x3089
|
||||
#define WGL_COLORSPACE_LINEAR_EXT 0x308A
|
||||
#define WGL_COLORSPACE_EXT 0x309D
|
||||
|
||||
#define WGLEW_EXT_colorspace WGLEW_GET_VAR(__WGLEW_EXT_colorspace)
|
||||
|
||||
#endif /* WGL_EXT_colorspace */
|
||||
|
||||
/* ------------------- WGL_EXT_create_context_es2_profile ------------------ */
|
||||
|
||||
#ifndef WGL_EXT_create_context_es2_profile
|
||||
@@ -570,8 +549,8 @@ typedef BOOL (WINAPI * PFNWGLSETPBUFFERATTRIBARBPROC) (HPBUFFERARB hPbuffer, con
|
||||
|
||||
typedef GLboolean (WINAPI * PFNWGLBINDDISPLAYCOLORTABLEEXTPROC) (GLushort id);
|
||||
typedef GLboolean (WINAPI * PFNWGLCREATEDISPLAYCOLORTABLEEXTPROC) (GLushort id);
|
||||
typedef VOID (WINAPI * PFNWGLDESTROYDISPLAYCOLORTABLEEXTPROC) (GLushort id);
|
||||
typedef GLboolean (WINAPI * PFNWGLLOADDISPLAYCOLORTABLEEXTPROC) (const GLushort* table, GLuint length);
|
||||
typedef void (WINAPI * PFNWGLDESTROYDISPLAYCOLORTABLEEXTPROC) (GLushort id);
|
||||
typedef GLboolean (WINAPI * PFNWGLLOADDISPLAYCOLORTABLEEXTPROC) (GLushort* table, GLuint length);
|
||||
|
||||
#define wglBindDisplayColorTableEXT WGLEW_GET_FUN(__wglewBindDisplayColorTableEXT)
|
||||
#define wglCreateDisplayColorTableEXT WGLEW_GET_FUN(__wglewCreateDisplayColorTableEXT)
|
||||
@@ -613,7 +592,7 @@ typedef const char* (WINAPI * PFNWGLGETEXTENSIONSSTRINGEXTPROC) (void);
|
||||
|
||||
#define ERROR_INVALID_PIXEL_TYPE_EXT 0x2043
|
||||
|
||||
typedef HDC (WINAPI * PFNWGLGETCURRENTREADDCEXTPROC) (void);
|
||||
typedef HDC (WINAPI * PFNWGLGETCURRENTREADDCEXTPROC) (VOID);
|
||||
typedef BOOL (WINAPI * PFNWGLMAKECONTEXTCURRENTEXTPROC) (HDC hDrawDC, HDC hReadDC, HGLRC hglrc);
|
||||
|
||||
#define wglGetCurrentReadDCEXT WGLEW_GET_FUN(__wglewGetCurrentReadDCEXT)
|
||||
@@ -719,9 +698,9 @@ typedef int (WINAPI * PFNWGLRELEASEPBUFFERDCEXTPROC) (HPBUFFEREXT hPbuffer, HDC
|
||||
#define WGL_TYPE_RGBA_EXT 0x202B
|
||||
#define WGL_TYPE_COLORINDEX_EXT 0x202C
|
||||
|
||||
typedef BOOL (WINAPI * PFNWGLCHOOSEPIXELFORMATEXTPROC) (HDC hdc, const int* piAttribIList, const FLOAT* pfAttribFList, UINT nMaxFormats, int* piFormats, UINT* nNumFormats);
|
||||
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBFVEXTPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int* piAttributes, FLOAT* pfValues);
|
||||
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBIVEXTPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int* piAttributes, int* piValues);
|
||||
typedef BOOL (WINAPI * PFNWGLCHOOSEPIXELFORMATEXTPROC) (HDC hdc, const int* piAttribIList, const FLOAT *pfAttribFList, UINT nMaxFormats, int *piFormats, UINT *nNumFormats);
|
||||
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBFVEXTPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int* piAttributes, FLOAT *pfValues);
|
||||
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBIVEXTPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int* piAttributes, int *piValues);
|
||||
|
||||
#define wglChoosePixelFormatEXT WGLEW_GET_FUN(__wglewChoosePixelFormatEXT)
|
||||
#define wglGetPixelFormatAttribfvEXT WGLEW_GET_FUN(__wglewGetPixelFormatAttribfvEXT)
|
||||
@@ -794,9 +773,9 @@ typedef BOOL (WINAPI * PFNWGLSETDIGITALVIDEOPARAMETERSI3DPROC) (HDC hDC, int iAt
|
||||
#define WGL_GAMMA_TABLE_SIZE_I3D 0x204E
|
||||
#define WGL_GAMMA_EXCLUDE_DESKTOP_I3D 0x204F
|
||||
|
||||
typedef BOOL (WINAPI * PFNWGLGETGAMMATABLEI3DPROC) (HDC hDC, int iEntries, USHORT* puRed, USHORT* puGreen, USHORT* puBlue);
|
||||
typedef BOOL (WINAPI * PFNWGLGETGAMMATABLEI3DPROC) (HDC hDC, int iEntries, USHORT* puRed, USHORT *puGreen, USHORT *puBlue);
|
||||
typedef BOOL (WINAPI * PFNWGLGETGAMMATABLEPARAMETERSI3DPROC) (HDC hDC, int iAttribute, int* piValue);
|
||||
typedef BOOL (WINAPI * PFNWGLSETGAMMATABLEI3DPROC) (HDC hDC, int iEntries, const USHORT* puRed, const USHORT* puGreen, const USHORT* puBlue);
|
||||
typedef BOOL (WINAPI * PFNWGLSETGAMMATABLEI3DPROC) (HDC hDC, int iEntries, const USHORT* puRed, const USHORT *puGreen, const USHORT *puBlue);
|
||||
typedef BOOL (WINAPI * PFNWGLSETGAMMATABLEPARAMETERSI3DPROC) (HDC hDC, int iAttribute, const int* piValue);
|
||||
|
||||
#define wglGetGammaTableI3D WGLEW_GET_FUN(__wglewGetGammaTableI3D)
|
||||
@@ -834,7 +813,7 @@ typedef BOOL (WINAPI * PFNWGLGETGENLOCKSOURCEDELAYI3DPROC) (HDC hDC, UINT* uDela
|
||||
typedef BOOL (WINAPI * PFNWGLGETGENLOCKSOURCEEDGEI3DPROC) (HDC hDC, UINT* uEdge);
|
||||
typedef BOOL (WINAPI * PFNWGLGETGENLOCKSOURCEI3DPROC) (HDC hDC, UINT* uSource);
|
||||
typedef BOOL (WINAPI * PFNWGLISENABLEDGENLOCKI3DPROC) (HDC hDC, BOOL* pFlag);
|
||||
typedef BOOL (WINAPI * PFNWGLQUERYGENLOCKMAXSOURCEDELAYI3DPROC) (HDC hDC, UINT* uMaxLineDelay, UINT* uMaxPixelDelay);
|
||||
typedef BOOL (WINAPI * PFNWGLQUERYGENLOCKMAXSOURCEDELAYI3DPROC) (HDC hDC, UINT* uMaxLineDelay, UINT *uMaxPixelDelay);
|
||||
|
||||
#define wglDisableGenlockI3D WGLEW_GET_FUN(__wglewDisableGenlockI3D)
|
||||
#define wglEnableGenlockI3D WGLEW_GET_FUN(__wglewEnableGenlockI3D)
|
||||
@@ -861,10 +840,10 @@ typedef BOOL (WINAPI * PFNWGLQUERYGENLOCKMAXSOURCEDELAYI3DPROC) (HDC hDC, UINT*
|
||||
#define WGL_IMAGE_BUFFER_MIN_ACCESS_I3D 0x00000001
|
||||
#define WGL_IMAGE_BUFFER_LOCK_I3D 0x00000002
|
||||
|
||||
typedef BOOL (WINAPI * PFNWGLASSOCIATEIMAGEBUFFEREVENTSI3DPROC) (HDC hDC, const HANDLE* pEvent, const LPVOID* pAddress, const DWORD* pSize, UINT count);
|
||||
typedef BOOL (WINAPI * PFNWGLASSOCIATEIMAGEBUFFEREVENTSI3DPROC) (HDC hdc, HANDLE* pEvent, LPVOID *pAddress, DWORD *pSize, UINT count);
|
||||
typedef LPVOID (WINAPI * PFNWGLCREATEIMAGEBUFFERI3DPROC) (HDC hDC, DWORD dwSize, UINT uFlags);
|
||||
typedef BOOL (WINAPI * PFNWGLDESTROYIMAGEBUFFERI3DPROC) (HDC hDC, LPVOID pAddress);
|
||||
typedef BOOL (WINAPI * PFNWGLRELEASEIMAGEBUFFEREVENTSI3DPROC) (HDC hDC, const LPVOID* pAddress, UINT count);
|
||||
typedef BOOL (WINAPI * PFNWGLRELEASEIMAGEBUFFEREVENTSI3DPROC) (HDC hdc, LPVOID* pAddress, UINT count);
|
||||
|
||||
#define wglAssociateImageBufferEventsI3D WGLEW_GET_FUN(__wglewAssociateImageBufferEventsI3D)
|
||||
#define wglCreateImageBufferI3D WGLEW_GET_FUN(__wglewCreateImageBufferI3D)
|
||||
@@ -880,8 +859,8 @@ typedef BOOL (WINAPI * PFNWGLRELEASEIMAGEBUFFEREVENTSI3DPROC) (HDC hDC, const LP
|
||||
#ifndef WGL_I3D_swap_frame_lock
|
||||
#define WGL_I3D_swap_frame_lock 1
|
||||
|
||||
typedef BOOL (WINAPI * PFNWGLDISABLEFRAMELOCKI3DPROC) (void);
|
||||
typedef BOOL (WINAPI * PFNWGLENABLEFRAMELOCKI3DPROC) (void);
|
||||
typedef BOOL (WINAPI * PFNWGLDISABLEFRAMELOCKI3DPROC) (VOID);
|
||||
typedef BOOL (WINAPI * PFNWGLENABLEFRAMELOCKI3DPROC) (VOID);
|
||||
typedef BOOL (WINAPI * PFNWGLISENABLEDFRAMELOCKI3DPROC) (BOOL* pFlag);
|
||||
typedef BOOL (WINAPI * PFNWGLQUERYFRAMELOCKMASTERI3DPROC) (BOOL* pFlag);
|
||||
|
||||
@@ -902,7 +881,7 @@ typedef BOOL (WINAPI * PFNWGLQUERYFRAMELOCKMASTERI3DPROC) (BOOL* pFlag);
|
||||
typedef BOOL (WINAPI * PFNWGLBEGINFRAMETRACKINGI3DPROC) (void);
|
||||
typedef BOOL (WINAPI * PFNWGLENDFRAMETRACKINGI3DPROC) (void);
|
||||
typedef BOOL (WINAPI * PFNWGLGETFRAMEUSAGEI3DPROC) (float* pUsage);
|
||||
typedef BOOL (WINAPI * PFNWGLQUERYFRAMETRACKINGI3DPROC) (DWORD* pFrameCount, DWORD* pMissedFrames, float* pLastMissedUsage);
|
||||
typedef BOOL (WINAPI * PFNWGLQUERYFRAMETRACKINGI3DPROC) (DWORD* pFrameCount, DWORD *pMissedFrames, float *pLastMissedUsage);
|
||||
|
||||
#define wglBeginFrameTrackingI3D WGLEW_GET_FUN(__wglewBeginFrameTrackingI3D)
|
||||
#define wglEndFrameTrackingI3D WGLEW_GET_FUN(__wglewEndFrameTrackingI3D)
|
||||
@@ -918,9 +897,9 @@ typedef BOOL (WINAPI * PFNWGLQUERYFRAMETRACKINGI3DPROC) (DWORD* pFrameCount, DWO
|
||||
#ifndef WGL_NV_DX_interop
|
||||
#define WGL_NV_DX_interop 1
|
||||
|
||||
#define WGL_ACCESS_READ_ONLY_NV 0x00000000
|
||||
#define WGL_ACCESS_READ_WRITE_NV 0x00000001
|
||||
#define WGL_ACCESS_WRITE_DISCARD_NV 0x00000002
|
||||
#define WGL_ACCESS_READ_ONLY_NV 0x0000
|
||||
#define WGL_ACCESS_READ_WRITE_NV 0x0001
|
||||
#define WGL_ACCESS_WRITE_DISCARD_NV 0x0002
|
||||
|
||||
typedef BOOL (WINAPI * PFNWGLDXCLOSEDEVICENVPROC) (HANDLE hDevice);
|
||||
typedef BOOL (WINAPI * PFNWGLDXLOCKOBJECTSNVPROC) (HANDLE hDevice, GLint count, HANDLE* hObjects);
|
||||
@@ -1031,21 +1010,6 @@ typedef BOOL (WINAPI * PFNWGLENUMGPUSNVPROC) (UINT iGpuIndex, HGPUNV *phGpu);
|
||||
|
||||
#endif /* WGL_NV_gpu_affinity */
|
||||
|
||||
/* ------------------------ WGL_NV_multigpu_context ------------------------ */
|
||||
|
||||
#ifndef WGL_NV_multigpu_context
|
||||
#define WGL_NV_multigpu_context 1
|
||||
|
||||
#define WGL_CONTEXT_MULTIGPU_ATTRIB_NV 0x20AA
|
||||
#define WGL_CONTEXT_MULTIGPU_ATTRIB_SINGLE_NV 0x20AB
|
||||
#define WGL_CONTEXT_MULTIGPU_ATTRIB_AFR_NV 0x20AC
|
||||
#define WGL_CONTEXT_MULTIGPU_ATTRIB_MULTICAST_NV 0x20AD
|
||||
#define WGL_CONTEXT_MULTIGPU_ATTRIB_MULTI_DISPLAY_MULTICAST_NV 0x20AE
|
||||
|
||||
#define WGLEW_NV_multigpu_context WGLEW_GET_VAR(__WGLEW_NV_multigpu_context)
|
||||
|
||||
#endif /* WGL_NV_multigpu_context */
|
||||
|
||||
/* ---------------------- WGL_NV_multisample_coverage ---------------------- */
|
||||
|
||||
#ifndef WGL_NV_multisample_coverage
|
||||
@@ -1084,6 +1048,7 @@ typedef BOOL (WINAPI * PFNWGLQUERYCURRENTCONTEXTNVPROC) (int iAttribute, int* pi
|
||||
#ifndef WGL_NV_render_depth_texture
|
||||
#define WGL_NV_render_depth_texture 1
|
||||
|
||||
#define WGL_NO_TEXTURE_ARB 0x2077
|
||||
#define WGL_BIND_TO_TEXTURE_DEPTH_NV 0x20A3
|
||||
#define WGL_BIND_TO_TEXTURE_RECTANGLE_DEPTH_NV 0x20A4
|
||||
#define WGL_DEPTH_TEXTURE_FORMAT_NV 0x20A5
|
||||
@@ -1115,8 +1080,8 @@ typedef BOOL (WINAPI * PFNWGLQUERYCURRENTCONTEXTNVPROC) (int iAttribute, int* pi
|
||||
typedef BOOL (WINAPI * PFNWGLBINDSWAPBARRIERNVPROC) (GLuint group, GLuint barrier);
|
||||
typedef BOOL (WINAPI * PFNWGLJOINSWAPGROUPNVPROC) (HDC hDC, GLuint group);
|
||||
typedef BOOL (WINAPI * PFNWGLQUERYFRAMECOUNTNVPROC) (HDC hDC, GLuint* count);
|
||||
typedef BOOL (WINAPI * PFNWGLQUERYMAXSWAPGROUPSNVPROC) (HDC hDC, GLuint* maxGroups, GLuint* maxBarriers);
|
||||
typedef BOOL (WINAPI * PFNWGLQUERYSWAPGROUPNVPROC) (HDC hDC, GLuint* group, GLuint* barrier);
|
||||
typedef BOOL (WINAPI * PFNWGLQUERYMAXSWAPGROUPSNVPROC) (HDC hDC, GLuint* maxGroups, GLuint *maxBarriers);
|
||||
typedef BOOL (WINAPI * PFNWGLQUERYSWAPGROUPNVPROC) (HDC hDC, GLuint* group, GLuint *barrier);
|
||||
typedef BOOL (WINAPI * PFNWGLRESETFRAMECOUNTNVPROC) (HDC hDC);
|
||||
|
||||
#define wglBindSwapBarrierNV WGLEW_GET_FUN(__wglewBindSwapBarrierNV)
|
||||
@@ -1135,8 +1100,8 @@ typedef BOOL (WINAPI * PFNWGLRESETFRAMECOUNTNVPROC) (HDC hDC);
|
||||
#ifndef WGL_NV_vertex_array_range
|
||||
#define WGL_NV_vertex_array_range 1
|
||||
|
||||
typedef void* (WINAPI * PFNWGLALLOCATEMEMORYNVPROC) (GLsizei size, GLfloat readfreq, GLfloat writefreq, GLfloat priority);
|
||||
typedef void (WINAPI * PFNWGLFREEMEMORYNVPROC) (void* pointer);
|
||||
typedef void * (WINAPI * PFNWGLALLOCATEMEMORYNVPROC) (GLsizei size, GLfloat readFrequency, GLfloat writeFrequency, GLfloat priority);
|
||||
typedef void (WINAPI * PFNWGLFREEMEMORYNVPROC) (void *pointer);
|
||||
|
||||
#define wglAllocateMemoryNV WGLEW_GET_FUN(__wglewAllocateMemoryNV)
|
||||
#define wglFreeMemoryNV WGLEW_GET_FUN(__wglewFreeMemoryNV)
|
||||
@@ -1194,7 +1159,7 @@ DECLARE_HANDLE(HPVIDEODEV);
|
||||
|
||||
typedef BOOL (WINAPI * PFNWGLBINDVIDEOIMAGENVPROC) (HPVIDEODEV hVideoDevice, HPBUFFERARB hPbuffer, int iVideoBuffer);
|
||||
typedef BOOL (WINAPI * PFNWGLGETVIDEODEVICENVPROC) (HDC hDC, int numDevices, HPVIDEODEV* hVideoDevice);
|
||||
typedef BOOL (WINAPI * PFNWGLGETVIDEOINFONVPROC) (HPVIDEODEV hpVideoDevice, unsigned long* pulCounterOutputPbuffer, unsigned long* pulCounterOutputVideo);
|
||||
typedef BOOL (WINAPI * PFNWGLGETVIDEOINFONVPROC) (HPVIDEODEV hpVideoDevice, unsigned long* pulCounterOutputPbuffer, unsigned long *pulCounterOutputVideo);
|
||||
typedef BOOL (WINAPI * PFNWGLRELEASEVIDEODEVICENVPROC) (HPVIDEODEV hVideoDevice);
|
||||
typedef BOOL (WINAPI * PFNWGLRELEASEVIDEOIMAGENVPROC) (HPBUFFERARB hPbuffer, int iVideoBuffer);
|
||||
typedef BOOL (WINAPI * PFNWGLSENDPBUFFERTOVIDEONVPROC) (HPBUFFERARB hPbuffer, int iBufferType, unsigned long* pulCounterPbuffer, BOOL bBlock);
|
||||
@@ -1215,12 +1180,12 @@ typedef BOOL (WINAPI * PFNWGLSENDPBUFFERTOVIDEONVPROC) (HPBUFFERARB hPbuffer, in
|
||||
#ifndef WGL_OML_sync_control
|
||||
#define WGL_OML_sync_control 1
|
||||
|
||||
typedef BOOL (WINAPI * PFNWGLGETMSCRATEOMLPROC) (HDC hdc, INT32* numerator, INT32* denominator);
|
||||
typedef BOOL (WINAPI * PFNWGLGETSYNCVALUESOMLPROC) (HDC hdc, INT64* ust, INT64* msc, INT64* sbc);
|
||||
typedef BOOL (WINAPI * PFNWGLGETMSCRATEOMLPROC) (HDC hdc, INT32* numerator, INT32 *denominator);
|
||||
typedef BOOL (WINAPI * PFNWGLGETSYNCVALUESOMLPROC) (HDC hdc, INT64* ust, INT64 *msc, INT64 *sbc);
|
||||
typedef INT64 (WINAPI * PFNWGLSWAPBUFFERSMSCOMLPROC) (HDC hdc, INT64 target_msc, INT64 divisor, INT64 remainder);
|
||||
typedef INT64 (WINAPI * PFNWGLSWAPLAYERBUFFERSMSCOMLPROC) (HDC hdc, INT fuPlanes, INT64 target_msc, INT64 divisor, INT64 remainder);
|
||||
typedef BOOL (WINAPI * PFNWGLWAITFORMSCOMLPROC) (HDC hdc, INT64 target_msc, INT64 divisor, INT64 remainder, INT64* ust, INT64* msc, INT64* sbc);
|
||||
typedef BOOL (WINAPI * PFNWGLWAITFORSBCOMLPROC) (HDC hdc, INT64 target_sbc, INT64* ust, INT64* msc, INT64* sbc);
|
||||
typedef BOOL (WINAPI * PFNWGLWAITFORMSCOMLPROC) (HDC hdc, INT64 target_msc, INT64 divisor, INT64 remainder, INT64* ust, INT64 *msc, INT64 *sbc);
|
||||
typedef BOOL (WINAPI * PFNWGLWAITFORSBCOMLPROC) (HDC hdc, INT64 target_sbc, INT64* ust, INT64 *msc, INT64 *sbc);
|
||||
|
||||
#define wglGetMscRateOML WGLEW_GET_FUN(__wglewGetMscRateOML)
|
||||
#define wglGetSyncValuesOML WGLEW_GET_FUN(__wglewGetSyncValuesOML)
|
||||
@@ -1235,8 +1200,18 @@ typedef BOOL (WINAPI * PFNWGLWAITFORSBCOMLPROC) (HDC hdc, INT64 target_sbc, INT6
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
#ifdef GLEW_MX
|
||||
#define WGLEW_FUN_EXPORT
|
||||
#define WGLEW_VAR_EXPORT
|
||||
#else
|
||||
#define WGLEW_FUN_EXPORT GLEW_FUN_EXPORT
|
||||
#define WGLEW_VAR_EXPORT GLEW_VAR_EXPORT
|
||||
#endif /* GLEW_MX */
|
||||
|
||||
#ifdef GLEW_MX
|
||||
struct WGLEWContextStruct
|
||||
{
|
||||
#endif /* GLEW_MX */
|
||||
|
||||
WGLEW_FUN_EXPORT PFNWGLSETSTEREOEMITTERSTATE3DLPROC __wglewSetStereoEmitterState3DL;
|
||||
|
||||
@@ -1393,7 +1368,6 @@ WGLEW_VAR_EXPORT GLboolean __WGLEW_AMD_gpu_association;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_ARB_buffer_region;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_ARB_context_flush_control;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_ARB_create_context;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_ARB_create_context_no_error;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_ARB_create_context_profile;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_ARB_create_context_robustness;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_ARB_extensions_string;
|
||||
@@ -1408,7 +1382,6 @@ WGLEW_VAR_EXPORT GLboolean __WGLEW_ARB_robustness_application_isolation;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_ARB_robustness_share_group_isolation;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_ATI_pixel_format_float;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_ATI_render_texture_rectangle;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_EXT_colorspace;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_EXT_create_context_es2_profile;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_EXT_create_context_es_profile;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_EXT_depth_float;
|
||||
@@ -1434,7 +1407,6 @@ WGLEW_VAR_EXPORT GLboolean __WGLEW_NV_copy_image;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_NV_delay_before_swap;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_NV_float_buffer;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_NV_gpu_affinity;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_NV_multigpu_context;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_NV_multisample_coverage;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_NV_present_video;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_NV_render_depth_texture;
|
||||
@@ -1444,18 +1416,34 @@ WGLEW_VAR_EXPORT GLboolean __WGLEW_NV_vertex_array_range;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_NV_video_capture;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_NV_video_output;
|
||||
WGLEW_VAR_EXPORT GLboolean __WGLEW_OML_sync_control;
|
||||
|
||||
#ifdef GLEW_MX
|
||||
}; /* WGLEWContextStruct */
|
||||
#endif /* GLEW_MX */
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
#ifdef GLEW_MX
|
||||
|
||||
typedef struct WGLEWContextStruct WGLEWContext;
|
||||
GLEWAPI GLenum GLEWAPIENTRY wglewContextInit (WGLEWContext *ctx);
|
||||
GLEWAPI GLboolean GLEWAPIENTRY wglewContextIsSupported (const WGLEWContext *ctx, const char *name);
|
||||
|
||||
#define wglewInit() wglewContextInit(wglewGetContext())
|
||||
#define wglewIsSupported(x) wglewContextIsSupported(wglewGetContext(), x)
|
||||
|
||||
#define WGLEW_GET_VAR(x) (*(const GLboolean*)&(wglewGetContext()->x))
|
||||
#define WGLEW_GET_FUN(x) wglewGetContext()->x
|
||||
|
||||
#else /* GLEW_MX */
|
||||
|
||||
GLEWAPI GLenum GLEWAPIENTRY wglewInit ();
|
||||
GLEWAPI GLboolean GLEWAPIENTRY wglewIsSupported (const char *name);
|
||||
|
||||
#ifndef WGLEW_GET_VAR
|
||||
#define WGLEW_GET_VAR(x) (*(const GLboolean*)&x)
|
||||
#endif
|
||||
|
||||
#ifndef WGLEW_GET_FUN
|
||||
#define WGLEW_GET_FUN(x) x
|
||||
#endif
|
||||
|
||||
#endif /* GLEW_MX */
|
||||
|
||||
GLEWAPI GLboolean GLEWAPIENTRY wglewGetExtension (const char *name);
|
||||
|
||||
|
||||
18481
deps/GLEW/glew/src/glew.c
vendored
11
deps/GLFW/GLFW.cmake
vendored
@@ -6,12 +6,6 @@ else()
|
||||
set(_build_static ON)
|
||||
endif()
|
||||
|
||||
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||
set(_glfw_use_wayland "-DGLFW_USE_WAYLAND=ON")
|
||||
else()
|
||||
set(_glfw_use_wayland "-DGLFW_USE_WAYLAND=FF")
|
||||
endif()
|
||||
|
||||
bambustudio_add_cmake_project(GLFW
|
||||
URL https://github.com/glfw/glfw/archive/refs/tags/3.3.7.zip
|
||||
URL_HASH SHA256=e02d956935e5b9fb4abf90e2c2e07c9a0526d7eacae8ee5353484c69a2a76cd0
|
||||
@@ -20,10 +14,9 @@ bambustudio_add_cmake_project(GLFW
|
||||
-DBUILD_SHARED_LIBS=${_build_shared}
|
||||
-DGLFW_BUILD_DOCS=OFF
|
||||
-DGLFW_BUILD_EXAMPLES=OFF
|
||||
-DGLFW_BUILD_TESTS=OFF
|
||||
${_glfw_use_wayland}
|
||||
-DGLFW_BUILD_TESTS=OFF
|
||||
)
|
||||
|
||||
if (MSVC)
|
||||
add_debug_dep(dep_GLFW)
|
||||
endif ()
|
||||
endif ()
|
||||
22
deps/GMP/GMP.cmake
vendored
@@ -22,24 +22,10 @@ else ()
|
||||
|
||||
if (APPLE)
|
||||
if (${CMAKE_SYSTEM_PROCESSOR} MATCHES "arm")
|
||||
set(_gmp_build_arch aarch64)
|
||||
else ()
|
||||
set(_gmp_build_arch ${CMAKE_SYSTEM_PROCESSOR})
|
||||
endif()
|
||||
if (IS_CROSS_COMPILE)
|
||||
if (${CMAKE_OSX_ARCHITECTURES} MATCHES "arm")
|
||||
set(_gmp_host_arch aarch64)
|
||||
set(_gmp_host_arch_flags "-arch arm64")
|
||||
elseif (${CMAKE_OSX_ARCHITECTURES} MATCHES "x86_64")
|
||||
set(_gmp_host_arch x86_64)
|
||||
set(_gmp_host_arch_flags "-arch x86_64")
|
||||
endif()
|
||||
set(_gmp_ccflags "${_gmp_ccflags} ${_gmp_host_arch_flags} -mmacosx-version-min=${DEP_OSX_TARGET}")
|
||||
set(_gmp_build_tgt --build=${_gmp_build_arch}-apple-darwin --host=${_gmp_host_arch}-apple-darwin)
|
||||
else ()
|
||||
set(_gmp_ccflags "${_gmp_ccflags} -mmacosx-version-min=${DEP_OSX_TARGET}")
|
||||
set(_gmp_build_tgt "--build=${_gmp_build_arch}-apple-darwin")
|
||||
set(_gmp_build_tgt aarch64)
|
||||
endif()
|
||||
set(_gmp_ccflags "${_gmp_ccflags} -mmacosx-version-min=${DEP_OSX_TARGET}")
|
||||
set(_gmp_build_tgt "--build=${_gmp_build_tgt}-apple-darwin")
|
||||
elseif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||
if (${CMAKE_SYSTEM_PROCESSOR} MATCHES "arm")
|
||||
set(_gmp_ccflags "${_gmp_ccflags} -march=armv7-a") # Works on RPi-4
|
||||
@@ -65,4 +51,4 @@ else ()
|
||||
BUILD_COMMAND make -j
|
||||
INSTALL_COMMAND make install
|
||||
)
|
||||
endif ()
|
||||
endif ()
|
||||
|
||||
22
deps/OCCT/OCCT.cmake
vendored
@@ -10,21 +10,19 @@ bambustudio_add_cmake_project(OCCT
|
||||
#PATCH_COMMAND ${PATCH_CMD} ${CMAKE_CURRENT_LIST_DIR}/0001-OCCT-fix.patch
|
||||
PATCH_COMMAND git apply --directory deps/build/dep_OCCT-prefix/src/dep_OCCT --verbose --ignore-space-change --whitespace=fix ${CMAKE_CURRENT_LIST_DIR}/0001-OCCT-fix.patch
|
||||
#DEPENDS dep_Boost
|
||||
#DEPENDS dep_FREETYPE
|
||||
CMAKE_ARGS
|
||||
-DBUILD_LIBRARY_TYPE=${library_build_type}
|
||||
-DUSE_TK=OFF
|
||||
-DUSE_TBB=OFF
|
||||
#-DUSE_FREETYPE=OFF
|
||||
-DUSE_FFMPEG=OFF
|
||||
-DUSE_VTK=OFF
|
||||
-DBUILD_MODULE_ApplicationFramework=OFF
|
||||
#-DBUILD_MODULE_DataExchange=OFF
|
||||
-DUSE_FREETYPE=OFF
|
||||
-DUSE_FFMPEG=OFF
|
||||
-DUSE_VTK=OFF
|
||||
-DUSE_FREETYPE=OFF
|
||||
-DBUILD_MODULE_ApplicationFramework=OFF
|
||||
#-DBUILD_MODULE_DataExchange=OFF
|
||||
-DBUILD_MODULE_Draw=OFF
|
||||
-DBUILD_MODULE_FoundationClasses=OFF
|
||||
-DBUILD_MODULE_ModelingAlgorithms=OFF
|
||||
-DBUILD_MODULE_ModelingData=OFF
|
||||
-DBUILD_MODULE_Visualization=OFF
|
||||
-DBUILD_MODULE_FoundationClasses=OFF
|
||||
-DBUILD_MODULE_ModelingAlgorithms=OFF
|
||||
-DBUILD_MODULE_ModelingData=OFF
|
||||
-DBUILD_MODULE_Visualization=OFF
|
||||
)
|
||||
|
||||
add_dependencies(dep_OCCT dep_FREETYPE)
|
||||
|
||||
32
deps/OpenEXR/OpenEXR.cmake
vendored
@@ -1,34 +1,3 @@
|
||||
# Check if we're building for arm on x86_64 and just for OpenEXR, build fat
|
||||
# binaries. We need this because it compiles some code to generate other
|
||||
# source and we need to be able to run the executables. When we link the
|
||||
# library, the x86_64 part will be ignored.
|
||||
if (APPLE AND IS_CROSS_COMPILE)
|
||||
if (${CMAKE_SYSTEM_PROCESSOR} MATCHES "x86_64" AND ${CMAKE_OSX_ARCHITECTURES} MATCHES "arm")
|
||||
set(_openexr_arch arm64^^x86_64)
|
||||
set(_openxr_list_sep LIST_SEPARATOR ^^)
|
||||
set(_cmake_openexr_arch -DCMAKE_OSX_ARCHITECTURES:STRING=${_openexr_arch})
|
||||
else()
|
||||
set(_openexr_arch ${CMAKE_OSX_ARCHITECTURES})
|
||||
set(_cmake_openexr_arch -DCMAKE_OSX_ARCHITECTURES:STRING=${_openexr_arch})
|
||||
endif()
|
||||
ExternalProject_Add(dep_OpenEXR
|
||||
EXCLUDE_FROM_ALL ON
|
||||
URL https://github.com/AcademySoftwareFoundation/openexr/archive/refs/tags/v2.5.5.zip
|
||||
URL_HASH SHA256=0307a3d7e1fa1e77e9d84d7e9a8694583fbbbfd50bdc6884e2c96b8ef6b902de
|
||||
INSTALL_DIR ${DESTDIR}/usr/local
|
||||
DOWNLOAD_DIR ${DEP_DOWNLOAD_DIR}/OpenEXR
|
||||
${_openxr_list_sep}
|
||||
CMAKE_ARGS
|
||||
-DCMAKE_INSTALL_PREFIX:STRING=${DESTDIR}/usr/local
|
||||
-DBUILD_SHARED_LIBS:BOOL=OFF
|
||||
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
|
||||
-DBUILD_TESTING=OFF
|
||||
-DPYILMBASE_ENABLE:BOOL=OFF
|
||||
-DOPENEXR_VIEWERS_ENABLE:BOOL=OFF
|
||||
-DOPENEXR_BUILD_UTILS:BOOL=OFF
|
||||
${_cmake_openexr_arch}
|
||||
)
|
||||
else()
|
||||
bambustudio_add_cmake_project(OpenEXR
|
||||
# GIT_REPOSITORY https://github.com/openexr/openexr.git
|
||||
URL https://github.com/AcademySoftwareFoundation/openexr/archive/refs/tags/v2.5.5.zip
|
||||
@@ -42,7 +11,6 @@ bambustudio_add_cmake_project(OpenEXR
|
||||
-DOPENEXR_VIEWERS_ENABLE:BOOL=OFF
|
||||
-DOPENEXR_BUILD_UTILS:BOOL=OFF
|
||||
)
|
||||
endif()
|
||||
|
||||
if (MSVC)
|
||||
add_debug_dep(dep_OpenEXR)
|
||||
|
||||
53
deps/PNG/PNG.cmake
vendored
@@ -5,43 +5,26 @@ else ()
|
||||
set(_disable_neon_extension "")
|
||||
endif ()
|
||||
|
||||
if(APPLE AND IS_CROSS_COMPILE)
|
||||
# TODO: check if it doesn't create problem when compiling from arm to x86_64
|
||||
bambustudio_add_cmake_project(PNG
|
||||
GIT_REPOSITORY https://github.com/glennrp/libpng.git
|
||||
GIT_TAG v1.6.35
|
||||
DEPENDS ${ZLIB_PKG}
|
||||
PATCH_COMMAND ${GIT_EXECUTABLE} checkout -f -- . && git clean -df &&
|
||||
${GIT_EXECUTABLE} apply --whitespace=fix ${CMAKE_CURRENT_LIST_DIR}/macos-arm64.patch
|
||||
CMAKE_ARGS
|
||||
-DPNG_SHARED=OFF
|
||||
-DPNG_STATIC=ON
|
||||
-DPNG_PREFIX=prusaslicer_
|
||||
-DPNG_TESTS=OFF
|
||||
-DDISABLE_DEPENDENCY_TRACKING=OFF
|
||||
${_disable_neon_extension}
|
||||
)
|
||||
else ()
|
||||
set(_patch_step "")
|
||||
if (APPLE)
|
||||
set(_patch_step PATCH_COMMAND ${PATCH_CMD} ${CMAKE_CURRENT_LIST_DIR}/PNG.patch)
|
||||
endif ()
|
||||
bambustudio_add_cmake_project(PNG
|
||||
# GIT_REPOSITORY https://github.com/glennrp/libpng.git
|
||||
# GIT_TAG v1.6.35
|
||||
URL https://github.com/glennrp/libpng/archive/refs/tags/v1.6.35.zip
|
||||
URL_HASH SHA256=3d22d46c566b1761a0e15ea397589b3a5f36ac09b7c785382e6470156c04247f
|
||||
DEPENDS ${ZLIB_PKG}
|
||||
"${_patch_step}"
|
||||
CMAKE_ARGS
|
||||
-DPNG_SHARED=OFF
|
||||
-DPNG_STATIC=ON
|
||||
-DPNG_PREFIX=prusaslicer_
|
||||
-DPNG_TESTS=OFF
|
||||
-DDISABLE_DEPENDENCY_TRACKING=OFF
|
||||
${_disable_neon_extension}
|
||||
if (APPLE)
|
||||
set(_patch_step PATCH_COMMAND ${PATCH_CMD} ${CMAKE_CURRENT_LIST_DIR}/PNG.patch)
|
||||
endif ()
|
||||
|
||||
bambustudio_add_cmake_project(PNG
|
||||
# GIT_REPOSITORY https://github.com/glennrp/libpng.git
|
||||
# GIT_TAG v1.6.35
|
||||
URL https://github.com/glennrp/libpng/archive/refs/tags/v1.6.35.zip
|
||||
URL_HASH SHA256=3d22d46c566b1761a0e15ea397589b3a5f36ac09b7c785382e6470156c04247f
|
||||
DEPENDS ${ZLIB_PKG}
|
||||
"${_patch_step}"
|
||||
CMAKE_ARGS
|
||||
-DPNG_SHARED=OFF
|
||||
-DPNG_STATIC=ON
|
||||
-DPNG_PREFIX=prusaslicer_
|
||||
-DPNG_TESTS=OFF
|
||||
-DDISABLE_DEPENDENCY_TRACKING=OFF
|
||||
${_disable_neon_extension}
|
||||
)
|
||||
endif()
|
||||
|
||||
if (MSVC)
|
||||
add_debug_dep(dep_PNG)
|
||||
|
||||
90
deps/PNG/macos-arm64.patch
vendored
@@ -1,90 +0,0 @@
|
||||
Based on https://github.com/vespakoen/libpng to work around until
|
||||
https://github.com/glennrp/libpng/pull/354 is resolved.
|
||||
also added patch from PS2.4 (PNG.pach) in pngrutil.c
|
||||
---
|
||||
CMakeLists.txt | 28 ++++++++++++++++++++--------
|
||||
pngrutil.c | 7 -------
|
||||
2 files changed, 20 insertions(+), 15 deletions(-)
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 4db9bb87d..9099d1edf 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -82,10 +82,22 @@ option(PNG_HARDWARE_OPTIMIZATIONS "Enable Hardware Optimizations" ON)
|
||||
set(PNG_PREFIX "" CACHE STRING "Prefix to add to the API function names")
|
||||
set(DFA_XTRA "" CACHE FILEPATH "File containing extra configuration settings")
|
||||
|
||||
+# CMake currently sets CMAKE_SYSTEM_PROCESSOR to one of x86_64 or arm64 on macOS,
|
||||
+# based upon the OS architecture, not the target architecture. As such, we need
|
||||
+# to check CMAKE_OSX_ARCHITECTURES to identify which hardware-specific flags to
|
||||
+# enable. Note that this will fail if you attempt to build a universal binary in
|
||||
+# a single cmake invokation.
|
||||
+if (APPLE AND CMAKE_OSX_ARCHITECTURES)
|
||||
+ set(TARGET_ARCH ${CMAKE_OSX_ARCHITECTURES})
|
||||
+else()
|
||||
+ set(TARGET_ARCH ${CMAKE_SYSTEM_PROCESSOR})
|
||||
+endif()
|
||||
+
|
||||
+
|
||||
if(PNG_HARDWARE_OPTIMIZATIONS)
|
||||
# set definitions and sources for arm
|
||||
-if(CMAKE_SYSTEM_PROCESSOR MATCHES "^arm" OR
|
||||
- CMAKE_SYSTEM_PROCESSOR MATCHES "^aarch64")
|
||||
+if(TARGET_ARCH MATCHES "^arm" OR
|
||||
+ TARGET_ARCH MATCHES "^aarch64")
|
||||
set(PNG_ARM_NEON_POSSIBLE_VALUES check on off)
|
||||
set(PNG_ARM_NEON "check" CACHE STRING "Enable ARM NEON optimizations:
|
||||
check: (default) use internal checking code;
|
||||
@@ -114,8 +126,8 @@ if(CMAKE_SYSTEM_PROCESSOR MATCHES "^arm" OR
|
||||
endif()
|
||||
|
||||
# set definitions and sources for powerpc
|
||||
-if(CMAKE_SYSTEM_PROCESSOR MATCHES "^powerpc*" OR
|
||||
- CMAKE_SYSTEM_PROCESSOR MATCHES "^ppc64*" )
|
||||
+if(TARGET_ARCH MATCHES "^powerpc*" OR
|
||||
+ TARGET_ARCH MATCHES "^ppc64*" )
|
||||
set(PNG_POWERPC_VSX_POSSIBLE_VALUES on off)
|
||||
set(PNG_POWERPC_VSX "on" CACHE STRING "Enable POWERPC VSX optimizations:
|
||||
off: disable the optimizations.")
|
||||
@@ -138,8 +150,8 @@ if(CMAKE_SYSTEM_PROCESSOR MATCHES "^powerpc*" OR
|
||||
endif()
|
||||
|
||||
# set definitions and sources for intel
|
||||
-if(CMAKE_SYSTEM_PROCESSOR MATCHES "^i?86" OR
|
||||
- CMAKE_SYSTEM_PROCESSOR MATCHES "^x86_64*" )
|
||||
+if(TARGET_ARCH MATCHES "^i?86" OR
|
||||
+ TARGET_ARCH MATCHES "^x86_64*" )
|
||||
set(PNG_INTEL_SSE_POSSIBLE_VALUES on off)
|
||||
set(PNG_INTEL_SSE "on" CACHE STRING "Enable INTEL_SSE optimizations:
|
||||
off: disable the optimizations")
|
||||
@@ -162,8 +174,8 @@ if(CMAKE_SYSTEM_PROCESSOR MATCHES "^i?86" OR
|
||||
endif()
|
||||
|
||||
# set definitions and sources for MIPS
|
||||
-if(CMAKE_SYSTEM_PROCESSOR MATCHES "mipsel*" OR
|
||||
- CMAKE_SYSTEM_PROCESSOR MATCHES "mips64el*" )
|
||||
+if(TARGET_ARCH MATCHES "mipsel*" OR
|
||||
+ TARGET_ARCH MATCHES "mips64el*" )
|
||||
set(PNG_MIPS_MSA_POSSIBLE_VALUES on off)
|
||||
set(PNG_MIPS_MSA "on" CACHE STRING "Enable MIPS_MSA optimizations:
|
||||
off: disable the optimizations")
|
||||
diff --git a/pngrutil.c b/pngrutil.c
|
||||
index 7001f1976..91930f1f2 100644
|
||||
--- a/pngrutil.c
|
||||
+++ b/pngrutil.c
|
||||
@@ -422,13 +422,6 @@ png_inflate_claim(png_structrp png_ptr, png_uint_32 owner)
|
||||
png_ptr->flags |= PNG_FLAG_ZSTREAM_INITIALIZED;
|
||||
}
|
||||
|
||||
-#if ZLIB_VERNUM >= 0x1290 && \
|
||||
- defined(PNG_SET_OPTION_SUPPORTED) && defined(PNG_IGNORE_ADLER32)
|
||||
- if (((png_ptr->options >> PNG_IGNORE_ADLER32) & 3) == PNG_OPTION_ON)
|
||||
- /* Turn off validation of the ADLER32 checksum in IDAT chunks */
|
||||
- ret = inflateValidate(&png_ptr->zstream, 0);
|
||||
-#endif
|
||||
-
|
||||
if (ret == Z_OK)
|
||||
png_ptr->zowner = owner;
|
||||
|
||||
--
|
||||
2.33.0.windows.1
|
||||
41
deps/TIFF/TIFF.cmake
vendored
@@ -1,32 +1,13 @@
|
||||
find_package(OpenGL QUIET REQUIRED)
|
||||
|
||||
if (APPLE)
|
||||
message(STATUS "Compiling TIFF for macos ${CMAKE_SYSTEM_VERSION}.")
|
||||
bambustudio_add_cmake_project(TIFF
|
||||
URL https://gitlab.com/libtiff/libtiff/-/archive/v4.3.0/libtiff-v4.3.0.zip
|
||||
URL_HASH SHA256=4fca1b582c88319f3ad6ecd5b46320eadaf5eb4ef6f6c32d44caaae4a03d0726
|
||||
DEPENDS ${ZLIB_PKG} ${PNG_PKG} dep_JPEG
|
||||
CMAKE_ARGS
|
||||
-Dlzma:BOOL=OFF
|
||||
-Dwebp:BOOL=OFF
|
||||
-Djbig:BOOL=OFF
|
||||
-Dzstd:BOOL=OFF
|
||||
-Dpixarlog:BOOL=OFF
|
||||
)
|
||||
else()
|
||||
bambustudio_add_cmake_project(TIFF
|
||||
URL https://gitlab.com/libtiff/libtiff/-/archive/v4.1.0/libtiff-v4.1.0.zip
|
||||
URL_HASH SHA256=c56edfacef0a60c0de3e6489194fcb2f24c03dbb550a8a7de5938642d045bd32
|
||||
DEPENDS ${ZLIB_PKG} ${PNG_PKG} dep_JPEG
|
||||
CMAKE_ARGS
|
||||
-Dlzma:BOOL=OFF
|
||||
-Dwebp:BOOL=OFF
|
||||
-Djbig:BOOL=OFF
|
||||
-Dzstd:BOOL=OFF
|
||||
-Dpixarlog:BOOL=OFF
|
||||
)
|
||||
|
||||
endif()
|
||||
|
||||
|
||||
|
||||
bambustudio_add_cmake_project(TIFF
|
||||
URL https://gitlab.com/libtiff/libtiff/-/archive/v4.1.0/libtiff-v4.1.0.zip
|
||||
URL_HASH SHA256=c56edfacef0a60c0de3e6489194fcb2f24c03dbb550a8a7de5938642d045bd32
|
||||
DEPENDS ${ZLIB_PKG} ${PNG_PKG} dep_JPEG
|
||||
CMAKE_ARGS
|
||||
-Dlzma:BOOL=OFF
|
||||
-Dwebp:BOOL=OFF
|
||||
-Djbig:BOOL=OFF
|
||||
-Dzstd:BOOL=OFF
|
||||
-Dpixarlog:BOOL=OFF
|
||||
)
|
||||
|
||||
4
deps/deps-windows.cmake
vendored
@@ -15,10 +15,6 @@ elseif (MSVC_VERSION LESS 1930)
|
||||
# 1920-1929 = VS 16.0 (v142 toolset)
|
||||
set(DEP_VS_VER "16")
|
||||
set(DEP_BOOST_TOOLSET "msvc-14.2")
|
||||
elseif (MSVC_VERSION LESS 1940)
|
||||
# 1930-1939 = VS 17.0 (v143 toolset)
|
||||
set(DEP_VS_VER "17")
|
||||
set(DEP_BOOST_TOOLSET "msvc-14.3")
|
||||
else ()
|
||||
message(FATAL_ERROR "Unsupported MSVC version")
|
||||
endif ()
|
||||
|
||||
16
deps/wxWidgets/0001-wxWidget-fix.patch
vendored
@@ -1,19 +1,3 @@
|
||||
diff --git a/build/cmake/init.cmake b/build/cmake/init.cmake
|
||||
index 0bc4f934b9..479431a69c 100644
|
||||
--- a/build/cmake/init.cmake
|
||||
+++ b/build/cmake/init.cmake
|
||||
@@ -413,7 +413,11 @@ if(wxUSE_GUI)
|
||||
else()
|
||||
find_package(OpenGL)
|
||||
if(WXGTK3 AND OpenGL_EGL_FOUND AND wxUSE_GLCANVAS_EGL)
|
||||
+ if(UNIX AND NOT APPLE)
|
||||
+ set(OPENGL_LIBRARIES OpenGL EGL)
|
||||
+ else()
|
||||
set(OPENGL_LIBRARIES OpenGL::OpenGL OpenGL::EGL)
|
||||
+ endif()
|
||||
find_package(WAYLANDEGL)
|
||||
if(WAYLANDEGL_FOUND AND wxHAVE_GDK_WAYLAND)
|
||||
list(APPEND OPENGL_LIBRARIES ${WAYLANDEGL_LIBRARIES})
|
||||
diff --git a/include/wx/fontutil.h b/include/wx/fontutil.h
|
||||
index 09ad8c8ef3..3c0c2d8f7e 100644
|
||||
--- a/include/wx/fontutil.h
|
||||
|
||||
19
deps/wxWidgets/wxWidgets.cmake
vendored
@@ -7,9 +7,6 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||
set(_gtk_ver 3)
|
||||
endif ()
|
||||
set(_wx_toolkit "-DwxBUILD_TOOLKIT=gtk${_gtk_ver}")
|
||||
set(_wx_private_font "-DwxUSE_PRIVATE_FONTS=1")
|
||||
else ()
|
||||
set(_wx_private_font "-DwxUSE_PRIVATE_FONTS=0")
|
||||
endif()
|
||||
|
||||
if (MSVC)
|
||||
@@ -18,21 +15,10 @@ else ()
|
||||
set(_wx_edge "-DwxUSE_WEBVIEW_EDGE=OFF")
|
||||
endif ()
|
||||
|
||||
if (MSVC)
|
||||
set(_patch_cmd ${PATCH_CMD} ${CMAKE_CURRENT_LIST_DIR}/0001-wxWidget-fix.patch)
|
||||
else ()
|
||||
set(_patch_cmd test -f WXWIDGETS_PATCHED || ${PATCH_CMD} ${CMAKE_CURRENT_LIST_DIR}/0001-wxWidget-fix.patch && touch WXWIDGETS_PATCHED)
|
||||
endif ()
|
||||
|
||||
if (CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||
set(_patch_cmd ${PATCH_CMD} ${CMAKE_CURRENT_LIST_DIR}/0001-wxWidget-fix.patch)
|
||||
endif ()
|
||||
|
||||
|
||||
bambustudio_add_cmake_project(wxWidgets
|
||||
GIT_REPOSITORY "https://github.com/wxWidgets/wxWidgets"
|
||||
GIT_TAG ${_wx_git_tag}
|
||||
PATCH_COMMAND ${_patch_cmd}
|
||||
PATCH_COMMAND ${PATCH_CMD} ${CMAKE_CURRENT_LIST_DIR}/0001-wxWidget-fix.patch
|
||||
DEPENDS ${PNG_PKG} ${ZLIB_PKG} ${EXPAT_PKG} dep_TIFF dep_JPEG
|
||||
CMAKE_ARGS
|
||||
-DwxBUILD_PRECOMP=ON
|
||||
@@ -44,7 +30,6 @@ bambustudio_add_cmake_project(wxWidgets
|
||||
-DwxUSE_MEDIACTRL=ON
|
||||
-DwxUSE_DETECT_SM=OFF
|
||||
-DwxUSE_UNICODE=ON
|
||||
${_wx_private_font}
|
||||
-DwxUSE_OPENGL=ON
|
||||
-DwxUSE_WEBVIEW=ON
|
||||
${_wx_edge}
|
||||
@@ -64,4 +49,4 @@ bambustudio_add_cmake_project(wxWidgets
|
||||
|
||||
if (MSVC)
|
||||
add_debug_dep(dep_wxWidgets)
|
||||
endif ()
|
||||
endif ()
|
||||
|
||||
35
doc/Dependencies.md
Normal file
@@ -0,0 +1,35 @@
|
||||
# Dependency report for PrusaSlicer
|
||||
## Possible dynamic linking on Linux
|
||||
* zlib: Strict dependency required from the system, linked dynamically. Many other libs depend on zlib.
|
||||
* wxWidgets: searches for wx-3.1 by default, but with cmake option `SLIC3R_WX_STABLE=ON` it will use wx-3.0 bundled with most distros.
|
||||
* libcurl
|
||||
* tbb
|
||||
* boost
|
||||
* eigen
|
||||
* glew
|
||||
* expat
|
||||
* openssl
|
||||
* nlopt
|
||||
* openvdb: This library depends on other libs, namely boost, zlib, openexr, blosc (not strictly), etc...
|
||||
* CGAL: Needs additional dependencies
|
||||
* MPFR
|
||||
* GMP
|
||||
|
||||
## External libraries in source tree
|
||||
* ad-mesh: Lots of customization, have to be bundled in the source tree.
|
||||
* avrdude: Like ad-mesh, many customization, need to be in the source tree.
|
||||
* clipper: An important library we have to have full control over it. We also have some slicer specific modifications.
|
||||
* glu-libtess: This is an extract of the mesa/glu library not officially available as a package.
|
||||
* imgui: no packages for debian, author suggests using in the source tree
|
||||
* miniz: No packages, author suggests using in the source tree
|
||||
* qhull: libqhull-dev does not contain libqhullcpp => link errors. Until it is fixed, we will use the builtin version. https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=925540
|
||||
* semver: One module C library, author expects to use clib for installation. No packages.
|
||||
* Shiny: no packages
|
||||
|
||||
## Header only
|
||||
* igl
|
||||
* nanosvg
|
||||
* agg
|
||||
* catch2: Only Arch has packages for catch2, other distros at most catch (v1.x). Being strictly header only, we bundle this in the source tree. Used for the unit-test suites.
|
||||
|
||||
|
||||
@@ -1,4 +1,131 @@
|
||||
|
||||
# Building Bambu Studio on UNIX/Linux
|
||||
# Building PrusaSlicer on UNIX/Linux
|
||||
|
||||
Currently Linux version is not verified, you can try it referring to [PrusaSlicer'S linux building guide](https://github.com/prusa3d/PrusaSlicer/blob/master/doc/How%20to%20build%20-%20Linux%20et%20al.md)
|
||||
Please understand that PrusaSlicer team cannot support compilation on all possible Linux distros. Namely, we cannot help troubleshoot OpenGL driver issues or dependency issues if compiled against distro provided libraries. **We can only support PrusaSlicer statically linked against the dependencies compiled with the `deps` scripts**, the same way we compile PrusaSlicer for our [binary builds](https://github.com/prusa3d/PrusaSlicer/releases).
|
||||
|
||||
If you have some reason to link dynamically to your system libraries, you are free to do so, but we can not and will not troubleshoot any issues you possibly run into.
|
||||
|
||||
Instead of compiling PrusaSlicer from source code, one may also consider to install PrusaSlicer [pre-compiled by contributors](https://github.com/prusa3d/PrusaSlicer/wiki/PrusaSlicer-on-Linux---binary-distributions).
|
||||
|
||||
## Step by step guide
|
||||
|
||||
This guide describes building PrusaSlicer statically against dependencies pulled by our `deps` script. Running all the listed commands in order should result in successful build.
|
||||
|
||||
#### 0. Prerequisities
|
||||
|
||||
GNU build tools, CMake, git and other libraries have to be installed on the build machine.
|
||||
Unless that's already the case, install them as usual from your distribution packages.
|
||||
E.g. on Ubuntu 20.10, run
|
||||
```shell
|
||||
sudo apt-get install -y \
|
||||
git \
|
||||
build-essential \
|
||||
autoconf \
|
||||
cmake \
|
||||
libglu1-mesa-dev \
|
||||
libgtk-3-dev \
|
||||
libdbus-1-dev \
|
||||
|
||||
```
|
||||
The names of the packages may be different on different distros.
|
||||
|
||||
#### 1. Cloning the repository
|
||||
|
||||
|
||||
Cloning the repository is simple thanks to git and Github. Simply `cd` into wherever you want to clone PrusaSlicer code base and run
|
||||
```
|
||||
git clone https://www.github.com/prusa3d/PrusaSlicer
|
||||
cd PrusaSlicer
|
||||
```
|
||||
This will download the source code into a new directory and `cd` into it. You can now optionally select a tag/branch/commit to build using `git checkout`. Otherwise, `master` branch will be built.
|
||||
|
||||
|
||||
#### 2. Building dependencies
|
||||
|
||||
PrusaSlicer uses CMake and the build is quite simple, the only tricky part is resolution of dependencies. The supported and recommended way is to build the dependencies first and link to them statically. PrusaSlicer source base contains a CMake script that automatically downloads and builds the required dependencies. All that is needed is to run the following (from the top of the cloned repository):
|
||||
|
||||
cd deps
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. -DDEP_WX_GTK3=ON
|
||||
make
|
||||
cd ../..
|
||||
|
||||
|
||||
**Warning**: Once the dependency bundle is installed in a destdir, the destdir cannot be moved elsewhere. This is because wxWidgets hardcode the installation path.
|
||||
|
||||
|
||||
#### 3. Building PrusaSlicer
|
||||
|
||||
Now when the dependencies are compiled, all that is needed is to tell CMake that we are interested in static build and point it to the dependencies. From the top of the repository, run
|
||||
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. -DSLIC3R_STATIC=1 -DSLIC3R_GTK=3 -DSLIC3R_PCH=OFF -DCMAKE_PREFIX_PATH=$(pwd)/../deps/build/destdir/usr/local
|
||||
make -j4
|
||||
|
||||
And that's it. It is now possible to run the freshly built PrusaSlicer binary:
|
||||
|
||||
cd src
|
||||
./prusa-slicer
|
||||
|
||||
|
||||
|
||||
|
||||
## Useful CMake flags when building dependencies
|
||||
|
||||
- `-DDESTDIR=<target destdir>` allows to specify a directory where the dependencies will be installed. When not provided, the script creates and uses `destdir` directory where cmake is run.
|
||||
|
||||
- `-DDEP_DOWNLOAD_DIR=<download cache dir>` specifies a directory to cache the downloaded source packages for each library. Can be useful for repeated builds, to avoid unnecessary network traffic.
|
||||
|
||||
- `-DDEP_WX_GTK3=ON` builds wxWidgets (one of the dependencies) against GTK3 (defaults to OFF)
|
||||
|
||||
|
||||
## Useful CMake flags when building PrusaSlicer
|
||||
- `-DSLIC3R_ASAN=ON` enables gcc/clang address sanitizer (defaults to `OFF`, requires gcc>4.8 or clang>3.1)
|
||||
- `-DSLIC3R_GTK=3` to use GTK3 (defaults to `2`). Note that wxWidgets must be built against the same GTK version.
|
||||
- `-DSLIC3R_STATIC=ON` for static build (defaults to `OFF`)
|
||||
- `-DSLIC3R_WX_STABLE=ON` to look for wxWidgets 3.0 (defaults to `OFF`)
|
||||
- `-DCMAKE_BUILD_TYPE=Debug` to build in debug mode (defaults to `Release`)
|
||||
|
||||
See the CMake files to get the complete list.
|
||||
|
||||
|
||||
|
||||
## Building dynamically
|
||||
|
||||
As already mentioned above, dynamic linking of dependencies is possible, but PrusaSlicer team is unable to troubleshoot (Linux world is way too complex). Feel free to do so, but you are on your own. Several remarks though:
|
||||
|
||||
The list of dependencies can be easily obtained by inspecting the CMake scripts in the `deps/` directory. Some of the dependencies don't have to be as recent as the versions listed - generally versions available on conservative Linux distros such as Debian stable, Ubuntu LTS releases or Fedora are likely sufficient. If you decide to build this way, it is your responsibility to make sure that CMake finds all required dependencies. It is possible to look at your distribution PrusaSlicer package to see how the package maintainers solved the dependency issues.
|
||||
|
||||
#### wxWidgets
|
||||
By default, PrusaSlicer looks for wxWidgets 3.1. Our build script in fact downloads specific patched version of wxWidgets. If you want to link against wxWidgets 3.0 (which are still provided by most distributions because wxWidgets 3.1 have not yet been declared stable), you must set `-DSLIC3R_WX_STABLE=ON` when running CMake. Note that while PrusaSlicer can be linked against wWidgets 3.0, the combination is not well tested and there might be bugs in the resulting application.
|
||||
|
||||
When building on ubuntu 20.04 focal fossa, the package libwxgtk3.0-gtk3-dev needs to be installed instead of libwxgtk3.0-dev and you should use:
|
||||
```
|
||||
-DSLIC3R_WX_STABLE=1 -DSLIC3R_GTK=3
|
||||
```
|
||||
|
||||
## Miscellaneous
|
||||
|
||||
### Installation
|
||||
|
||||
At runtime, PrusaSlicer needs a way to access its resource files. By default, it looks for a `resources` directory relative to its binary.
|
||||
|
||||
If you instead want PrusaSlicer installed in a structure according to the File System Hierarchy Standard, use the `SLIC3R_FHS` flag
|
||||
|
||||
cmake .. -DSLIC3R_FHS=1
|
||||
|
||||
This will make PrusaSlicer look for a fixed-location `share/slic3r-prusa3d` directory instead (note that the location becomes hardcoded).
|
||||
|
||||
You can then use the `make install` target to install PrusaSlicer.
|
||||
|
||||
### Desktop Integration (PrusaSlicer 2.4 and newer)
|
||||
|
||||
If PrusaSlicer is to be distributed as an AppImage or a binary blob (.tar.gz and similar), then a desktop integration support is compiled in by default: PrusaSlicer will offer to integrate with desktop by manually copying the desktop file and application icon into user's desktop configuration. The built-in desktop integration is also handy on Crosstini (Linux on Chrome OS).
|
||||
|
||||
If PrusaSlicer is compiled with `SLIC3R_FHS` enabled, then a desktop integration support will not be integrated. One may want to disable desktop integration by running
|
||||
|
||||
cmake .. -DSLIC3R_DESKTOP_INTEGRATION=0
|
||||
|
||||
when building PrusaSlicer for flatpack or snap, where the desktop integration is performed by the installer.
|
||||
|
||||
@@ -1,41 +1,109 @@
|
||||
|
||||
# Building Bambu Studio on Mac OS
|
||||
# Building PrusaSlicer on Mac OS
|
||||
|
||||
## Enviroment setup
|
||||
Install Following tools:
|
||||
- Xcode from app store
|
||||
- Cmake
|
||||
- git
|
||||
- gettext
|
||||
To build PrusaSlicer on Mac OS, you will need the following software:
|
||||
|
||||
Cmake, git, gettext can be installed from brew(brew install cmake git gettext)
|
||||
- XCode
|
||||
- CMake
|
||||
- git
|
||||
- gettext
|
||||
|
||||
## building the deps
|
||||
You need to build the dependence of BambuStudio first. (Only needs for the first time)
|
||||
XCode is available through Apple's App Store, the other three tools are available on
|
||||
[brew](https://brew.sh/) (use `brew install cmake git gettext` to install them).
|
||||
|
||||
Suppose you download the codes into /Users/_username_/work/projects/BambuStudio
|
||||
create a directory to store the dependence built: /Users/_username_/work/projects/BambuStudio_dep
|
||||
**(Please make sure to replace the username with the one on your computer)**
|
||||
### Dependencies
|
||||
|
||||
`cd BambuStudio/deps`
|
||||
`mkdir build;cd build`
|
||||
PrusaSlicer comes with a set of CMake scripts to build its dependencies, it lives in the `deps` directory.
|
||||
Open a terminal window and navigate to PrusaSlicer sources directory and then to `deps`.
|
||||
Use the following commands to build the dependencies:
|
||||
|
||||
for arm64 architecture
|
||||
`cmake ../ -DDESTDIR="/Users/username/work/projects/BambuStudio_dep" -DOPENSSL_ARCH="darwin64-arm64-cc"`
|
||||
for x86 architeccture
|
||||
`cmake ../ -DDESTDIR="/Users/username/work/projects/BambuStudio_dep" -DOPENSSL_ARCH="darwin64-x86_64-cc"`
|
||||
`make -jN` (N can be a number between 1 and the max cpu number)
|
||||
mkdir build
|
||||
cd build
|
||||
cmake ..
|
||||
make
|
||||
|
||||
## building the Bambu Studio
|
||||
create a directory to store the installed files at /Users/username/work/projects/BambuStudio/install_dir
|
||||
`cd BambuStudio`
|
||||
`mkdir install_dir`
|
||||
`mkdir build;cd build`
|
||||
This will create a dependencies bundle inside the `build/destdir` directory.
|
||||
You can also customize the bundle output path using the `-DDESTDIR=<some path>` option passed to `cmake`.
|
||||
|
||||
building it use cmake
|
||||
`cmake .. -DBBL_RELEASE_TO_PUBLIC=1 -DCMAKE_PREFIX_PATH="/Users/username/work/projects/BambuStudio_dep/usr/local" -DCMAKE_INSTALL_PREFIX="../install_dir" -DCMAKE_BUILD_TYPE=Release -DCMAKE_MACOSX_RPATH=ON -DCMAKE_INSTALL_RPATH="/Users/username/work/projects/BambuStudio_dep/usr/local" -DCMAKE_MACOSX_BUNDLE=on`
|
||||
`cmake --build . --target install --config Release -jN`
|
||||
**Warning**: Once the dependency bundle is installed in a destdir, the destdir cannot be moved elsewhere.
|
||||
(This is because wxWidgets hardcodes the installation path.)
|
||||
|
||||
building it use xcode
|
||||
`cmake .. -GXcode -DBBL_RELEASE_TO_PUBLIC=1 -DCMAKE_PREFIX_PATH="/Users/username/work/projects/BambuStudio_dep/usr/local" -DCMAKE_INSTALL_PREFIX="../install_dir" -DCMAKE_BUILD_TYPE=Release -DCMAKE_MACOSX_RPATH=ON -DCMAKE_INSTALL_RPATH="/Users/username/work/projects/BambuStudio_dep/usr/local" -DCMAKE_MACOSX_BUNDLE=on`
|
||||
then building it using Xcode
|
||||
FIXME The Cereal serialization library needs a tiny patch on some old OSX clang installations
|
||||
https://github.com/USCiLab/cereal/issues/339#issuecomment-246166717
|
||||
|
||||
|
||||
### Building PrusaSlicer
|
||||
|
||||
If dependencies are built without errors, you can proceed to build PrusaSlicer itself.
|
||||
Go back to top level PrusaSlicer sources directory and use these commands:
|
||||
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. -DCMAKE_PREFIX_PATH="$PWD/../deps/build/destdir/usr/local"
|
||||
|
||||
The `CMAKE_PREFIX_PATH` is the path to the dependencies bundle but with `/usr/local` appended - if you set a custom path
|
||||
using the `DESTDIR` option, you will need to change this accordingly. **Warning:** the `CMAKE_PREFIX_PATH` needs to be an absolute path.
|
||||
|
||||
The CMake command above prepares PrusaSlicer for building from the command line.
|
||||
To start the build, use
|
||||
|
||||
make -jN
|
||||
|
||||
where `N` is the number of CPU cores, so, for example `make -j4` for a 4-core machine.
|
||||
|
||||
Alternatively, if you would like to use XCode GUI, modify the `cmake` command to include the `-GXcode` option:
|
||||
|
||||
cmake .. -GXcode -DCMAKE_PREFIX_PATH="$PWD/../deps/build/destdir/usr/local"
|
||||
|
||||
and then open the `PrusaSlicer.xcodeproj` file.
|
||||
This should open up XCode where you can perform build using the GUI or perform other tasks.
|
||||
|
||||
### Note on Mac OS X SDKs
|
||||
|
||||
By default PrusaSlicer builds against whichever SDK is the default on the current system.
|
||||
|
||||
This can be customized. The `CMAKE_OSX_SYSROOT` option sets the path to the SDK directory location
|
||||
and the `CMAKE_OSX_DEPLOYMENT_TARGET` option sets the target OS X system version (eg. `10.14` or similar).
|
||||
Note you can set just one value and the other will be guessed automatically.
|
||||
In case you set both, the two settings need to agree with each other. (Building with a lower deployment target
|
||||
is currently unsupported because some of the dependencies don't support this, most notably wxWidgets.)
|
||||
|
||||
Please note that the `CMAKE_OSX_DEPLOYMENT_TARGET` and `CMAKE_OSX_SYSROOT` options need to be set the same
|
||||
on both the dependencies bundle as well as PrusaSlicer itself.
|
||||
|
||||
Official Mac PrusaSlicer builds are currently built against SDK 10.9 to ensure compatibility with older Macs.
|
||||
|
||||
_Warning:_ XCode may be set such that it rejects SDKs bellow some version (silently, more or less).
|
||||
This is set in the property list file
|
||||
|
||||
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Info.plist
|
||||
|
||||
To remove the limitation, simply delete the key `MinimumSDKVersion` from that file.
|
||||
|
||||
|
||||
# TL; DR
|
||||
|
||||
Works on a fresh installation of MacOS Catalina 10.15.6
|
||||
|
||||
- Install [brew](https://brew.sh/):
|
||||
- Open Terminal
|
||||
|
||||
- Enter:
|
||||
|
||||
```
|
||||
brew update
|
||||
brew install cmake git gettext
|
||||
brew upgrade
|
||||
git clone https://github.com/prusa3d/PrusaSlicer/
|
||||
cd PrusaSlicer/deps
|
||||
mkdir build
|
||||
cd build
|
||||
cmake ..
|
||||
make
|
||||
cd ../..
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. -DCMAKE_PREFIX_PATH="$PWD/../deps/build/destdir/usr/local"
|
||||
make
|
||||
src/prusa-slicer
|
||||
```
|
||||
|
||||
@@ -1,36 +1,216 @@
|
||||
# Building Bambu Studio on Windows
|
||||
# Step by Step Visual Studio 2019 Instructions
|
||||
|
||||
## Enviroment setup
|
||||
Install Following tools:
|
||||
- Visual Studio Community 2019 from [visualstudio.microsoft.com/vs/](https://visualstudio.microsoft.com/vs/) (Older versions are not supported as Bambu Studio requires support for C++17, and newer versions should also be ok);
|
||||
- Cmake from [cmake.org](https://cmake.org/download/)
|
||||
- Git from [gitforwindows.org](https://gitforwindows.org/)
|
||||
- Perl from [strawberryperl](https://strawberryperl.com/)
|
||||
### Install the tools
|
||||
|
||||
## building the deps
|
||||
Suppose you download the codes into D:/work/Projects/BambuStudio
|
||||
create a directory to store the dependence built: D:/work/Projects/BambuStudio_dep
|
||||
Install Visual Studio Community 2019 from [visualstudio.microsoft.com/vs/](https://visualstudio.microsoft.com/vs/). Older versions are not supported as PrusaSlicer requires support for C++17.
|
||||
Select all workload options for C++ and make sure to launch Visual Studio after install (to ensure that the full setup completes).
|
||||
|
||||
`cd BambuStudio/deps`
|
||||
`mkdir build;cd build`
|
||||
`cmake ../ -G "Visual Studio 16 2019" -DDESTDIR="D:/work/Projects/BambuStudio_dep" -DCMAKE_BUILD_TYPE=Release`
|
||||
`msbuild /m ALL_BUILD.vcxproj`
|
||||
Install git for Windows from [gitforwindows.org](https://gitforwindows.org/)
|
||||
Download and run the exe accepting all defaults
|
||||
|
||||
It takes "00:14:27.37" to finish it on my machine (11th Gen Intel(R) Core(TM) i9-11900 @2.50GHz 2.50 GHz, with 32.0 GB DDR)
|
||||
### Download sources
|
||||
|
||||
## building the Bambu Studio
|
||||
create a directory to store the installed files at D:/work/Projects/BambuStudio/install_dir
|
||||
`cd BambuStudio`
|
||||
`mkdir install_dir`
|
||||
`mkdir build;cd build`
|
||||
Clone the respository. To place it in C:\src\PrusaSlicer, run:
|
||||
```
|
||||
c:> mkdir src
|
||||
c:> cd src
|
||||
c:\src> git clone https://github.com/prusa3d/PrusaSlicer.git
|
||||
```
|
||||
|
||||
set -DWIN10SDK_PATH to your windows sdk path(for example: C:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0) in below command:
|
||||
`cmake .. -G "Visual Studio 16 2019" -DBBL_RELEASE_TO_PUBLIC=1 -DCMAKE_PREFIX_PATH="D:/work/Projects/BambuStudio_dep/usr/local" -DCMAKE_INSTALL_PREFIX="../install_dir" -DCMAKE_BUILD_TYPE=Release -DWIN10SDK_PATH="C:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0"`
|
||||
### Run the automatic build script
|
||||
|
||||
then build it using command
|
||||
`cmake --build . --target install --config Release`
|
||||
The script `build_win.bat` will automatically find the default Visual Studio installation, set up the build environment, and then run both CMake and MSBuild to generate the dependencies and application as needed. If you'd rather do these steps manually, you can skip to the [Manual Build Instructions](#manual-build-instructions) in the next section. Otherwise, just run the following command to get everything going with the default configs:
|
||||
|
||||
or building it under the Visual Studio 2019
|
||||
(set the BambuStudio_app_gui as start project)
|
||||

|
||||
```
|
||||
c:\src>cd c:\src\PrusaSlicer
|
||||
c:\src\PrusaSlicer>build_win.bat -d=..\PrusaSlicer-deps -r=console
|
||||
```
|
||||
|
||||
The build script will run for a while (over an hour, depending on your machine) and automatically perform the following steps:
|
||||
1. Configure and build [deps](#compile-the-dependencies) as RelWithDebInfo with `c:\src\PrusaSlicer-deps` as the destination directory
|
||||
2. Configure and build all [application targets](#compile-prusaslicer) as RelWithDebInfo
|
||||
3. Launch the resulting `prusa-slicer-console.exe` binary
|
||||
|
||||
You can change the above command line options to do things like:
|
||||
* Change the destination for the dependencies by pointing `-d` to a different directory such as: `build_win.bat -d=s:\PrusaSlicerDeps`
|
||||
* Open the solution in Visual Studio after the build completes by changing the `-r` switch to `-r=ide`
|
||||
* Generate a release build without debug info by adding `-c=Release` or a full debug build with `-c=Debug`
|
||||
* Perform an incremental application build (the default) with: `build_win.bat -s=app-dirty`
|
||||
* Clean and rebuild the application: `build_win.bat -s=app`
|
||||
* Clean and rebuild the dependencies: `build_win.bat -s=deps`
|
||||
* Clean and rebuild everything (app and deps): `build_win.bat -s=all`
|
||||
* _The full list of build script options can be listed by running:_ `build_win.bat -?`
|
||||
|
||||
### Troubleshooting
|
||||
|
||||
You're best off initiating builds from within Visual Studio for day-to-day development. However, the `build_win.bat` script can be very helpful if you run into build failures after updating your source tree. Here are some tips to keep in mind:
|
||||
* The last several lines of output from `build_win.bat` will usually have the most helpful error messages.
|
||||
* If CMake complains about missing binaries or paths (e.g. after updating Visual Studio), building with `build_win.bat` will force CMake to regenerate its cache on an error.
|
||||
* After a deps change, you may just need to rebuild everything with the `-s=all` switch.
|
||||
* Reading through the instructions in the next section may help diagnose more complex issues.
|
||||
|
||||
# Manual Build Instructions
|
||||
|
||||
_Follow the steps below if you want to understand how to perform a manual build, or if you're troubleshooting issues with the automatic build script._
|
||||
|
||||
### Compile the dependencies.
|
||||
Dependencies are updated seldomly, thus they are compiled out of the PrusaSlicer source tree.
|
||||
Go to the Windows Start Menu and Click on "Visual Studio 2019" folder, then select the ->"x64 Native Tools Command Prompt" to open a command window and run the following:
|
||||
```
|
||||
cd c:\src\PrusaSlicer\deps
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. -G "Visual Studio 16 2019" -DDESTDIR="c:\src\PrusaSlicer-deps"
|
||||
|
||||
msbuild /m ALL_BUILD.vcxproj // This took 13.5 minutes on my machine: core I7-7700K @ 4.2Ghz with 32GB main memory and 20min on a average laptop
|
||||
```
|
||||
|
||||
### Generate Visual Studio project file for PrusaSlicer, referencing the precompiled dependencies.
|
||||
Go to the Windows Start Menu and Click on "Visual Studio 2019" folder, then select the ->"x64 Native Tools Command Prompt" to open a command window and run the following:
|
||||
```
|
||||
cd c:\src\PrusaSlicer\
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. -G "Visual Studio 16 2019" -DCMAKE_PREFIX_PATH="c:\src\PrusaSlicer-deps\usr\local"
|
||||
```
|
||||
|
||||
Note that `CMAKE_PREFIX_PATH` must be absolute path. A relative path like "..\..\PrusaSlicer-deps\usr\local" does not work.
|
||||
|
||||
### Compile PrusaSlicer.
|
||||
|
||||
Double-click c:\src\PrusaSlicer\build\PrusaSlicer.sln to open in Visual Studio 2019.
|
||||
OR
|
||||
Open Visual Studio for C++ development (VS asks this the first time you start it).
|
||||
|
||||
Select PrusaSlicer_app_gui as your startup project (right-click->Set as Startup Project).
|
||||
|
||||
Run Build->Rebuild Solution once to populate all required dependency modules. This is NOT done automatically when you build/run. If you run both Debug and Release variants, you will need to do this once for each.
|
||||
|
||||
Debug->Start Debugging or press F5
|
||||
|
||||
PrusaSlicer should start. You're up and running!
|
||||
|
||||
note: Thanks to @douggorgen for the original guide, as an answer for a issue
|
||||
|
||||
|
||||
# The below information is out of date, but still useful for reference purposes
|
||||
|
||||
We have switched to MS Visual Studio 2019.
|
||||
|
||||
We don't use MSVS 2013 any more. At the moment we are in the process of creating new pre-built dependency bundles
|
||||
and updating this document. In the meantime, you will need to compile the dependencies yourself
|
||||
[the same way as before](#building-the-dependencies-package-yourself)
|
||||
except with CMake generators for MSVS 2019 instead of 2013.
|
||||
|
||||
Thank you for understanding.
|
||||
|
||||
---
|
||||
|
||||
# Building PrusaSlicer on Microsoft Windows
|
||||
|
||||
~~The currently supported way of building PrusaSlicer on Windows is with CMake and MS Visual Studio 2013.
|
||||
You can use the free [Visual Studio 2013 Community Edition](https://www.visualstudio.com/vs/older-downloads/).
|
||||
CMake installer can be downloaded from [the official website](https://cmake.org/download/).~~
|
||||
|
||||
~~Building with newer versions of MSVS (2015, 2017) may work too as reported by some of our users.~~
|
||||
|
||||
_Note:_ Thanks to [**@supermerill**](https://github.com/supermerill) for testing and inspiration for this guide.
|
||||
|
||||
### Dependencies
|
||||
|
||||
On Windows PrusaSlicer is built against statically built libraries.
|
||||
~~We provide a prebuilt package of all the needed dependencies. This package only works on Visual Studio 2013, so~~ if you are using a newer version of Visual Studio, you need to compile the dependencies yourself as per [below](#building-the-dependencies-package-yourself).
|
||||
The package comes in a several variants:
|
||||
|
||||
- ~~64 bit, Release mode only (41 MB, 578 MB unpacked)~~
|
||||
- ~~64 bit, Release and Debug mode (88 MB, 1.3 GB unpacked)~~
|
||||
- ~~32 bit, Release mode only (38 MB, 520 MB unpacked)~~
|
||||
- ~~32 bit, Release and Debug mode (74 MB, 1.1 GB unpacked)~~
|
||||
|
||||
When unsure, use the _Release mode only_ variant, the _Release and Debug_ variant is only needed for debugging & development.
|
||||
|
||||
If you're unsure where to unpack the package, unpack it into `C:\local\` (but it can really be anywhere).
|
||||
|
||||
Alternatively you can also compile the dependencies yourself, see below.
|
||||
|
||||
### Building PrusaSlicer with Visual Studio
|
||||
|
||||
First obtain the PrusaSlicer sources via either git or by extracting the source archive.
|
||||
|
||||
Then you will need to note down the so-called 'prefix path' to the dependencies, this is the location of the dependencies packages + `\usr\local` appended.
|
||||
For example on 64 bits this would be `C:\local\destdir-64\usr\local`. The prefix path will need to be passed to CMake.
|
||||
|
||||
When ready, open the relevant Visual Studio command line and `cd` into the directory with PrusaSlicer sources.
|
||||
Use these commands to prepare Visual Studio solution file:
|
||||
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. -G "Visual Studio 12 Win64" -DCMAKE_PREFIX_PATH="<insert prefix path here>"
|
||||
|
||||
Note that if you're building a 32-bit variant, you will need to change the `"Visual Studio 12 Win64"` to just `"Visual Studio 12"`.
|
||||
|
||||
Conversely, if you're using Visual Studio version other than 2013, the version number will need to be changed accordingly.
|
||||
|
||||
If `cmake` has finished without errors, go to the build directory and open the `PrusaSlicer.sln` solution file in Visual Studio.
|
||||
Before building, make sure you're building the right project (use one of those starting with `PrusaSlicer_app_...`) and that you're building
|
||||
with the right configuration, i.e. _Release_ vs. _Debug_. When unsure, choose _Release_.
|
||||
Note that you won't be able to build a _Debug_ variant against a _Release_-only dependencies package.
|
||||
|
||||
#### Installing using the `INSTALL` project
|
||||
|
||||
PrusaSlicer can be run from the Visual Studio or from Visual Studio's build directory (`src\Release` or `src\Debug`),
|
||||
but for longer-term usage you might want to install somewhere using the `INSTALL` project.
|
||||
By default, this installs into `C:\Program Files\PrusaSlicer`.
|
||||
To customize the install path, use the `-DCMAKE_INSTALL_PREFIX=<path of your choice>` when invoking `cmake`.
|
||||
|
||||
### Building from the command line
|
||||
|
||||
There are several options for building from the command line:
|
||||
|
||||
- [msbuild](https://docs.microsoft.com/en-us/visualstudio/msbuild/msbuild-reference?view=vs-2017&viewFallbackFrom=vs-2013)
|
||||
- [Ninja](https://ninja-build.org/)
|
||||
- [nmake](https://docs.microsoft.com/en-us/cpp/build/nmake-reference?view=vs-2017)
|
||||
|
||||
To build with msbuild, use the same CMake command as in previous paragraph and then build using
|
||||
|
||||
msbuild /m /P:Configuration=Release ALL_BUILD.vcxproj
|
||||
|
||||
To build with Ninja or nmake, replace the `-G` option in the CMake call with `-G Ninja` or `-G "NMake Makefiles"` , respectively.
|
||||
Then use either `ninja` or `nmake` to start the build.
|
||||
|
||||
To install, use `msbuild /P:Configuration=Release INSTALL.vcxproj` , `ninja install` , or `nmake install` .
|
||||
|
||||
### Building the dependencies package yourself
|
||||
|
||||
The dependencies package is built using CMake scripts inside the `deps` subdirectory of PrusaSlicer sources.
|
||||
(This is intentionally not interconnected with the CMake scripts in the rest of the sources.)
|
||||
|
||||
Open the preferred Visual Studio command line (64 or 32 bit variant) and `cd` into the directory with PrusaSlicer sources.
|
||||
Then `cd` into the `deps` directory and use these commands to build:
|
||||
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. -G "Visual Studio 16 2019" -DDESTDIR="C:\local\destdir-custom"
|
||||
msbuild /m ALL_BUILD.vcxproj
|
||||
|
||||
You can also use the Visual Studio GUI or other generators as mentioned above.
|
||||
|
||||
The `DESTDIR` option is the location where the bundle will be installed.
|
||||
This may be customized. If you leave it empty, the `DESTDIR` will be placed inside the same `build` directory.
|
||||
|
||||
Warning: If the `build` directory is nested too deep inside other folders, various file paths during the build
|
||||
become too long and the build might fail due to file writing errors (\*). For this reason, it is recommended to
|
||||
place the `build` directory relatively close to the drive root.
|
||||
|
||||
Note that the build variant that you may choose using Visual Studio (i.e. _Release_ or _Debug_ etc.) when building the dependency package is **not relevant**.
|
||||
The dependency build will by default build _both_ the _Release_ and _Debug_ variants regardless of what you choose in Visual Studio.
|
||||
You can disable building of the debug variant by passing the
|
||||
|
||||
-DDEP_DEBUG=OFF
|
||||
|
||||
option to CMake, this will only produce a _Release_ build.
|
||||
|
||||
Refer to the CMake scripts inside the `deps` directory to see which dependencies are built in what versions and how this is done.
|
||||
|
||||
\*) Specifically, the problem arises when building boost. Boost build tool appends all build options into paths of
|
||||
intermediate files, which are not handled correctly by either `b2.exe` or possibly `ninja` (?).
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# Localization and translation guide
|
||||
|
||||
The purpose of this guide is to describe how to contribute to the Bambu Studio translations. We use GNUgettext for extracting string resources from the project and PoEdit for editing translations.
|
||||
The purpose of this guide is to describe how to contribute to the PrusaSlicer translations. We use GNUgettext for extracting string resources from the project and PoEdit for editing translations.
|
||||
|
||||
Those can be downloaded here:
|
||||
- https://sourceforge.net/directory/os:windows/?q=gnu+gettext GNUgettext package contains a set of tools to extract strings from the source code and to create the translation Catalog.
|
||||
@@ -12,42 +12,41 @@ Full manual for GNUgettext can be seen here: http://www.gnu.org/software/gettext
|
||||
|
||||
|
||||
### Scenario 1. How do I add a translation or fix an existing translation
|
||||
1. Get PO-file 'BambuStudio_xx.pot' from corresponding sub-folder here:
|
||||
https://github.com/bambulab/BambuStudio/tree/master/bbl/i18n
|
||||
1. Get PO-file from corresponding folder here:
|
||||
https://github.com/prusa3d/PrusaSlicer/tree/master/resources/localization
|
||||
2. Open this file in PoEdit as "Edit a translation"
|
||||
3. Apply your corrections to the translation
|
||||
4. Push changed BambuStudio_xx.po into the original folder
|
||||
5. copy BambuStudio_xx.mo into resources/i18n/xx and rename it to BambuStudio.mo, then push the changed file.
|
||||
4. Push changed PrusaSlicer.po and PrusaSlicer.mo (will create automatically after saving of PrusaSlicer.po in PoEdit) into the original folder.
|
||||
|
||||
### Scenario 2. How do I add a new language support
|
||||
1. Get file BambuStudio.pot here :
|
||||
https://github.com/bambulab/BambuStudio/tree/master/bbl/i18n
|
||||
1. Get file PrusaSlicer.pot here :
|
||||
https://github.com/prusa3d/PrusaSlicer/tree/master/resources/localization
|
||||
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 BambuStudio_fr.po
|
||||
- Click "Save file" button. BambuStudio_fr.mo will be created immediately
|
||||
- Bambu_Studio_fr.po needs to be copied into the sub-folder fr of https://github.com/bambulab/BambuStudio/tree/master/bbl/i18n, and be pushed
|
||||
- copy BambuStudio_xx.mo into resources/i18n/xx and rename it to BambuStudio.mo, then push the changed file.
|
||||
- Rename the file to PrusaSlicer.po
|
||||
- Click "Save file" button. PrusaSlicer.mo will be created immediately
|
||||
- Both PrusaSlicer.po and PrusaSlicer.mo have to be saved here:
|
||||
https://github.com/prusa3d/PrusaSlicer/tree/master/resources/localization/fr
|
||||
( name of folder "fr" means "French" - the translation language).
|
||||
|
||||
### Scenario 3. How do I add a new text resource when implementing a feature to Bambu Studio
|
||||
Each string resource in Bambu Studio available for translation needs to be explicitly marked using L() macro like this:
|
||||
### Scenario 3. How do I add a new text resource when implementing a feature to PrusaSlicer
|
||||
Each string resource in PrusaSlicer 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 Bambu Studio as an example
|
||||
### Scenario 4. How do I use GNUgettext to localize my own application taking PrusaSlicer as an example
|
||||
|
||||
1. For convenience create a list of files with this macro `L(s)`. We have
|
||||
https://github.com/bambulab/BambuStudio/blob/master/bbl/i18n/list.txt.
|
||||
https://github.com/prusa3d/PrusaSlicer/tree/master/resources/localization/list.txt.
|
||||
|
||||
2. Create template file(*.POT) with GNUgettext command:
|
||||
```
|
||||
xgettext --keyword=L --add-comments=TRN --from-code=UTF-8 --debug -o BambuStudio.pot -f list.txt
|
||||
xgettext --keyword=L --add-comments=TRN --from-code=UTF-8 --debug -o PrusaSlicer.pot -f list.txt
|
||||
```
|
||||
|
||||
Use flag `--from-code=UTF-8` to specify that the source strings are in UTF-8 encoding
|
||||
@@ -75,14 +74,14 @@ https://github.com/bambulab/BambuStudio/blob/master/bbl/i18n/list.txt.
|
||||
When you have Catalog to translation open POT or PO file in PoEdit and start translating.
|
||||
|
||||
|
||||
## General guidelines for Bambu Studio translators
|
||||
## General guidelines for PrusaSlicer 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 Bambu Studio.mo, and you can run Bambu Studio (see above).
|
||||
- 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 PrusaSlicer.mo, and you can run PrusaSlicer (see above).
|
||||
|
||||
- If you see an encoding error (garbage characters instead of Unicode) somewhere in Bambu Studio, report it. It is likely not a problem of your translation, but a bug in the software.
|
||||
- If you see an encoding error (garbage characters instead of Unicode) somewhere in PrusaSlicer, 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:
|
||||
|
||||
|
||||
BIN
doc/images/long_text_on_button.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
@@ -1,18 +0,0 @@
|
||||
**新功能**
|
||||
1. 3D文字工具
|
||||
2. 对象和拷贝间的数据共享
|
||||
3. 参数表格
|
||||
4. 用户指南
|
||||
5. 支持Arachne特性
|
||||
|
||||
**改进**
|
||||
1. 支持导出通用的3mf格式,兼容其他切片软件
|
||||
2. 优化混合支撑和树状支撑的生成速度
|
||||
3. 支持不停靠工具头的延迟摄影
|
||||
4. 支持纹理PEI热床
|
||||
5. 支持导入和导出预设
|
||||
6. 支持随机位置的接缝设置
|
||||
7. 支持匈牙利语
|
||||
8. 一些关键问题修复
|
||||
|
||||
详细信息请查看:https://github.com/bambulab/BambuStudio/releases
|
||||
@@ -1,18 +0,0 @@
|
||||
**New Features**
|
||||
1. 3D text tool
|
||||
2. Shared data between an object and its copies
|
||||
3. Parameter table
|
||||
4. User manual
|
||||
5. Arachne feature
|
||||
|
||||
**Improvements**
|
||||
1. Added support for exporting generic 3mf that is compatible with other slicers
|
||||
2. Optimized the performance of hybrid and tree support
|
||||
3. Added traditional timelapse mode
|
||||
4. Added support for Textured PEI plate
|
||||
5. Added support for export/import preset
|
||||
6. Added random seam position
|
||||
7. Added Magyar translations
|
||||
8. Fixed some known bugs
|
||||
|
||||
For details, please check https://github.com/bambulab/BambuStudio/releases
|
||||
52
doc/updating/Updating.md
Normal file
@@ -0,0 +1,52 @@
|
||||
# Slic3r PE 1.40 configuration update
|
||||
|
||||
Slic3r PE 1.40.0 comes with a major re-work of the way configuration presets work.
|
||||
There are three new features:
|
||||
|
||||
+ A two-tier system of presets being divided into _System_ and _User_ groups
|
||||
+ Configuration snapshots
|
||||
+ Configuration updating from the internet
|
||||
|
||||
## System and User presets
|
||||
|
||||
- _System preset_: These are the presets that come with Slic3r PE installation. They come from a vendor configuration bundle (not individual files like before). They are **read-only** – a user cannot modify them, but may instead create a derived User preset based on a System preset
|
||||
- _User preset_: These are regular presets stored in files just like before. Additionally, they may be derived (inherited) from one of the System presets
|
||||
|
||||
A derived User preset keeps track of which settings are inherited from the parent System preset and which are modified by the user. When a system preset is updated (either via installation of a new Slic3r or automatically from the internet), in a User preset the settings that are modified by the user will stay that way, while the ones that are inherited reflect the updated System preset.
|
||||
|
||||
This system ensures that we don't overwrite user's settings when there is an update to the built in presets.
|
||||
|
||||
Slic3r GUI now displays accurately which settings are inherited and which are modified.
|
||||
A setting derived from a System preset is represented by green label and a locked lock icon:
|
||||
|
||||

|
||||
|
||||
A settings modified in a User preset has an open lock icon:
|
||||
|
||||

|
||||
|
||||
Clicking the open lock icon restores the system setting.
|
||||
|
||||
Additionally, any setting that is modified but not yet saved onto disk is represented by orange label and a back-arrow:
|
||||
|
||||

|
||||
|
||||
Clicking the back-arrow restores the value that was previously saved in this Preset.
|
||||
|
||||
## Configuration snapshots
|
||||
|
||||
Configuration snapshots can now be taken via the _Configuration_ menu.
|
||||
A snapshot contains complete configuration from the point when the snapshot was taken.
|
||||
Users may move back and forth between snapshots at will using a dialog:
|
||||
|
||||

|
||||
|
||||
|
||||
# Updating from the internet
|
||||
|
||||
Slic3r PE 1.40.0 checks for updates of the built-in System presets and downloads them.
|
||||
The first-time configuration assistant will ask you if you want to enable this feature - it is **not** mandatory.
|
||||
|
||||
Updates are checked for and downloaded in the background. If there's is an update, Slic3r will prompt about it
|
||||
next time it is launched, never during normal program operation. An update may be either accepted or refused.
|
||||
Before any update is applied a configuration snapshot (as described above) is taken.
|
||||
BIN
doc/updating/setting_mod.png
Normal file
|
After Width: | Height: | Size: 4.0 KiB |
BIN
doc/updating/setting_sys.png
Normal file
|
After Width: | Height: | Size: 3.8 KiB |
BIN
doc/updating/setting_user.png
Normal file
|
After Width: | Height: | Size: 3.9 KiB |
BIN
doc/updating/snapshots_dialog.png
Normal file
|
After Width: | Height: | Size: 77 KiB |
@@ -36,16 +36,15 @@
|
||||
},
|
||||
{
|
||||
"type": "po",
|
||||
"pattern": "bbl/i18n/hu/BambuStudio_hu.po",
|
||||
"lang": "hu"
|
||||
"pattern": "bbl/i18n/zh_cn/BambuStudio_zh_CN.po",
|
||||
"lang": "zh_cn"
|
||||
}
|
||||
]
|
||||
},
|
||||
"download": {
|
||||
"folder": "bbl/i18n",
|
||||
"includeSourceLang" : "true",
|
||||
"files": {
|
||||
"output": "${lang}/BambuStudio_${lang}.po"
|
||||
"output": "${lang}/BambuStudio_${lang}_new.po"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||