Skip to content

Commit d32f2cc

Browse files
committed
Merge branch 'release-260630' into HEAD
1 parent 010c71d commit d32f2cc

1,259 files changed

Lines changed: 518521 additions & 216245 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,3 +65,5 @@ __pycache__
6565
docs
6666
flatbuild
6767
/.edge-zentao-profile
68+
/resources/web/chat/node_modules/
69+
/tools/updater/*.syso

.vscode/launch.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"configurations": [
44
{
55
"name": "C3DSlicer: Launch",
6-
"type": "lldb",
6+
"type": "cppvsdbg",
77
"request": "launch",
88
"program": "${command:cmake.launchTargetPath}",
99
"args": [],
@@ -25,6 +25,8 @@
2525
},
2626
"windows": {
2727
"type": "cppvsdbg",
28+
"program": "${workspaceFolder}\\build_Release\\src\\Release\\CrealityPrint.exe",
29+
"cwd": "${workspaceFolder}\\build_Release\\src\\Release",
2830
"env": {
2931
"SLIC3R_RESOURCES_DIR": "${workspaceFolder}/resources"
3032
}
@@ -41,4 +43,4 @@
4143
}
4244
}
4345
]
44-
}
46+
}

CMakeLists.txt

Lines changed: 82 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,32 @@ elseif(BUILD_OS_OSX)
2929
set(BUILD_OS "macx")
3030
endif()
3131

32+
if (NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
33+
message(STATUS "No build type selected, default to Release")
34+
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Build type (default Release)" FORCE)
35+
endif()
36+
37+
set(CXAGENT_DEBUG_API_BASE "http://127.0.0.1:8787" CACHE STRING "CxAgent API base used for Debug/RelWithDebInfo builds")
38+
set(CXAGENT_RELEASE_API_BASE "http://cxagent.crealitycloud.cn" CACHE STRING "CxAgent API base used for Release/MinSizeRel builds")
39+
40+
if (NOT "$ENV{CXAGENT_DEBUG_API_BASE}" STREQUAL "")
41+
set(CXAGENT_DEBUG_API_BASE "$ENV{CXAGENT_DEBUG_API_BASE}" CACHE STRING "CxAgent API base used for Debug/RelWithDebInfo builds" FORCE)
42+
endif()
43+
if (NOT "$ENV{CXAGENT_RELEASE_API_BASE}" STREQUAL "")
44+
set(CXAGENT_RELEASE_API_BASE "$ENV{CXAGENT_RELEASE_API_BASE}" CACHE STRING "CxAgent API base used for Release/MinSizeRel builds" FORCE)
45+
endif()
46+
if (NOT "$ENV{CXAGENT_API_BASE}" STREQUAL "")
47+
set(CXAGENT_DEBUG_API_BASE "$ENV{CXAGENT_API_BASE}" CACHE STRING "CxAgent API base used for Debug/RelWithDebInfo builds" FORCE)
48+
set(CXAGENT_RELEASE_API_BASE "$ENV{CXAGENT_API_BASE}" CACHE STRING "CxAgent API base used for Release/MinSizeRel builds" FORCE)
49+
endif()
50+
51+
if ("${CMAKE_BUILD_TYPE}" STREQUAL "Debug" OR "${CMAKE_BUILD_TYPE}" STREQUAL "RelWithDebInfo")
52+
set(CXAGENT_DEFAULT_API_BASE "${CXAGENT_DEBUG_API_BASE}")
53+
else()
54+
set(CXAGENT_DEFAULT_API_BASE "${CXAGENT_RELEASE_API_BASE}")
55+
endif()
56+
message(STATUS "CXAGENT_DEFAULT_API_BASE for ${CMAKE_BUILD_TYPE}: ${CXAGENT_DEFAULT_API_BASE}")
57+
3258
include(ConfigureAllModules)
3359
__configure_build_info_header(
3460
customized
@@ -55,11 +81,6 @@ message("PROCESS_NAME=${PROCESS_NAME}")
5581
set(SLIC3R_RESOURCES_DIR "${CMAKE_CURRENT_SOURCE_DIR}/resources")
5682
file(TO_NATIVE_PATH "${SLIC3R_RESOURCES_DIR}" SLIC3R_RESOURCES_DIR_WIN)
5783

58-
if (NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
59-
message(STATUS "No build type selected, default to Release")
60-
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Build type (default Release)" FORCE)
61-
endif()
62-
6384
if(DEFINED ENV{SLIC3R_STATIC})
6485
set(SLIC3R_STATIC_INITIAL $ENV{SLIC3R_STATIC})
6586
else()
@@ -81,6 +102,8 @@ option(SLIC3R_MSVC_COMPILE_PARALLEL "Compile on Visual Studio in parallel" 1)
81102
option(SLIC3R_MSVC_PDB "Generate PDB files on MSVC in Release mode" 1)
82103
option(SLIC3R_PERL_XS "Compile XS Perl module and enable Perl unit and integration tests" 0)
83104
option(SLIC3R_ASAN "Enable ASan on Clang and GCC" 0)
105+
option(SLIC3R_ENABLE_TIME_ANALYTICS_EXPORT "Enable exporting slicer time analytics artifacts (layer/custom/prepare/thumbnail/meta)" 0)
106+
option(SLIC3R_ENABLE_GCODE_IMPORT_PROFILE_OVERLAY_FOR_TEST "Enable test-only online printer profile overlay when importing G-code" 0)
84107
option(GENERATE_ORCA_HEADER "Enable generate header" 1)
85108

86109
# If SLIC3R_FHS is 1 -> SLIC3R_DESKTOP_INTEGRATION is always 0, othrewise variable.
@@ -135,6 +158,14 @@ if(SLIC3R_DESKTOP_INTEGRATION)
135158
add_definitions(-DSLIC3R_DESKTOP_INTEGRATION)
136159
endif ()
137160

161+
if (SLIC3R_ENABLE_TIME_ANALYTICS_EXPORT)
162+
add_definitions(-DSLIC3R_ENABLE_TIME_ANALYTICS_EXPORT)
163+
endif ()
164+
165+
if (SLIC3R_ENABLE_GCODE_IMPORT_PROFILE_OVERLAY_FOR_TEST)
166+
add_definitions(-DSLIC3R_ENABLE_GCODE_IMPORT_PROFILE_OVERLAY_FOR_TEST)
167+
endif ()
168+
138169
if (MSVC AND CMAKE_CXX_COMPILER_ID STREQUAL Clang)
139170
set(IS_CLANG_CL TRUE)
140171

@@ -278,6 +309,52 @@ if(WIN32)
278309
endif()
279310
endif()
280311

312+
option(SLIC3R_ENABLE_IMATISTL "Enable ImatiSTL mesh repair backend on Linux/macOS" ON)
313+
314+
set(HAS_IMATISTL FALSE)
315+
unset(IMATISTL_INCLUDE_DIR)
316+
unset(IMATISTL_LIBRARY)
317+
unset(IMATISTL_DEP_LIBRARIES)
318+
319+
if (SLIC3R_ENABLE_IMATISTL AND (APPLE OR CMAKE_SYSTEM_NAME STREQUAL "Linux"))
320+
find_path(IMATISTL_INCLUDE_DIR
321+
NAMES imatistl.h ImatiSTL/imatistl.h
322+
PATH_SUFFIXES include include/ImatiSTL)
323+
find_library(IMATISTL_LIBRARY
324+
NAMES ImatiSTL imatiSTL imatistl
325+
PATH_SUFFIXES lib)
326+
find_library(IMATISTL_GMP_LIBRARY
327+
NAMES gmp libgmp
328+
PATH_SUFFIXES lib)
329+
find_library(IMATISTL_MPFR_LIBRARY
330+
NAMES mpfr libmpfr
331+
PATH_SUFFIXES lib)
332+
333+
if (IMATISTL_INCLUDE_DIR)
334+
get_filename_component(_imatistl_include_leaf "${IMATISTL_INCLUDE_DIR}" NAME)
335+
if (_imatistl_include_leaf STREQUAL "ImatiSTL")
336+
get_filename_component(IMATISTL_INCLUDE_DIR "${IMATISTL_INCLUDE_DIR}" DIRECTORY)
337+
endif()
338+
endif()
339+
340+
if (IMATISTL_INCLUDE_DIR AND IMATISTL_LIBRARY)
341+
set(HAS_IMATISTL TRUE)
342+
if (IMATISTL_MPFR_LIBRARY)
343+
list(APPEND IMATISTL_DEP_LIBRARIES ${IMATISTL_MPFR_LIBRARY})
344+
endif()
345+
if (IMATISTL_GMP_LIBRARY)
346+
list(APPEND IMATISTL_DEP_LIBRARIES ${IMATISTL_GMP_LIBRARY})
347+
endif()
348+
message("Building with ImatiSTL mesh repair support (deps/system library)")
349+
else()
350+
message("Building without ImatiSTL mesh repair support")
351+
endif()
352+
endif()
353+
354+
if (HAS_IMATISTL)
355+
add_definitions(-DHAS_IMATISTL)
356+
endif()
357+
281358
if (APPLE)
282359
message("OS X SDK Path: ${CMAKE_OSX_SYSROOT}")
283360
if (CMAKE_OSX_DEPLOYMENT_TARGET)

CMakePresets.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@
6464
"cacheVariables": {
6565
"CMAKE_BUILD_TYPE": "Release",
6666
"CMAKE_PREFIX_PATH": "${sourceDir}/deps/build/OrcaSlicer_dep/usr/local/",
67-
"CX_DEBUG": "1",
6867
"CMAKE_EXPORT_COMPILE_COMMANDS":"1",
6968
"BOOST_HAS_THREADS": "1",
7069
"CMAKE_C_COMPILER_LAUNCHER":"ccache",

0 commit comments

Comments
 (0)