mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-23 13:30:02 +00:00
Move the computation of simulate-logic shader type earlier
This commit is contained in:
parent
87b14fe1c2
commit
d35749bfc8
@ -1063,6 +1063,8 @@ void ConvertBlendState(GenericBlendState &blendState, bool forceReplaceBlend) {
|
||||
}
|
||||
blendState.replaceBlend = replaceBlend;
|
||||
|
||||
blendState.simulateLogicOpType = SimulateLogicOpShaderTypeIfNeeded();
|
||||
|
||||
ReplaceAlphaType replaceAlphaWithStencil = ReplaceAlphaWithStencil(replaceBlend);
|
||||
blendState.replaceAlphaWithStencil = replaceAlphaWithStencil;
|
||||
|
||||
|
@ -146,6 +146,7 @@ struct GenericBlendState {
|
||||
// Shader generation state
|
||||
ReplaceAlphaType replaceAlphaWithStencil;
|
||||
ReplaceBlendType replaceBlend;
|
||||
SimulateLogicOpType simulateLogicOpType;
|
||||
|
||||
// Resulting hardware blend state
|
||||
bool blendEnabled;
|
||||
|
@ -267,7 +267,7 @@ void ComputeFragmentShaderID(FShaderID *id_out, const ComputedPipelineState &pip
|
||||
|
||||
ReplaceBlendType replaceBlend = pipelineState.blendState.replaceBlend;
|
||||
ReplaceAlphaType stencilToAlpha = pipelineState.blendState.replaceAlphaWithStencil;
|
||||
SimulateLogicOpType simulateLogicOpType = SimulateLogicOpShaderTypeIfNeeded();
|
||||
SimulateLogicOpType simulateLogicOpType = pipelineState.blendState.simulateLogicOpType;
|
||||
|
||||
// All texfuncs except replace are the same for RGB as for RGBA with full alpha.
|
||||
// Note that checking this means that we must dirty the fragment shader ID whenever textureFullAlpha changes.
|
||||
|
Loading…
Reference in New Issue
Block a user