Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: mac-opengl digest, Vol 2 #32 - 2 msgs



On 12/5/00 1:26 AM, email@hidden wrote:

> Hi, I am just starting out with OpenGL and was building a model when
>I noticed that the edges faded to a white-ish color. I figured I'd use
>border pixels so that linear interpolation would have something to
>interpolate to. But I read a page on the net that said borders aren't
>supported on many cards and may run in software extremely slowly. Are
>they supported on the rage pro & 128 (and possible the II or whatever's
>in the iMac Rev. A)? If they are not, I can use a 64x64 texture but only
>set my coordinates to go from 1/64 to 1-1/64 so that the first and last
>row go for interpolation, but it seems like much more work.

As for borders... don't use borders. Disable them. I haven't been able to
get them to work consistently on any 3D card I've tested with -- the only
way they worked "to spec" is with software rendering.

If you need to divide a large texture up into tiles, you have a few
options... 1) just use GL_CLAMP_TO_EDGE and ignore interpolation
artifacts at the edges (many games do this where fast action means it
won't be too noticable -- e.g. Cro Mag Rally)... 2) adjust the texture
coordinates as you described, although it can be annoying and requires
you to have duplicate pixels in the other tiles... or 3) Manually average
the texel values at the edges of the texture so that they match the
surrounding tiles. Unless you have a very complex, busy texture, this may
be much more visually acceptable than the seams.

-Ben

+--------------------------+-----------------------------------+
| Ben Spees | Ambrosia Software, Inc. |
| Coding Boffin | http://www.AmbrosiaSW.com/ |
+--------------------------+-----------------------------------+




Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.