Reverse subtractive and reverse subtractive.

This commit is contained in:
sphere 2021-11-19 18:56:55 +01:00
parent f4a771553b
commit e1ee0bd138
2 changed files with 11 additions and 10 deletions

View file

@ -77,7 +77,8 @@ namespace CodeImp.DoomBuilder.IO
{ 936, 0.4f },
{ 937, 0.3f },
{ 938, 0.2f },
{ 939, 0.1f }
{ 939, 0.1f },
{ 940, 0.5f } // modulate, placeholder value
};
startTypes = new List<int>() { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35 };

View file

@ -994,14 +994,14 @@ namespace CodeImp.DoomBuilder.Rendering
break;
case RenderPass.Subtractive:
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.ReverseSubtract);
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.Subtract);
graphics.Device.SetRenderState(RenderState.SourceBlend, Blend.SourceAlpha);
graphics.Device.SetRenderState(RenderState.DestinationBlend, Blend.One);
break;
case RenderPass.ReverseSubtractive:
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.Subtract);
graphics.Device.SetRenderState(RenderState.SourceBlend, Blend.InverseSourceAlpha);
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.ReverseSubtract);
graphics.Device.SetRenderState(RenderState.SourceBlend, Blend.SourceAlpha);
graphics.Device.SetRenderState(RenderState.DestinationBlend, Blend.One);
break;
@ -1139,14 +1139,14 @@ namespace CodeImp.DoomBuilder.Rendering
break;
case RenderPass.Subtractive:
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.ReverseSubtract);
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.Subtract);
graphics.Device.SetRenderState(RenderState.SourceBlend, Blend.SourceAlpha);
graphics.Device.SetRenderState(RenderState.DestinationBlend, Blend.One);
break;
case RenderPass.ReverseSubtractive:
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.Subtract);
graphics.Device.SetRenderState(RenderState.SourceBlend, Blend.InverseSourceAlpha);
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.ReverseSubtract);
graphics.Device.SetRenderState(RenderState.SourceBlend, Blend.SourceAlpha);
graphics.Device.SetRenderState(RenderState.DestinationBlend, Blend.One);
break;
@ -1521,14 +1521,14 @@ namespace CodeImp.DoomBuilder.Rendering
break;
case RenderPass.Subtractive:
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.ReverseSubtract);
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.Subtract);
graphics.Device.SetRenderState(RenderState.SourceBlend, Blend.SourceAlpha);
graphics.Device.SetRenderState(RenderState.DestinationBlend, Blend.One);
break;
case RenderPass.ReverseSubtractive:
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.Subtract);
graphics.Device.SetRenderState(RenderState.SourceBlend, Blend.InverseSourceAlpha);
graphics.Device.SetRenderState(RenderState.BlendOperation, BlendOperation.ReverseSubtract);
graphics.Device.SetRenderState(RenderState.SourceBlend, Blend.SourceAlpha);
graphics.Device.SetRenderState(RenderState.DestinationBlend, Blend.One);
break;