diff --git a/blast/VERSION.md b/blast/VERSION.md
index 50e2274e6..2d6c0bcf1 100644
--- a/blast/VERSION.md
+++ b/blast/VERSION.md
@@ -1 +1 @@
-5.0.3
+5.0.4
diff --git a/blast/deps/repo-deps.packman.xml b/blast/deps/repo-deps.packman.xml
index e175ebac4..eadeb933b 100644
--- a/blast/deps/repo-deps.packman.xml
+++ b/blast/deps/repo-deps.packman.xml
@@ -1,8 +1,8 @@
-
+
-
+
diff --git a/blast/docs/CHANGELOG.md b/blast/docs/CHANGELOG.md
index 5e18198dc..0003ba384 100644
--- a/blast/docs/CHANGELOG.md
+++ b/blast/docs/CHANGELOG.md
@@ -1,5 +1,11 @@
# Changelog
+## [5.0.4] - 22-January-2024
+
+### Bugfixes
+- Fixed issue https://github.com/NVIDIA-Omniverse/PhysX/issues/207, Island removal doesn't work as expected
+
+
## [5.0.3] - 1-November-2023
### Bugfixes
diff --git a/blast/source/sdk/extensions/authoring/NvBlastExtAuthoringFractureToolImpl.cpp b/blast/source/sdk/extensions/authoring/NvBlastExtAuthoringFractureToolImpl.cpp
index 0cc363a7e..8223bc710 100644
--- a/blast/source/sdk/extensions/authoring/NvBlastExtAuthoringFractureToolImpl.cpp
+++ b/blast/source/sdk/extensions/authoring/NvBlastExtAuthoringFractureToolImpl.cpp
@@ -573,7 +573,7 @@ Mesh* FractureToolImpl::createChunkMesh(int32_t chunkInfoIndex, bool splitUVs /*
if (splitUVs)
compactifyAndTransformVertexBuffer(_vertexBuffer, edges, sourceVertices, numSourceVerts, numEdges, tm);
else
- compactifyAndTransformVertexBuffer(_vertexBuffer, edges, sourceVertices, numSourceVerts, numEdges, tm);
+ compactifyAndTransformVertexBuffer(_vertexBuffer, edges, sourceVertices, numSourceVerts, numEdges, tm);
// now fix the order of the edges
// compacting the vertex buffer can put them out of order
@@ -629,7 +629,7 @@ Mesh* FractureToolImpl::createChunkMesh(int32_t chunkInfoIndex, bool splitUVs /*
vert.uv[0].x = (vert.uv[0].x - bnd.minimum.x) * scale;
vert.uv[0].y = (vert.uv[0].y - bnd.minimum.y) * scale;
}
-
+
// build a new mesh from the converted data
Mesh* chunkMesh = new MeshImpl(vertices, edges, facets, numVerts, numEdges, facetsCount);
NVBLAST_FREE(edges);
@@ -2105,8 +2105,11 @@ int32_t FractureToolImpl::islandDetectionAndRemoving(int32_t chunkId, bool creat
}
}
- if (createAtNewDepth == false || chunkId != 0)
+ if (createAtNewDepth == false)
{
+ // We need to flag the chunk as changed, in case someone is calling this function directly
+ // Otherwise when called as part of automatic island removal, chunks are already flagged as changed
+ mChunkData[chunkInfoIndex].isChanged = true;
delete mChunkData[chunkInfoIndex].getMesh();
Mesh* newMesh0 =
new MeshImpl(compVertices[0].data(), compEdges[0].data(), compFacets[0].data(),
diff --git a/blast/tools/packman/bootstrap/configure.bat b/blast/tools/packman/bootstrap/configure.bat
index 3dad020b1..1aff9d870 100644
--- a/blast/tools/packman/bootstrap/configure.bat
+++ b/blast/tools/packman/bootstrap/configure.bat
@@ -1,4 +1,4 @@
-:: Copyright 2019 NVIDIA CORPORATION
+:: Copyright 2019-2023 NVIDIA CORPORATION
::
:: Licensed under the Apache License, Version 2.0 (the "License");
:: you may not use this file except in compliance with the License.
@@ -12,7 +12,7 @@
:: See the License for the specific language governing permissions and
:: limitations under the License.
-set PM_PACKMAN_VERSION=6.56
+set PM_PACKMAN_VERSION=7.10.1
:: Specify where packman command is rooted
set PM_INSTALL_PATH=%~dp0..
@@ -59,7 +59,7 @@ if defined PM_PYTHON_EXT (
goto PACKMAN
)
-set PM_PYTHON_VERSION=3.7.13-nv1-windows-x86_64
+set PM_PYTHON_VERSION=3.10.5-1-windows-x86_64
set PM_PYTHON_BASE_DIR=%PM_PACKAGES_ROOT%\python
set PM_PYTHON_DIR=%PM_PYTHON_BASE_DIR%\%PM_PYTHON_VERSION%
set PM_PYTHON=%PM_PYTHON_DIR%\python.exe
@@ -95,11 +95,16 @@ if exist "%PM_PYTHON%" (
if exist "%PM_PYTHON_DIR%" ( rd /s /q "%PM_PYTHON_DIR%" > nul )
)
-:: Perform atomic rename
-rename "%TEMP_FOLDER_NAME%" "%PM_PYTHON_VERSION%" 1> nul
-:: Failure during move, need to clean up and abort
+:: Perform atomic move (allowing ovewrite, /y)
+move /y "%TEMP_FOLDER_NAME%" "%PM_PYTHON_DIR%" 1> nul
+:: Verify that python.exe is now where we expect
+if exist "%PM_PYTHON%" goto PACKMAN
+
+:: Wait a second and try again (can help with access denied weirdness)
+timeout /t 1 /nobreak 1> nul
+move /y "%TEMP_FOLDER_NAME%" "%PM_PYTHON_DIR%" 1> nul
if %errorlevel% neq 0 (
- echo !!! Error renaming python !!!
+ echo !!! Error moving python %TEMP_FOLDER_NAME% -> %PM_PYTHON_DIR% !!!
call :CLEAN_UP_TEMP_FOLDER
goto ERROR
)
@@ -114,7 +119,7 @@ if defined PM_MODULE_DIR_EXT (
set PM_MODULE=%PM_MODULE_DIR%\run.py
-if exist "%PM_MODULE%" goto ENSURE_7ZA
+if exist "%PM_MODULE%" goto END
:: Clean out broken PM_MODULE_DIR if it exists
if exist "%PM_MODULE_DIR%" ( rd /s /q "%PM_MODULE_DIR%" > nul )
@@ -137,19 +142,6 @@ if %errorlevel% neq 0 (
del "%TARGET%"
-:ENSURE_7ZA
-set PM_7Za_VERSION=22.01-1
-set PM_7Za_PATH=%PM_PACKAGES_ROOT%\7za\%PM_7ZA_VERSION%
-if exist "%PM_7Za_PATH%" goto END
-set PM_7Za_PATH=%PM_PACKAGES_ROOT%\chk\7za\%PM_7ZA_VERSION%
-if exist "%PM_7Za_PATH%" goto END
-
-"%PM_PYTHON%" -S -s -u -E "%PM_MODULE%" pull "%PM_MODULE_DIR%\deps.packman.xml"
-if %errorlevel% neq 0 (
- echo !!! Error fetching packman dependencies !!!
- goto ERROR
-)
-
goto END
:ERROR_MKDIR_PACKAGES_ROOT
diff --git a/blast/tools/packman/config.packman.xml b/blast/tools/packman/config.packman.xml
index d8e5083a6..6e36e665f 100644
--- a/blast/tools/packman/config.packman.xml
+++ b/blast/tools/packman/config.packman.xml
@@ -1,6 +1,7 @@
-
-
+
+
+
diff --git a/blast/tools/packman/packman b/blast/tools/packman/packman
index cd4dfd34b..75c78aae5 100644
--- a/blast/tools/packman/packman
+++ b/blast/tools/packman/packman
@@ -1,6 +1,6 @@
#!/bin/bash
-# Copyright 2019-2020 NVIDIA CORPORATION
+# Copyright 2019-2023 NVIDIA CORPORATION
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -18,11 +18,13 @@ set -eu
if echo ${PM_VERBOSITY-} | grep -i "debug" > /dev/null ; then
set -x
+ PM_CURL_SILENT=""
+ PM_WGET_QUIET=""
else
PM_CURL_SILENT="-s -S"
PM_WGET_QUIET="--quiet"
fi
-PM_PACKMAN_VERSION=6.56
+PM_PACKMAN_VERSION=7.10.1
# This is necessary for newer macOS
if [ `uname` == 'Darwin' ]; then
@@ -85,7 +87,7 @@ install_python()
{
PLATFORM=`uname`
PROCESSOR=`uname -m`
- PYTHON_VERSION=3.7.13-nv1
+ PYTHON_VERSION=3.10.5-1
if [ $PLATFORM == 'Darwin' ]; then
PYTHON_PACKAGE=$PYTHON_VERSION-macos-x86_64
@@ -154,20 +156,6 @@ if [ ! -f "$PM_MODULE" ]; then
fi
fi
-# Ensure 7za package exists:
-PM_7za_VERSION=22.01-1
-export PM_7za_PATH="$PM_PACKAGES_ROOT/7za/$PM_7za_VERSION"
-if [ ! -d "$PM_7za_PATH" ]; then
- export PM_7za_PATH="$PM_PACKAGES_ROOT/chk/7za/$PM_7za_VERSION"
- if [ ! -d "$PM_7za_PATH" ]; then
- "$PM_PYTHON" -S -s -u -E "$PM_MODULE" pull "$PM_MODULE_DIR/deps.packman.xml"
- if [ "$?" -ne 0 ]; then
- echo "Failure while installing required 7za package"
- exit 1
- fi
- fi
-fi
-
# Generate temporary file name for environment variables:
PM_VAR_PATH=`mktemp -u -t tmp.$$.pmvars.XXXXXX`
diff --git a/blast/tools/packman/packman.cmd b/blast/tools/packman/packman.cmd
index b1be5d8b4..e55b2f0e1 100644
--- a/blast/tools/packman/packman.cmd
+++ b/blast/tools/packman/packman.cmd
@@ -1,11 +1,12 @@
:: RUN_PM_MODULE must always be at the same spot for packman update to work (batch reloads file during update!)
-:: [xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]
+:: [xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]
:: Reset errorlevel status (don't inherit from caller)
@call :ECHO_AND_RESET_ERROR
-:: You can remove the call below if you do your own manual configuration of the dev machines
-call "%~dp0\bootstrap\configure.bat"
+:: You can remove this section if you do your own manual configuration of the dev machines
+call :CONFIGURE
if %errorlevel% neq 0 ( exit /b %errorlevel% )
+
:: Everything below is mandatory
if not defined PM_PYTHON goto :PYTHON_ENV_ERROR
if not defined PM_MODULE goto :MODULE_ENV_ERROR
@@ -46,6 +47,7 @@ exit /b 1
@echo Error while processing and setting environment variables!
exit /b 1
+:: pad [xxxx]
:ECHO_AND_RESET_ERROR
@echo off
if /I "%PM_VERBOSITY%"=="debug" (
@@ -58,3 +60,30 @@ exit /b 0
for /f "delims=" %%a in ('%PM_PYTHON% -S -s -u -E -c "import tempfile;file = tempfile.NamedTemporaryFile(mode='w+t', delete=False);print(file.name)"') do (set PM_VAR_PATH=%%a)
set PM_VAR_PATH_ARG=--var-path="%PM_VAR_PATH%"
goto :RUN_PM_MODULE
+
+:CONFIGURE
+:: Must capture and set code page to work around issue #279, powershell invocation mutates console font
+:: This issue only happens in Windows CMD shell when using 65001 code page. Some Git Bash implementations
+:: don't support chcp so this workaround is a bit convoluted.
+:: Test for chcp:
+chcp > nul 2>&1
+if %errorlevel% equ 0 (
+ for /f "tokens=2 delims=:" %%a in ('chcp') do (set PM_OLD_CODE_PAGE=%%a)
+) else (
+ call :ECHO_AND_RESET_ERROR
+)
+:: trim leading space (this is safe even when PM_OLD_CODE_PAGE has not been set)
+set PM_OLD_CODE_PAGE=%PM_OLD_CODE_PAGE:~1%
+if "%PM_OLD_CODE_PAGE%" equ "65001" (
+ chcp 437 > nul
+ set PM_RESTORE_CODE_PAGE=1
+)
+call "%~dp0\bootstrap\configure.bat"
+set PM_CONFIG_ERRORLEVEL=%errorlevel%
+if defined PM_RESTORE_CODE_PAGE (
+ :: Restore code page
+ chcp %PM_OLD_CODE_PAGE% > nul
+)
+set PM_OLD_CODE_PAGE=
+set PM_RESTORE_CODE_PAGE=
+exit /b %PM_CONFIG_ERRORLEVEL%
diff --git a/blast/tools/packman/packmanconf.py b/blast/tools/packman/packmanconf.py
index 48d0e37d3..539d05625 100644
--- a/blast/tools/packman/packmanconf.py
+++ b/blast/tools/packman/packmanconf.py
@@ -34,9 +34,9 @@ def init():
"""
major = sys.version_info[0]
minor = sys.version_info[1]
- if major != 3 or minor != 7:
+ if major != 3 or minor != 10:
raise RuntimeError(
- f"This version of packman requires Python 3.7.x, but {major}.{minor} was provided"
+ f"This version of packman requires Python 3.10.x, but {major}.{minor} was provided"
)
conf_dir = os.path.dirname(os.path.abspath(__file__))
os.environ["PM_INSTALL_PATH"] = conf_dir
@@ -56,7 +56,7 @@ def get_packages_root(conf_dir: str) -> str:
elif platform_name == "Darwin":
# macOS
root = os.path.join(
- os.path.expanduser("~"), "/Library/Application Support/packman-cache"
+ os.path.expanduser("~"), "Library/Application Support/packman-cache"
)
elif platform_name == "Linux":
try:
diff --git a/blast/tools/packman/python.bat b/blast/tools/packman/python.bat
index ef37691b2..08df74f8a 100644
--- a/blast/tools/packman/python.bat
+++ b/blast/tools/packman/python.bat
@@ -13,9 +13,20 @@
:: limitations under the License.
@echo off
-setlocal
+setlocal enableextensions
call "%~dp0\packman" init
set "PYTHONPATH=%PM_MODULE_DIR%;%PYTHONPATH%"
-set PYTHONNOUSERSITE=1
-"%PM_PYTHON%" -u %*
+
+if not defined PYTHONNOUSERSITE (
+ set PYTHONNOUSERSITE=1
+)
+
+REM For performance, default to unbuffered; however, allow overriding via
+REM PYTHONUNBUFFERED=0 since PYTHONUNBUFFERED on windows can truncate output
+REM when printing long strings
+if not defined PYTHONUNBUFFERED (
+ set PYTHONUNBUFFERED=1
+)
+
+"%PM_PYTHON%" %*
\ No newline at end of file
diff --git a/blast/tools/packman/python.sh b/blast/tools/packman/python.sh
index 37c9f1b89..74328bf0d 100755
--- a/blast/tools/packman/python.sh
+++ b/blast/tools/packman/python.sh
@@ -22,11 +22,21 @@ if [ ! -f "$PACKMAN_CMD" ]; then
fi
source "$PACKMAN_CMD" init
export PYTHONPATH="${PM_MODULE_DIR}:${PYTHONPATH}"
-export PYTHONNOUSERSITE=1
+
+if [ -z "${PYTHONNOUSERSITE:-}" ]; then
+ export PYTHONNOUSERSITE=1
+fi
+
+# For performance, default to unbuffered; however, allow overriding via
+# PYTHONUNBUFFERED=0 since PYTHONUNBUFFERED on windows can truncate output
+# when printing long strings
+if [ -z "${PYTHONUNBUFFERED:-}" ]; then
+ export PYTHONUNBUFFERED=1
+fi
# workaround for our python not shipping with certs
if [[ -z ${SSL_CERT_DIR:-} ]]; then
export SSL_CERT_DIR=/etc/ssl/certs/
fi
-"${PM_PYTHON}" -u "$@"
+"${PM_PYTHON}" "$@"