MCPcopy Index your code
hub / github.com/benfry/processing4 / bindTexture

Method bindTexture

core/src/processing/opengl/PGL.java:3296–3313  ·  view source on GitHub ↗
(int target, int texture)

Source from the content-addressed store, hash-verified

3294 protected abstract void activeTextureImpl(int texture);
3295
3296 public void bindTexture(int target, int texture) {
3297 bindTextureImpl(target, texture);
3298
3299 if (boundTextures == null) {
3300 maxTexUnits = getMaxTexUnits();
3301 boundTextures = new int[maxTexUnits][2];
3302 }
3303
3304 if (maxTexUnits <= activeTexUnit) {
3305 throw new RuntimeException(TEXUNIT_ERROR);
3306 }
3307
3308 if (target == TEXTURE_2D) {
3309 boundTextures[activeTexUnit][0] = texture;
3310 } else if (target == TEXTURE_RECTANGLE) {
3311 boundTextures[activeTexUnit][1] = texture;
3312 }
3313 }
3314 protected abstract void bindTextureImpl(int target, int texture);
3315
3316 ///////////////////////////////////////////////////////////

Callers 14

bindFrontTextureMethod · 0.95
unbindFrontTextureMethod · 0.95
endRenderMethod · 0.95
createFBOLayerMethod · 0.95
restoreFirstFrameMethod · 0.95
copyToTextureMethod · 0.95
drawTexture2DMethod · 0.95
drawTextureRectMethod · 0.95
setMethod · 0.80
setNativeMethod · 0.80
bindMethod · 0.80
unbindMethod · 0.80

Calls 2

bindTextureImplMethod · 0.95
getMaxTexUnitsMethod · 0.95

Tested by

no test coverage detected