---
name: "ggiCopyBox"
section: "3ggi"
platform: "linux"
package: "libggi2-dev"
version: "1:2.0.1-2"
release: "Debian 3.0 (Woody)"
platforms: ["linux"]
url: "https://new.carta.tech/ggiCopyBox/3ggi"
---

# ggiCopyBox(3ggi)

Copy a rectangular area

## NAME

ggiCopyBox - Copy a rectangular area

## SYNOPSIS

**#include \<ggi/ggi.h\>**

**int ggiCopyBox(ggi\_visual\_t** *vis***,**  **int** *x***, int** *y***,**  **int** *w***, int** *h***,**  **int** *nx***, int** *ny***);** .SH "DESCRIPTION"

This is a area-to-area-blit, all in the same visual. Copy the box described by *x*,*y*,*w*,*h* to the new location *nx*,*ny*. This automatically takes care of overlaps and optimizes for the given visual (e.g. uses HW-accel or intermediate buffers as appropriate).

**ggiCopyBox** will transfer an area between frames when the read frame is not the same as the write frame.

## RETURN VALUE

0 for OK, otherwise an error code.

## SEE ALSO

\[XRef to GGICROSSBLIT\]
