MCPcopy Create free account
hub / github.com/Card-Forge/forge / drawRipple

Method drawRipple

forge-gui-mobile/src/forge/Graphics.java:1105–1124  ·  view source on GitHub ↗
(FImage image, float x, float y, float w, float h, Float amount)

Source from the content-addressed store, hash-verified

1103 }
1104
1105 public void drawRipple(FImage image, float x, float y, float w, float h, Float amount) {
1106 if (image == null)
1107 return;
1108 if (amount != null) {
1109 batch.end();
1110 shaderRipple.bind();
1111 shaderRipple.setUniformf("u_time", amount);
1112 shaderRipple.setUniformf("u_bias", 0.7f);
1113 batch.setShader(shaderRipple);
1114 batch.begin();
1115 //draw
1116 image.draw(this, x, y, w, h);
1117 //reset
1118 batch.end();
1119 batch.setShader(null);
1120 batch.begin();
1121 } else {
1122 drawImage(image, x, y, w, h);
1123 }
1124 }
1125
1126 public void drawPixelated(FImage image, float x, float y, float w, float h, Float amount, boolean flipY) {
1127 if (image == null)

Callers 2

drawBackgroundMethod · 0.80
drawBackgroundMethod · 0.80

Calls 4

drawImageMethod · 0.95
drawMethod · 0.65
endMethod · 0.45
beginMethod · 0.45

Tested by

no test coverage detected