[PD] GEM mapping units to pixels

chris clepper cgclepper at gmail.com
Sun May 13 21:41:25 CEST 2007


On 5/13/07, altern <altern2 at gmail.com> wrote:
>
>
>
> ah!... now i see ... so [rectangle 1 1] is equivalent to
>
>      glBegin(GL_QUADS)
>      glVertex3f(-1.0, 1.0, 0.0)
>      glVertex3f(1.0, 1.0, 0.0)
>      glVertex3f(1.0, -1.0, 0.0)
>      glVertex3f(-1.0, -1.0, 0.0)
>      glEnd()
>
> so the final width and height is actually 2 units ... this is a bit
> confusing in the documentation help patch, i mean i know some opengl but
> still when i read width height words i thought about the width and
> height of a rectangle in normal geometry and not opengl postion of the
> vertex location from the current position.


You are correct that the size of the rectangle is the dimensions from the
center of the object.  Arguments can be made for treating size this way or
making the size the actual final dimensions in GL units, but both are valid
as long as the use is consistent.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20070513/1e92829e/attachment.htm>


More information about the Pd-list mailing list