Skip to content

Commit

Permalink
Revert the improvement to the color space transformation of the lead …
Browse files Browse the repository at this point in the history
…selection color because this change will require an update to multiple autotest baseline images and I don't want to pollute this PR
  • Loading branch information
vlasovi committed Jul 28, 2022
1 parent d6bdf1a commit b42af18
Showing 1 changed file with 5 additions and 12 deletions.
17 changes: 5 additions & 12 deletions lib/mayaUsd/render/vp2RenderDelegate/proxyRenderDelegate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1869,19 +1869,12 @@ MColor ProxyRenderDelegate::GetSelectionHighlightColor(const TfToken& className)

if (className.IsEmpty()) {
// The 'lead' color is returned in display space, so we need to convert it to
// rendering space. However, the required functionality for this conversion is
// available only starting from Maya 2023.2
// rendering space. However, function MColorPickerUtilities::applyViewTransform
// is supported only starting from Maya 2023, so in opposite case we just return
// the default lead color.
#if MAYA_API_VERSION >= 20230000
#if MAYA_API_VERSION >= 20230200
if (_currentFrameContext) {
colorCache->first
= _currentFrameContext->applyViewTransform(color, MFrameContext::kInverse);
} else
#endif
{
colorCache->first = MColorPickerUtilities::applyViewTransform(
color, MColorPickerUtilities::kInverse);
}
colorCache->first
= MColorPickerUtilities::applyViewTransform(color, MColorPickerUtilities::kInverse);
#else
colorCache->first = kDefaultLeadColor;
#endif
Expand Down

0 comments on commit b42af18

Please sign in to comment.