[Fluxus] texture problems

Scott alcoholiday at gmail.com
Wed Apr 8 07:42:44 PDT 2009


Well - all I can think, is taking Dave's comment above into acount too, is
that one of us is describing a polygon that is facing down the -z axis. If
you want to keep a texture readable (I like using text as the example) and
view it looking towards the +z axis, then you would put t:(0,0) on the
(1,0,0) vertext and the the t:(1,1) on the (0,1,0) vertext, which would of
course look backwards if viewed down the -Z axis. As Dave said - if your
using the poly-convert-to-indexed code, then perhaps pulling the wrong UVs.

On Wed, Apr 8, 2009 at 1:21 AM, gabor papp <gabor.lists at mndl.hu> wrote:

> > looks correct. You'll notice that the x,y coordinates are the same as the
> > s,t coordinates and they're all 1st quadrant.
> yes, you are right. the default plane coordinates look like this:
> 0: p: #(-0.5 -0.5 0.0) t: #(0.0 0.0 0.0)
> 1: p: #( 0.5 -0.5 0.0) t: #(1.0 0.0 0.0)
> 2: p: #( 0.5  0.5 0.0) t: #(1.0 1.0 0.0)
> 3: p: #(-0.5  0.5 0.0) t: #(0.0 1.0 0.0)
> p0 is bottom-left and p2 is top-right. texture coordinates: t0 is (0, 0)
> and t2 is (1, 1). i think the cause of the problem is that the top-left
> of the texture (1st pixel) should be at the texture coordinate (0, 0),
> and the bottom-right (last pixel) should be at (1, 1). so with these 1st
> quadrant texture coordinates the original, vertically flipped behaviour
> was right. now we have flipped the rows in the texture reading code
> (reading the last line first, and the first line last), which results in
> the problems with the pixels data.
>
> i think the coordinates should be vertically flipped, and the png
> reading code should be restored to its normal behaviour:
> 0: p: #(-0.5 -0.5 0.0) t: #(0.0 1.0 0.0)
> 1: p: #( 0.5 -0.5 0.0) t: #(1.0 1.0 0.0)
> 2: p: #( 0.5  0.5 0.0) t: #(1.0 0.0 0.0)
> 3: p: #(-0.5  0.5 0.0) t: #(0.0 0.0 0.0)
>
> or we can choose to have first quadrant texture coordinates with the
> normal, flipped texture.
>
> what is your opinion? am i missing something?
>
> best,
> gabor
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pawfal.org/pipermail/fluxus-pawfal.org/attachments/20090408/40d36bfb/attachment.html>


More information about the Fluxus mailing list