Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[HDRP] Fix build warnings #6524

Merged
merged 4 commits into from
Dec 8, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove if debug
  • Loading branch information
alelievr committed Dec 8, 2021
commit ce55b2ffb68a2ac77f8f621a6028aac711566eab
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,7 @@ public enum DebugLightLayersMask
static class DebugLightHierarchyExtensions
{

#if DEBUG
[IgnoreWarning(1370)] //Ignore throwing exception warning on burst..
#endif
public static bool IsEnabledFor(
this DebugLightFilterMode mode,
GPULightType gpuLightType,
Expand All @@ -128,23 +126,15 @@ SpotLightShape spotLightShape
case SpotLightShape.Cone: return (mode & DebugLightFilterMode.DirectSpotCone) != 0;
case SpotLightShape.Pyramid: return (mode & DebugLightFilterMode.DirectSpotPyramid) != 0;
default:
#if DEBUG
throw new ArgumentOutOfRangeException(nameof(spotLightShape));
#else
return false;
#endif
}
}
case GPULightType.Tube: return (mode & DebugLightFilterMode.DirectTube) != 0;
case GPULightType.Point: return (mode & DebugLightFilterMode.DirectPunctual) != 0;
case GPULightType.Rectangle: return (mode & DebugLightFilterMode.DirectRectangle) != 0;
case GPULightType.Directional: return (mode & DebugLightFilterMode.DirectDirectional) != 0;
default:
#if DEBUG
throw new ArgumentOutOfRangeException(nameof(gpuLightType));
#else
return false;
#endif
}
}

Expand Down