Skip to content

Commit 5cb0482

Browse files
author
Meeuyt
committed
fix(common): match CooIrisRenderState signatures to Java mixin
- Add @JvmStatic to all methods so Java mixin can call them statically - Fix captureSceneDepth signature to accept DepthTexture? instead of Int - Fix captureFinalColor signature to accept Any? for colorAttachment0 - Add missing import for DepthTexture, GlFramebuffer, RenderTargets
1 parent e629a55 commit 5cb0482

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

‎common/src/main/kotlin/cn/coostack/cooparticlesapi/compat/iris/CooIrisRenderState.kt‎

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,33 @@
11
package cn.coostack.cooparticlesapi.compat.iris
22

3+
import kotlin.jvm.JvmStatic
34
import net.irisshaders.iris.gl.framebuffer.GlFramebuffer
45
import net.irisshaders.iris.targets.DepthTexture
56
import net.irisshaders.iris.targets.RenderTargets
67

78
object CooIrisRenderState {
9+
@JvmStatic
810
fun beginFrame() {}
11+
12+
@JvmStatic
913
fun captureSceneDepth(depth: DepthTexture?, width: Int, height: Int) {}
14+
15+
@JvmStatic
1016
fun captureTerrainDepth(textureId: Int, width: Int, height: Int) {}
17+
18+
@JvmStatic
1119
fun captureNoHandDepth(textureId: Int, width: Int, height: Int) {}
20+
21+
@JvmStatic
1222
fun captureFinalColor(colorAttachment0: Any?, framebufferId: Int, width: Int, height: Int) {}
23+
24+
@JvmStatic
1325
fun clear() {}
26+
27+
@JvmStatic
1428
fun clearFinalColor() {}
29+
30+
@JvmStatic
1531
fun snapshot(): IrisSnapshot = EmptySnapshot
1632

1733
object EmptySnapshot : IrisSnapshot {

0 commit comments

Comments
 (0)