Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo


textureinfo call works unpredictable

  • When I try to get info from texture rendered in pixie and converted with RiMakeTexture call textureinfo returns wrong data.

    textureinfo(zfilename, "projectionmatrix", shadCamSpace);
    textureinfo(zfilename, "viewingmatrix", shadCamSpace);
    returns matrices filled by zerro

    uniform float res[2];
    textureinfo(zfilename, "resolution", res);
    return only first component;

    And one thing.
    When I call texture() and use shadowmap as texture pixie falls.

    • Please check this example scene:

      Point me if this is my mistake.

    • George Harker
      George Harker

      Hi Akhilman,

      The bug with the format query returning only the first element is now fixed.  Thanks for finding that.  It seemed to have crept in since we implemented textureinfo().

      The viewingmatrix and projectionmatrix queries are only supported for shadows or environments.  The textureinfo() call reutrns a float to indicate whether it could get the data.  We could have textureinfo check to see if a texture was rendered in Pixie and copy over the projectionmatrix and viewing matrix like it does for environments / shadows.  We don't currently because textures aren't usually rooted in world space like environments or textures.  But we could if there was need to.

      The textureinfo() call should support textures, shadowmaps and environments.  I tried to recreate your issue with both dsh and standard shadows, but couldn't.  Could you supply more info?



    • Regards
      Shadow map will be ok. I just need to get depth in some pixel of this map as described here http://www.rendermanacademy.com/docs/SSS_depthmaps.htm.

      viewing matrix works well with shadow map. But projection matrix still falls

      can't get projectionmatrix
      resolution 512.000000 256.000000
      viewingmatrix ((1.943864,-0.434504,0.262003,0.262003),(-0.321394,-2.291872,-0.642788,-0.642788),(-0.299905,-1.193791,0.719846,0.719846),(4.000000,5.286139,8.000000,8.000000))
      projectionmatrix ((0.000000,0.000000,0.000000,0.000000),(0.000000,0.000000,0.000000,0.000000),(0.000000,0.000000,0.000000,0.000000),(0.000000,0.000000,0.000000,0.000000))
      then rndr falls in texture call with shadow map

      please check updated scene http://akhil.nightmail.ru/pixie_textureinfo_prblem2.tar.bz2