Home | History | Annotate | Download | only in pixelflinger2

Lines Matching refs:sampler

139 static void tex2d(unsigned sample[4], const float tex_coord[4], const unsigned sampler)
141 const unsigned * data = (const unsigned *)textureGGLContext->textureState.textureData[sampler];
142 const unsigned width = textureGGLContext->textureState.textureDimensions[sampler * 2];
143 const unsigned height = textureGGLContext->textureState.textureDimensions[sampler * 2 + 1];
193 void texcube(unsigned sample[4], const float tex_coord[4], const unsigned sampler)
250 const unsigned * data = (const unsigned *)textureGGLContext->textureState.textureData[sampler];
251 const unsigned width = textureGGLContext->textureState.textureDimensions[sampler * 2];
252 const unsigned height = textureGGLContext->textureState.textureDimensions[sampler * 2 + 1];
389 static void SetSampler(GGLInterface * iface, const unsigned sampler, GGLTexture * texture)
391 assert(GGL_MAXCOMBINEDTEXTUREIMAGEUNITS > sampler);
395 else if (ctx->state.textureState.textures[sampler].format != texture->format)
397 else if (ctx->state.textureState.textures[sampler].wrapS != texture->wrapS)
399 else if (ctx->state.textureState.textures[sampler].wrapT != texture->wrapT)
401 else if (ctx->state.textureState.textures[sampler].minFilter != texture->minFilter)
403 else if (ctx->state.textureState.textures[sampler].magFilter != texture->magFilter)
408 ctx->state.textureState.textures[sampler] = *texture; // shallow copy, data pointed to must remain valid
409 //ctx->state.textureState.textureData[sampler] = texture->levels[0];
410 ctx->state.textureState.textureData[sampler] = texture->levels;
411 ctx->state.textureState.textureDimensions[sampler * 2] = texture->width;
412 ctx->state.textureState.textureDimensions[sampler * 2 + 1] = texture->height;
416 memset(ctx->state.textureState.textures + sampler, 0, sizeof(ctx->state.textureState.textures[sampler]));
417 ctx->state.textureState.textureData[sampler] = NULL;
418 ctx->state.textureState.textureDimensions[sampler * 2] = 0;
419 ctx->state.textureState.textureDimensions[sampler * 2 + 1] = 0;