TEXTUREPROJ(3G)

πŸ“¦
version 1.0~svn33624 Β· 4 versions
, in ubuntu jammy, ubuntu noble

πŸ’– TEXTUREPROJ(3G) πŸ’–

okay bestie, welcome to the [FIXME: manual] page for TEXTUREPROJ(3G) and honestly? she's iconic. pull up a chair, grab a boba, we're learning about projected texture lookups πŸ§‹βœ¨


✨ NAME ✨

textureProj β€” perform a texture lookup with projection πŸ’…


🌸 DECLARATION 🌸

here's the whole overload roster, fr fr, copied character for character, no notes:

gvec4 textureProj(gsampler1D sampler, vec2 P, [float bias]);

gvec4 textureProj(gsampler1D sampler, vec4 P, [float bias]);

gvec4 textureProj(gsampler2D sampler, vec3 P, [float bias]);

gvec4 textureProj(gsampler2D sampler, vec4 P, [float bias]);

gvec4 textureProj(gsampler3D sampler, vec4 P, [float bias]);

float textureProj(sampler1DShadow sampler, vec4 P, [float bias]);

float textureProj(sampler2DShadow sampler, vec4 P, [float bias]);

gvec4 textureProj(gsampler2DRect sampler, vec3 P);

gvec4 textureProj(gsampler2DRect sampler, vec4 P);

float textureProj(gsampler2DRectShadow sampler, vec4 P);

like, look at all those overloads. she has RANGE. πŸ‘‘


πŸŽ€ PARAMETERS πŸŽ€

  • sampler β€” this is the sampler the texture you're pulling texels out of is bound to. it's giving "which texture am I even looking at" energy 🫢
  • P β€” the texture coordinates where the texture gets sampled. your little map of where you wanna peek πŸ—ΊοΈ
  • bias β€” optional bias that gets applied during level-of-detail computation. optional!! she's a bonus, not a requirement ✨

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so textureProj does a texture lookup with projection. the texture coordinates consumed from P β€” and listen, this is not including the last component of P β€” get divided by the last component of P. division era πŸ’…

then the resulting 3rd component of P in the shadow forms is used as Dref. 🎯

after all those values get computed, the texture lookup just proceeds exactly like it does in texture(). same vibes, different setup. periodt. 🌈


🌈 VERSION SUPPORT 🌈

so this is the OpenGL Shading Language Version tea β˜• β€” which versions said yes and which ones said absolutely not. βœ” means she's supported, - means she's not there yet πŸ’€

  • textureProj
    • 1.10 β€” -
    • 1.20 β€” -
    • 1.30 β€” βœ”
    • 1.40 β€” βœ”
    • 1.50 β€” βœ”
    • 3.30 β€” βœ”
    • 4.00 β€” βœ”
    • 4.10 β€” βœ”
    • 4.20 β€” βœ”
    • 4.30 β€” βœ”
    • 4.40 β€” βœ”
    • 4.50 β€” βœ”
  • textureProj (gsampler2DRect{Shadow})
    • 1.10 β€” -
    • 1.20 β€” -
    • 1.30 β€” -
    • 1.40 β€” βœ”
    • 1.50 β€” βœ”
    • 3.30 β€” βœ”
    • 4.00 β€” βœ”
    • 4.10 β€” βœ”
    • 4.20 β€” βœ”
    • 4.30 β€” βœ”
    • 4.40 β€” βœ”
    • 4.50 β€” βœ”

not the 2DRect one showing up fashionably late to the 1.40 party 😭 honestly relatable.


πŸ‘‘ SEE ALSO πŸ‘‘

the whole friend group, go say hi:

texelFetch(), texelFetchOffset(), texture(), textureGather(), textureGatherOffset(), textureGatherOffsets(), textureGrad(), textureGradOffset(), textureLod(), textureLodOffset(), textureOffset(), textureProjGrad(), textureProjGradOffset(), textureProjLod(), textureProjLodOffset(), textureProjOffset(), textureQueryLod(), textureSize()

a whole squad. iykyk 🫢


Copyright Β© 2011-2014 Khronos Group. This material may be distributed subject to the terms and conditions set forth in the Open Publication License, v 1.0, 8 June 1999. http://opencontent.org/openpub/.

Copyright Β© 2011-2014 Khronos Group


and that's the whole page bestie!! 🌸 she came from [FIXME: source], she's dated 01/03/2018, and she's filed under TEXTUREPROJ(3G). go forth and project those texels, you absolute main character πŸ¦‹πŸ’–πŸŽ€

πŸ“¦ where this page comes from