-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
generalize binding framebuffer to every time its called when blur is …
…working
- Loading branch information
Showing
7 changed files
with
29 additions
and
69 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
src/main/java/org/polyfrost/polyblur/mixin/FramebufferMixin.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package org.polyfrost.polyblur.mixin; | ||
|
||
import net.minecraft.client.Minecraft; | ||
import net.minecraft.client.shader.Framebuffer; | ||
import org.polyfrost.polyblur.blurs.monkey.MonkeyBlur; | ||
import org.spongepowered.asm.mixin.Mixin; | ||
import org.spongepowered.asm.mixin.Unique; | ||
import org.spongepowered.asm.mixin.injection.At; | ||
import org.spongepowered.asm.mixin.injection.Inject; | ||
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; | ||
|
||
@Mixin(Framebuffer.class) | ||
public class FramebufferMixin { | ||
|
||
@Unique private final Framebuffer polyBlur$self = (Framebuffer) (Object) this; | ||
|
||
@Inject(method = "bindFramebuffer", at = @At("TAIL")) | ||
private void onBindFramebuffer(boolean p_147610_1_, CallbackInfo ci) { | ||
if (MonkeyBlur.instance.drawingBuffer && polyBlur$self == Minecraft.getMinecraft().getFramebuffer()) { | ||
MonkeyBlur.instance.bindFb(); | ||
} | ||
} | ||
} |
19 changes: 0 additions & 19 deletions
19
src/main/java/org/polyfrost/polyblur/mixin/RenderGlobalMixin.java
This file was deleted.
Oops, something went wrong.
21 changes: 0 additions & 21 deletions
21
src/main/java/org/polyfrost/polyblur/mixin/SBAEntityOutlineRendererMixin.java
This file was deleted.
Oops, something went wrong.
22 changes: 0 additions & 22 deletions
22
src/main/java/org/polyfrost/polyblur/mixin/SkyHanniEntityOutlineRendererMixin.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters