Windows desktop applications
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

glPixelZoom function

The glPixelZoom function specifies the pixel zoom factors.

Syntax


void WINAPI glPixelZoom(
   GLfloat xfactor,
   GLfloat yfactor
);

Parameters

xfactor

The x zoom factor for pixel write operations.

yfactor

The y zoom factor for pixel write operations.

Return value

This function does not return a value.

Error codes

The following error code can be retrieved by the glGetError function.

NameMeaning
GL_INVALID_OPERATION

The function was called between a call to glBegin and the corresponding call to glEnd.

Error codes

The following error code can be retrieved by the glGetError function.

NameMeaning
GL_INVALID_OPERATION

The function was called between a call to glBegin and the corresponding call to glEnd.

Remarks

The glPixelZoom function specifies values for the x and y zoom factors. During the execution of glDrawPixels or glCopyPixels, if (xr ,yr ) is the current raster position, and a given element is in the nth row and mth column of the pixel rectangle, then pixels whose centers are in the rectangle with corners at

Dd373970.pix05(en-us,VS.85).png

are candidates for replacement. Any pixel whose center lies on the bottom or left edge of this rectangular region is also modified.

Pixel zoom factors are not limited to positive values. Negative zoom factors reflect the resulting image about the current raster position.

The following functions retrieve information related to glPixelZoom:

glGet with argument GL_ZOOM_X

glGet with argument GL_ZOOM_Y

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Gl.h

Library

Opengl32.lib

DLL

Opengl32.dll

See also

glBegin
glCopyPixels
glDrawPixels
glEnd

 

 

Show:
© 2016 Microsoft