Bugs item #2844089, was opened at 2009-08-25 09:53
Message generated for change (Tracker Item Submitted) made by zmoelnig
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=507079&aid=2844089&group_id=64325

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: IOhannes m zmlnig (zmoelnig)
Assigned to: Nobody/Anonymous (nobody)
Summary: model, texturing and flipped images

Initial Comment:
the UV-texturing mode of [model] (which is the default) does not work with 
upsidedown images .
instead the texture will appear as if it had only 1 dimension.
this happens on OSX, with the example posted to the gem-dev mailing list 
http://lists.puredata.info/pipermail/gem-dev/attachments/20090126/9968a85d/attachment-0001.zip
 and was initially reported by marius

workaround:
 insert [pix_flip] before [pix_texture]


technical background:
upsidedown images are images with the origin in the upper-left corner as 
opposed to openGL-pixes which origin in the lower-left corner; in Gem these 
might appear on various pix-sources (e.g. all sources on OS-X; most video 
codecs,...)  where their orientation is not corrected for performance reasons; 
instead an upsidedown flag is passed along with the image, in order to make the 
final of the image work "correctly" (by flipping the image using GPU)
unfortunately this doesn't work (yet?) with complex geos like models.
what's more, [model] just uses the 3rd texcoord from the GemState, which is - 
for non-upside down images - (w/h) (or 1/1 on normalized coordinates), whereas 
for upside-down images it is (w/0) (the 2nd texcoord would be (w/h)); that's 
why one dimension seems to be missing.


why does [pix_flip] help:
[pix_flip] will get the orientation of animage right; if an image is reported 
to be upside-down, pix_flip will flip the image around it's horizontal axis and 
clear the upside-down flag. therefore the problem with upside-down images can 
be fixed by inserting [pix_flip]

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=507079&aid=2844089&group_id=64325

_______________________________________________
GEM-dev mailing list
[email protected]
http://lists.puredata.info/listinfo/gem-dev

Reply via email to