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

Method drawHueShift

forge-gui-mobile/src/forge/Graphics.java:1045–1063  ·  view source on GitHub ↗
(Texture image, float x, float y, float w, float h, Float time)

Source from the content-addressed store, hash-verified

1043 }
1044
1045 public void drawHueShift(Texture image, float x, float y, float w, float h, Float time) {
1046 if (image == null)
1047 return;
1048 if (time != null) {
1049 batch.end();
1050 shaderHueShift.bind();
1051 shaderHueShift.setUniformf("u_time", time);
1052 batch.setShader(shaderHueShift);
1053 batch.begin();
1054 //draw
1055 batch.draw(image, x, y, w, h);
1056 //reset
1057 batch.end();
1058 batch.setShader(null);
1059 batch.begin();
1060 } else {
1061 drawImage(image, x, y, w, h);
1062 }
1063 }
1064
1065 public void drawHueShift(TextureRegion image, float x, float y, float w, float h, Float time) {
1066 if (image == null)

Callers 1

drawBackgroundMethod · 0.80

Calls 4

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

Tested by

no test coverage detected