|
View:
New views
3 Messages
—
Rating Filter:
Alert me
|
|
|
glViewport queryHi I am new to gtkglext trying to run some simple sample programs. In gtkglext, we create a drawing area as a widget and then set the size of the viewport using glviewport().Is the size of the drawing area not same as the size of the viewport? If not,then y? why would anyone make the size of drawing area and viewport different when viewport is also used to limit the size of drawing area? Also where is the coordinate (0,0) located on a window in this case? for gtk applications,it is located at top left corner.for gtkglext,where is it located? I am getting confused with the negative coordinates used in glviewport and glrectf and similar fns. |
|
|
Re: glViewport queryHi ,
glViewport specifies the affine transformation of x and y from normalized device coordinates to window coordinates and could be different than size of the widget. Try setting it to (w/2 , h/2 ) and (2*w, 2*h) to see the difference. You could zoom in or out using viewport with same widget size. (0,0 ) is the lower left corner of the viewport rectangle ~Prashant On Fri, Jul 10, 2009 at 7:41 PM, jyotigoyal <jytgyl@...> wrote:
_______________________________________________ gtkglext-list mailing list gtkglext-list@... http://mail.gnome.org/mailman/listinfo/gtkglext-list |
|
|
Re: glViewport queryHi ,
glViewport specifies the affine transformation of x and y from normalized device coordinates to window coordinates and could be different than size of the widget. Try setting it to (w/2 , h/2 ) and (2*w, 2*h) to see the difference. You could zoom in or out using viewport with same widget size. (0,0 ) is the lower left corner of the viewport rectangle ~Prashant
|
| Free embeddable forum powered by Nabble | Forum Help |