Skip to content

Conversation

@barbalt
Copy link
Collaborator

@barbalt barbalt commented Oct 15, 2025

The blendShape api in maya, by default, create copies for either each target or the original shape (if a target is not provided).
This makes the importing blendShapes really slow, specially for a mesh with several blendShapes.

This PR by pass the blendShape api by manually creating the required plugs for it to work just by using the deltas instead of the creating clone nodes.

@barbalt barbalt self-assigned this Oct 15, 2025
@barbalt barbalt assigned barbalt and unassigned barbalt Oct 15, 2025
@barbalt barbalt assigned barbalt and unassigned barbalt Oct 15, 2025
@barbalt barbalt assigned barbalt and unassigned barbalt Oct 15, 2025
// Zero weight: 5000
static const auto convertWeightToIndex = [](float weight) -> int {
int result = 5000 + static_cast<int>(weight * 1000.f);
return result >= 0 ? result : 0;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we also check for <= 6000? Or does that not matter?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In theory, internally, we could go up to INT_MAX

pierrebai-adsk
pierrebai-adsk previously approved these changes Oct 15, 2025
@barbalt barbalt added enhancement New feature or request import-export Related to Import and/or Export ready-for-merge Development process is finished, PR is ready for merge labels Oct 15, 2025
@seando-adsk seando-adsk merged commit 13f300b into dev Oct 16, 2025
11 checks passed
@seando-adsk seando-adsk deleted the barbalt/dev/EMSUSD-2662-slow-blendshapes branch October 16, 2025 18:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request import-export Related to Import and/or Export ready-for-merge Development process is finished, PR is ready for merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants