Skip to content

Commit

Permalink
fix: raytracing inclusion mask incorrect bit remove operation
Browse files Browse the repository at this point in the history
  • Loading branch information
turanszkij committed Nov 8, 2023
1 parent dce2696 commit 5287c0b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions WickedEngine/wiScene.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2567,7 +2567,7 @@ namespace wi::scene
}
if (!talking_active)
{
expression_mastering._flags ^= ExpressionComponent::TALKING_ENDED;
expression_mastering._flags &= ~ExpressionComponent::TALKING_ENDED;
}
}

Expand Down Expand Up @@ -3965,11 +3965,11 @@ namespace wi::scene
}
if (!object.IsCastingShadow())
{
instance.instance_mask ^= wi::renderer::raytracing_inclusion_mask_shadow;
instance.instance_mask &= ~wi::renderer::raytracing_inclusion_mask_shadow;
}
if (object.IsNotVisibleInReflections())
{
instance.instance_mask ^= wi::renderer::raytracing_inclusion_mask_reflection;
instance.instance_mask &= ~wi::renderer::raytracing_inclusion_mask_reflection;
}
instance.bottom_level = &mesh.BLASes[object.lod];
instance.instance_contribution_to_hit_group_index = 0;
Expand Down
2 changes: 1 addition & 1 deletion WickedEngine/wiScene_Components.h
Original file line number Diff line number Diff line change
Expand Up @@ -1101,7 +1101,7 @@ namespace wi::scene
float slopeBlendPower = 0;

// Set decal to only use alpha from base color texture. Useful for blending normalmap-only decals
constexpr void SetBaseColorOnlyAlpha(bool value) { if (value) { _flags |= BASECOLOR_ONLY_ALPHA; } else { _flags ^= BASECOLOR_ONLY_ALPHA; } }
constexpr void SetBaseColorOnlyAlpha(bool value) { if (value) { _flags |= BASECOLOR_ONLY_ALPHA; } else { _flags &= ~BASECOLOR_ONLY_ALPHA; } }

constexpr bool IsBaseColorOnlyAlpha() const { return _flags & BASECOLOR_ONLY_ALPHA; }

Expand Down
2 changes: 1 addition & 1 deletion WickedEngine/wiVersion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace wi::version
// minor features, major updates, breaking compatibility changes
const int minor = 71;
// minor bug fixes, alterations, refactors, updates
const int revision = 340;
const int revision = 341;

const std::string version_string = std::to_string(major) + "." + std::to_string(minor) + "." + std::to_string(revision);

Expand Down

0 comments on commit 5287c0b

Please sign in to comment.