Phil Keslin (philk++at++cthulhu.engr.sgi.com)
Thu, 08 Oct 1998 20:10:35 -0700
- Phil
Scott Herod wrote:
>
> I have large textures that I need to map onto geosets.
> "Large" means bigger than 512 on a side. If I make textures
> larger than 512 on a side, there is a subtle shift of the
> texels going from a glDrawPixel to the textured geoset.
>
> Currently, I am trying to cut the textures up into 512x512
> subtextures and paste them onto geosets sitting edge to edge.
> However, as they move, there is sometimes a seam.
>
> In an attempt to fix this, I am making the subtextures
> overlap by two texels, one for each in order to use these
> as a texture border. It appears that performer still wants
> textures with borders to be power-of-two so 2 texels for the
> border and 510 for the viewable portion. I then use
>
> tex->setRepeat( PFTEX_WRAP_S, PFTEX_CLAMP );
>
> This works fine on O2 but fails miserably on OCTANE as seams
> are visible.
>
> Any hints or suggestions for making this work? More details
> are below.
>
> Scott Herod
> scott++at++evt.com
>
> Details:
>
> Turn large texture into series of square tiles which width
> wise are (1 texel border) + (510 texels image) + (1 texel border). For
> each subtexture, the left side border is the
> last visible texel of the subtexture on the left and the
> right side border is the first visible texel of the subtexture
> to the right. (Top to bottom is the same, edge subtextures
> repeat border and first row of visible texels.)
>
> Then for each subtexture use
>
> pfTexture *tex = new pfTexture;
>
> // rimg_w = rimg_h = 512
> tex->setImage( tex_data, num_comps, rimg_w, rimg_h, 1 );
> tex->setBorderType(PFTEX_BORDER_TEXELS);
>
> tex->setRepeat( PFTEX_WRAP_S, PFTEX_CLAMP );
> tex->setRepeat( PFTEX_WRAP_T, PFTEX_CLAMP );
> =======================================================================
> List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/
> Submissions: info-performer++at++sgi.com
> Admin. requests: info-performer-request++at++sgi.com
-- Phil Keslin Silicon Graphics, Inc. E-Mail: philk++at++sgi.com 2011 N. Shoreline Blvd. M/S 8U-590 Mountain View, CA 94043
This archive was generated by hypermail 2.0b2 on Thu Oct 08 1998 - 20:10:35 PDT