mirror of
https://github.com/GTNewHorizons/Angelica.git
synced 2026-11-19 20:09:39 +00:00
Fix stale uniforms when switching shader program (#1715)
This commit is contained in:
1 parent
155f209db5
commit
7e44c1efcb
7 files changed
+48
-31
No files matched your search
@@ -181,9 +181,7 @@ public class DeferredWorldRenderingPipeline implements WorldRenderingPipeline, R
|
||||
private final boolean allowConcurrentCompute;
|
||||
private final OptionalInt forcedShadowRenderDistanceChunks;
|
||||
private final CloudSetting dhCloudSetting;
|
||||
|
||||
private Pass current = null;
|
||||
|
||||
private WorldRenderingPhase overridePhase = null;
|
||||
private WorldRenderingPhase phase = WorldRenderingPhase.NONE;
|
||||
private boolean isBeforeTranslucent;
|
||||
@@ -769,7 +767,11 @@ public class DeferredWorldRenderingPipeline implements WorldRenderingPipeline, R
|
||||
public boolean shouldOverrideShaders() {
|
||||
return isRenderingWorld && !isRenderingFullScreenPass && !isPostChain && isMainBound;
|
||||
}
|
||||
|
||||
|
||||
public Pass getActivePassProgram() {
|
||||
return current;
|
||||
}
|
||||
|
||||
public int getActivePassProgramId() {
|
||||
if (current == null) return -1;
|
||||
final Program p = current.getProgram();
|
||||
@@ -1050,7 +1052,7 @@ public class DeferredWorldRenderingPipeline implements WorldRenderingPipeline, R
|
||||
return shadowRenderTargets != null;
|
||||
}
|
||||
|
||||
private final class Pass {
|
||||
public final class Pass {
|
||||
@Nullable
|
||||
private final Program program;
|
||||
private final GlFramebuffer framebufferBeforeTranslucents;
|
||||
|
||||
Reference in new issue
Block a user