Results 1 to 2 of 2

Thread: textureGrad implementation

  1. #1
    Junior Member Newbie
    Join Date
    Apr 2010
    Posts
    24

    textureGrad implementation

    I am a little confused about what can be a possible implementation of textureGrad for 2d textures.
    min/mag: linear_mipmap_linear / linear.
    Implementation must be based on texelFetch.
    Texture dimensions are w/h.

    Which lod is chosen when du/dx=5 and dv/dy=20? (du/dy=dv/dx=0).

    I am trying procedural texturing and this info will be helpful.

  2. #2
    Senior Member OpenGL Guru
    Join Date
    Jun 2013
    Posts
    3,104
    Quote Originally Posted by Gessos Paul View Post
    I am a little confused about what can be a possible implementation of textureGrad for 2d textures.
    min/mag: linear_mipmap_linear / linear.
    Implementation must be based on texelFetch.
    Texture dimensions are w/h.

    Which lod is chosen when du/dx=5 and dv/dy=20? (du/dy=dv/dx=0)
    The LoD will be log2(20)~=4.32.

    The calculation is given in 8.14.1 of the OpenGL 4.5 specification.

Similar Threads

  1. Using textureGrad with cube map
    By idwakest in forum OpenGL: GLSL
    Replies: 2
    Last Post: 04-30-2012, 01:28 AM
  2. dFdx dFdy textureGrad and texture
    By yjh1982 in forum OpenGL: GLSL
    Replies: 3
    Last Post: 08-24-2010, 04:09 AM
  3. implementation
    By in forum OpenGL: Basic Coding
    Replies: 3
    Last Post: 12-09-2003, 01:08 AM
  4. OT: SSE implementation in C++
    By GPSnoopy in forum OpenGL: Advanced Coding
    Replies: 10
    Last Post: 04-27-2002, 01:46 PM
  5. Si implementation
    By OldMan in forum OpenGL: Linux
    Replies: 2
    Last Post: 12-20-2001, 08:30 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Proudly hosted by Digital Ocean