fg_vbscale()

Win32 DirectX Fastgraph/Light

Prototype

void fg_vbscale (int minx, int maxx, int miny, int maxy, int xmin, int xmax, int ymin, int ymax);

Sub fg_vbscale (ByVal minx As Long, ByVal maxx As Long, ByVal miny As Long, ByVal maxy As Long, ByVal xmin As Long, ByVal xmax As Long, ByVal ymin As Long, ByVal ymax As Long)

procedure fg_vbprint (minx, maxx, miny, maxy, xmin, xmax, ymin, ymax : integer);

Description

The fg_vbscale() function copies a rectangular region from the active virtual buffer to the window's client area, scaling the image to fit the client area as requested. Source coordinates are expressed in screen space, while destination coordinates are expressed as client coordinates. The WM_PAINT message handler usually calls fg_vbpaste() or fg_vbscale().

Parameters

minx is the x coordinate of the source region's left edge.

maxx is the x coordinate of the source region's right edge. It must be greater than or equal to the value of minx.

miny is the y coordinate of the source region's top edge.

maxy is the y coordinate of the source region's bottom edge. It must be greater than or equal to the value of miny.

xmin is the x coordinate of the destination region's left edge.

xmax is the x coordinate of the destination region's right edge. It must be greater than or equal to the value of xmin.

ymin is the y coordinate of the destination region's top edge.

ymax is the y coordinate of the destination region's bottom edge. It must be greater than or equal to the value of ymin.

Return value

none

Restrictions

When using DirectX, the active virtual buffer must not be locked.

See also

fg_scale(), fg_vbpaste()

Examples

First and nearly all the other example programs use this function.

Contents
Fastgraph Home Page

 

copyright 2001 Ted Gruber Software, Inc.