Skip to content

Commit 6c46445

Browse files
authored
Merge pull request #58 from EpicGames/release_1.3.0
Update for 1.3.0 release
2 parents 47a3a04 + 9839c8f commit 6c46445

Some content is hidden

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

60 files changed

+24367
-779
lines changed

CHANGELOG.md

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,31 @@
22

33
All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/).
44

5+
6+
## [1.3.0] - 2024-08-15
7+
8+
### Added
9+
- support for Maya 2024
10+
- support for Python 3.11
11+
- added source code comments to python wrappers
12+
13+
### Fixed
14+
- `CalculateMeshLowerLODsCommand` was rewritten to address edge cases discovered with eyelashes and to handle some common cases of invalid UV data.
15+
- `RotateCommand` to rotate blend shape target deltas as well.
16+
- `SetBlendShapeTargetDeltasCommand` to allow setting vertex indices as well.
17+
- Swig generated classes are now wrapped instead of being monkey-patched to invoke constructors and destructors (which allows building with newer Swig versions - 4.0.x and 4.1.x).
18+
19+
### Changed
20+
- CMake files to add test cases that execute the example scripts and allow generating bundled archives with CPack.
21+
- Binaries for embeddedRL4 plugin to be .so files.
22+
23+
24+
## [1.2.0] - 2023-06-30
25+
26+
### Added
27+
- assets (gui.ma, Ada.dna, additional_assemble_script.py) which support MHC 2.x.x releases (UE 5.2 and 5.3)
28+
29+
530
## [1.1.0] - 2023-04-20
631

732
### Added
@@ -26,4 +51,4 @@ All notable changes to this project will be documented in this file. This projec
2651
- option to pass list of indices to remove in remove commands.
2752

2853
### Removed
29-
- removed method `assemble_rig` from DNAViewer API.
54+
- removed method `assemble_rig` from DNAViewer API.

dnacalib/CMakeLists.txt

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,25 @@ project(dnacalib)
33

44
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/CMakeModulesExtra")
55

6+
enable_testing()
7+
68
add_subdirectory(DNACalib)
79
add_subdirectory(SPyUS)
810
add_subdirectory(PyDNA)
911
add_subdirectory(PyDNACalib)
12+
13+
################################################
14+
# Package build artifacts
15+
set(CPACK_GENERATOR "ZIP")
16+
set(CPACK_ARCHIVE_COMPONENT_INSTALL ON)
17+
set(CPACK_COMPONENT_INCLUDE_TOPLEVEL_DIRECTORY OFF)
18+
set(CPACK_COMPONENTS_GROUPING ALL_COMPONENTS_IN_ONE)
19+
string(CONCAT CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}"
20+
"-${CMAKE_PROJECT_VERSION}"
21+
"-${CMAKE_SYSTEM_NAME}"
22+
"-${CMAKE_SYSTEM_PROCESSOR}"
23+
"-${CMAKE_CXX_COMPILER_ID}${CMAKE_CXX_COMPILER_VERSION}"
24+
"-${CMAKE_BUILD_TYPE}"
25+
"-${PYTHON3_EXACT_VERSION}"
26+
"-SHARED")
27+
include(CPack)

dnacalib/CMakeModulesExtra/install/InstallLibrary.cmake

Lines changed: 31 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,16 +14,35 @@
1414
set(INSTALL_LIBRARY_SOURCE_DIR "${CMAKE_CURRENT_LIST_DIR}")
1515

1616
macro(install_library target_name)
17+
# component_name is an optional argument, and will default to the given target_name
18+
set(COMPONENT_NAME ${target_name})
19+
set(extra_args ${ARGN})
20+
list(LENGTH extra_args num_extra_args)
21+
if(${num_extra_args} GREATER 0)
22+
list(GET extra_args 0 COMPONENT_NAME)
23+
endif()
24+
1725
include(GNUInstallDirs)
1826
set(REPRESENTATIVE_TARGET_NAME ${target_name})
1927
set(INSTALL_CONFIGDIR ${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME})
2028

2129
# Set install destinations and associate installed target files with an export
2230
install(TARGETS ${REPRESENTATIVE_TARGET_NAME}
2331
EXPORT ${PROJECT_NAME}-targets
24-
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}
25-
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
26-
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
32+
COMPONENT ${COMPONENT_NAME}
33+
RUNTIME
34+
DESTINATION ${CMAKE_INSTALL_LIBDIR}
35+
COMPONENT ${COMPONENT_NAME}
36+
LIBRARY
37+
DESTINATION ${CMAKE_INSTALL_LIBDIR}
38+
COMPONENT ${COMPONENT_NAME}
39+
NAMELINK_COMPONENT ${COMPONENT_NAME}
40+
ARCHIVE
41+
DESTINATION ${CMAKE_INSTALL_LIBDIR}
42+
COMPONENT ${COMPONENT_NAME}
43+
PUBLIC_HEADER
44+
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
45+
COMPONENT ${COMPONENT_NAME}
2746
INCLUDES DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
2847

2948
# Write build-tree targets
@@ -37,7 +56,8 @@ macro(install_library target_name)
3756
install(EXPORT ${PROJECT_NAME}-targets
3857
FILE ${PROJECT_NAME}Targets.cmake
3958
NAMESPACE ${PROJECT_NAME}::
40-
DESTINATION ${INSTALL_CONFIGDIR})
59+
DESTINATION ${INSTALL_CONFIGDIR}
60+
COMPONENT ${COMPONENT_NAME})
4161

4262
include(CMakePackageConfigHelpers)
4363

@@ -68,13 +88,17 @@ macro(install_library target_name)
6888
install(FILES
6989
"${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}Config.install.cmake"
7090
DESTINATION ${INSTALL_CONFIGDIR}
71-
RENAME "${PROJECT_NAME}Config.cmake")
91+
RENAME "${PROJECT_NAME}Config.cmake"
92+
COMPONENT ${COMPONENT_NAME})
7293

7394
# Install package version file
7495
install(FILES
7596
"${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}ConfigVersion.cmake"
76-
DESTINATION ${INSTALL_CONFIGDIR})
97+
DESTINATION ${INSTALL_CONFIGDIR}
98+
COMPONENT ${COMPONENT_NAME})
7799

78100
# Install include files
79-
install(DIRECTORY include/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
101+
install(DIRECTORY include/
102+
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
103+
COMPONENT ${COMPONENT_NAME})
80104
endmacro()

dnacalib/DNACalib/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,8 @@ set(SOURCES
100100
src/dnacalib/TypeDefs.h
101101

102102
src/dnacalib/commands/CalculateMeshLowerLODsCommand.cpp
103+
src/dnacalib/commands/CalculateMeshLowerLODsCommandImpl.cpp
104+
src/dnacalib/commands/CalculateMeshLowerLODsCommandImpl.h
103105
src/dnacalib/commands/ClearBlendShapesCommand.cpp
104106
src/dnacalib/commands/CommandSequence.cpp
105107
src/dnacalib/commands/PruneBlendShapeTargetsCommand.cpp

dnacalib/DNACalib/cmake/DNACDependencies.cmake

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,8 @@ set(SOURCES
123123
src/dnacalib/CommandImplBase.h
124124
src/dnacalib/TypeDefs.h
125125
src/dnacalib/commands/CalculateMeshLowerLODsCommand.cpp
126+
src/dnacalib/commands/CalculateMeshLowerLODsCommandImpl.cpp
127+
src/dnacalib/commands/CalculateMeshLowerLODsCommandImpl.h
126128
src/dnacalib/commands/ClearBlendShapesCommand.cpp
127129
src/dnacalib/commands/CommandSequence.cpp
128130
src/dnacalib/commands/PruneBlendShapeTargetsCommand.cpp

dnacalib/DNACalib/include/dna/types/ArrayView.h

Lines changed: 24 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,19 @@ struct ArrayViewTraits<const T> {
4141
using difference_type = std::ptrdiff_t;
4242
};
4343

44+
template<typename T, typename U>
45+
struct IsCompatible {
46+
static constexpr bool value = std::is_same<typename std::remove_cv<T>::type, typename std::remove_cv<U>::type>::value &&
47+
(std::is_const<typename std::remove_reference<T>::type>::value ||
48+
!std::is_const<typename std::remove_reference<U>::type>::value);
49+
};
50+
4451
/**
4552
@brief A view over a continuous sequence of objects.
4653
@tparam T element type
4754
Provides a view over a continuous sequence of objects owned by some other object.
4855
Contains a count of elements and a pointer to a location where they are stored.
49-
ArrayView does not own the mmemory it points to - it does not perform any allocation
56+
ArrayView does not own the memory it points to - it does not perform any allocation
5057
and deallocation. It can be constructed given a pointer and element count, or a container
5158
type argument. The class provides helper methods for creating subviews over the objects,
5259
and methods for by-value comparison with containers. ConstArrayView represents an immutable view.
@@ -76,23 +83,23 @@ class ArrayView {
7683
sz{size} {
7784
}
7885

79-
ArrayView(std::nullptr_t /*unused*/, size_type /*unused*/) : ArrayView{nullptr, {}} {
80-
}
81-
82-
template<typename U>
86+
template<typename U, typename std::enable_if<IsCompatible<T, U>::value, int>::type = 0>
8387
ArrayView(ArrayView<U>& src) : ArrayView{src.data(), src.size()} {
8488
}
8589

86-
template<typename U>
90+
template<typename U, typename std::enable_if<IsCompatible<T, U>::value, int>::type = 0>
8791
ArrayView(const ArrayView<U>& src) : ArrayView{src.data(), src.size()} {
8892
}
8993

90-
template<typename U>
94+
template<typename U, typename std::enable_if<IsCompatible<T, U>::value, int>::type = 0>
9195
ArrayView(ArrayView<U>&& src) : ArrayView{src.data(), src.size()} {
9296
}
9397

94-
template<typename U, typename std::enable_if<!std::is_rvalue_reference<U &&>::value, int>::type = 0>
95-
explicit ArrayView(U&& src) : ArrayView{src.data(), src.size()} {
98+
template<typename U,
99+
typename std::enable_if<!std::is_rvalue_reference<U &&>::value &&
100+
IsCompatible<T, typename std::remove_reference<U>::type::value_type>::value,
101+
int>::type = 0>
102+
ArrayView(U&& src) : ArrayView{src.data(), static_cast<size_type>(src.size())} {
96103
}
97104

98105
size_type size() const {
@@ -193,7 +200,8 @@ bool operator!=(const ArrayView<T>& lhs, const ArrayView<U>& rhs) {
193200
}
194201

195202
template<typename T, typename TContainer>
196-
bool operator==(const ArrayView<T>& lhs, const TContainer& rhs) {
203+
typename std::enable_if<!std::is_base_of<ArrayView<T>, TContainer>::value, bool>::type operator==(const ArrayView<T>& lhs,
204+
const TContainer& rhs) {
197205
if (lhs.size() != rhs.size()) {
198206
return false;
199207
}
@@ -207,17 +215,20 @@ bool operator==(const ArrayView<T>& lhs, const TContainer& rhs) {
207215
}
208216

209217
template<typename T, typename TContainer>
210-
bool operator!=(const ArrayView<T>& lhs, const TContainer& rhs) {
218+
typename std::enable_if<!std::is_base_of<ArrayView<T>, TContainer>::value, bool>::type operator!=(const ArrayView<T>& lhs,
219+
const TContainer& rhs) {
211220
return !(lhs == rhs);
212221
}
213222

214223
template<typename T, typename TContainer>
215-
bool operator==(const TContainer& lhs, const ArrayView<T>& rhs) {
224+
typename std::enable_if<!std::is_base_of<ArrayView<T>, TContainer>::value, bool>::type operator==(const TContainer& lhs,
225+
const ArrayView<T>& rhs) {
216226
return (rhs == lhs);
217227
}
218228

219229
template<typename T, typename TContainer>
220-
bool operator!=(const TContainer& lhs, const ArrayView<T>& rhs) {
230+
typename std::enable_if<!std::is_base_of<ArrayView<T>, TContainer>::value, bool>::type operator!=(const TContainer& lhs,
231+
const ArrayView<T>& rhs) {
221232
return !(lhs == rhs);
222233
}
223234

dnacalib/DNACalib/include/dna/types/StringView.h

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,4 @@ class StringView : public trust::ConstArrayView<char> {
3232

3333
};
3434

35-
inline bool operator==(const StringView& lhs, const StringView& rhs) {
36-
return (static_cast<const StringView::Base&>(lhs) == static_cast<const StringView::Base&>(rhs));
37-
}
38-
39-
inline bool operator!=(const StringView& lhs, const StringView& rhs) {
40-
return !(lhs == rhs);
41-
}
42-
4335
} // namespace dna

dnacalib/DNACalib/src/dna/filters/JointFilter.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ void JointFilter::apply(RawBehavior& dest) {
7070
}
7171
}
7272
// Collect row indices of removed output indices to be used for joint delta removal
73-
Set<std::size_t> rowsToDelete{memRes};
73+
UnorderedSet<std::size_t> rowsToDelete{memRes};
7474
// Remove output indices belonging to the deletable joint
7575
extd::filter(jointGroup.outputIndices, [this, &rowsToDelete](std::uint16_t outputIndex, std::size_t rowIndex) {
7676
const auto jointIndex = static_cast<std::uint16_t>(outputIndex / jointAttributeCount);

0 commit comments

Comments
 (0)