hi
i'd like to show some images in fullscreen-mode with gem. since it is cheaper to use [pix_texture] than to draw the image directly, i draw a rectangle that fits exactly in the gem-window and apply the image as a texture. i plan to create an application that will be used on different machines with different displays. at the moment i have to change the dimensions of the [rectangle] manually when i use the patch on a machine with different display-resolution. i think there is a relation between the used resolution and x- and y-values of [rectangle], but i failed finding it. is there a way to calculate these values from the resolution in order to fit the [reactangle] exactly into the gem-window? this would allow to write the actual resolution in a config-file whitout the need of changing the patch.
thank you in advance
roman
___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de
Roman Haefeli wrote:
hi
i'd like to show some images in fullscreen-mode with gem. since it is cheaper to use [pix_texture] than to draw the image directly, i draw a rectangle that fits exactly in the gem-window and apply the image as a texture. i plan to create an application that will be used on different machines with different displays. at the moment i have to change the dimensions of the [rectangle] manually when i use the patch on a machine with different display-resolution.
no you don't!
i think there is a relation between the used resolution and x- and y-values of [rectangle], but i failed finding it. is there a way to calculate these values from the resolution in order to fit the [reactangle] exactly into the gem-window? this would allow to write the actual resolution in a config-file whitout the need of changing the patch.
the only problematic thing that can happen to you is when your aspect-ratio changes. a rectangle that covers the full-screen on 500x500 will not cover the entire screen on 800x600; however: the same rectangle that covers 1024x768 will also cover a 1600x1200 screen (or a 320x240 window)
note: the height of the gemwindow will always be 4 units (the width will change with the aspect-ratio)
note: you will probably want to keep the aspect-ratio in order to not distort your images)
mf.a.r IOhannes
PS: if you find that i am talking non-sense, then you are likely to have discovered a bug
Hallo Iohannes,
You said something that I find interesting as I'm trying to learn Gem,
The height of the GemWin will always be 4 units? How's that?
Where was I supposed to find about that? I have read a few documentations and none of them specified this... Do you recommend one in particular?
Jé
IOhannes m zmoelnig a écrit :
Roman Haefeli wrote:
hi
i'd like to show some images in fullscreen-mode with gem. since it is cheaper to use [pix_texture] than to draw the image directly, i draw a rectangle that fits exactly in the gem-window and apply the image as a texture. i plan to create an application that will be used on different machines with different displays. at the moment i have to change the dimensions of the [rectangle] manually when i use the patch on a machine with different display-resolution.
no you don't!
i think there is a relation between the used resolution and x- and y-values of [rectangle], but i failed finding it. is there a way to calculate these values from the resolution in order to fit the [reactangle] exactly into the gem-window? this would allow to write the actual resolution in a config-file whitout the need of changing the patch.
the only problematic thing that can happen to you is when your aspect-ratio changes. a rectangle that covers the full-screen on 500x500 will not cover the entire screen on 800x600; however: the same rectangle that covers 1024x768 will also cover a 1600x1200 screen (or a 320x240 window)
note: the height of the gemwindow will always be 4 units (the width will change with the aspect-ratio)
note: you will probably want to keep the aspect-ratio in order to not distort your images)
mf.a.r IOhannes
PS: if you find that i am talking non-sense, then you are likely to have discovered a bug
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
www.ekran.org/pd
all the workshop tutorials could be good, try the latest one for Interaccess.
B>
Jerome Tuncer wrote:
Hallo Iohannes,
You said something that I find interesting as I'm trying to learn Gem,
The height of the GemWin will always be 4 units? How's that?
Where was I supposed to find about that? I have read a few documentations and none of them specified this... Do you recommend one in particular?
Jé
IOhannes m zmoelnig a écrit :
Roman Haefeli wrote:
hi i'd like to show some images in fullscreen-mode with gem. since it is cheaper to use [pix_texture] than to draw the image directly, i draw a rectangle that fits exactly in the gem-window and apply the image as a texture. i plan to create an application that will be used on different machines with different displays. at the moment i have to change the dimensions of the [rectangle] manually when i use the patch on a machine with different display-resolution.
no you don't!
i think there is a relation between the used resolution and x- and y-values of [rectangle], but i failed finding it. is there a way to calculate these values from the resolution in order to fit the [reactangle] exactly into the gem-window? this would allow to write the actual resolution in a config-file whitout the need of changing the patch.
the only problematic thing that can happen to you is when your aspect-ratio changes. a rectangle that covers the full-screen on 500x500 will not cover the entire screen on 800x600; however: the same rectangle that covers 1024x768 will also cover a 1600x1200 screen (or a 320x240 window)
note: the height of the gemwindow will always be 4 units (the width will change with the aspect-ratio)
note: you will probably want to keep the aspect-ratio in order to not distort your images)
mf.a.r IOhannes
PS: if you find that i am talking non-sense, then you are likely to have discovered a bug
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
Jerome Tuncer wrote:
Hallo Iohannes,
You said something that I find interesting as I'm trying to learn Gem,
The height of the GemWin will always be 4 units? How's that?
oh, i have to apologize and become more accurate: an object with height 4 at position 0/0/0 with the camera at the default-position (0/0/-4) and the default perspective-setting will touch the upper and the lower border of the window exactly.
Where was I supposed to find about that? I have read a few documentations and none of them specified this... Do you recommend one in particular?
i guess this is no-where specified, what i have told as a fact has been gathered empiristically.
the important thing to remember is: in Gem you are viewing with a camera onto a 3D-scene. under certain circumstances (relative position camera vs. object; camera settings) the abstract units can be mapped to pixels rather simply. but these are "special cases".
mfg,.as.dr IOhannes
hi IOhannes
IOhannes m zmoelnig wrote:
Roman Haefeli wrote:
hi
i'd like to show some images in fullscreen-mode with gem. since it is cheaper to use [pix_texture] than to draw the image directly, i draw a rectangle that fits exactly in the gem-window and apply the image as a texture. i plan to create an application that will be used on different machines with different displays. at the moment i have to change the dimensions of the [rectangle] manually when i use the patch on a machine with different display-resolution.
no you don't!
i think there is a relation between the used resolution and x- and y-values of [rectangle], but i failed finding it. is there a way to calculate these values from the resolution in order to fit the [reactangle] exactly into the gem-window? this would allow to write the actual resolution in a config-file whitout the need of changing the patch.
the only problematic thing that can happen to you is when your aspect-ratio changes. a rectangle that covers the full-screen on 500x500 will not cover the entire screen on 800x600; however: the same rectangle that covers 1024x768 will also cover a 1600x1200 screen (or a 320x240 window)
note: the height of the gemwindow will always be 4 units (the width
will
change with the aspect-ratio)
thanks. i hoped it would be that easy to handle.
note: you will probably want to keep the aspect-ratio in order to not distort your images)
yes, i know. the images do always have the resolution (and, of course, the aspect-ratio) of the used screen, so this won't be a problem. by the way: if i fit the rectangle exactly into the window and the image has the same resolution as the screen, are there any interpolation artefacts?
regards roman
mf.a.r IOhannes
PS: if you find that i am talking non-sense, then you are likely to
have
discovered a bug
___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de