---
name: "vga_getscansegment"
section: "3"
platform: "linux"
package: "libsvga1-dev"
version: "1:1.4.3-33"
release: "Debian 7 (Wheezy)"
platforms: ["linux"]
url: "https://new.carta.tech/vga_getscansegment"
---

# vga\_getscansegment(3)

get a list of consecutive pixel values

## NAME

vga\_getscansegment - get a list of consecutive pixel values

## SYNOPSIS

**#include \<vga.h\>**

**int vga\_getscansegment(unsigned char \****colors***, int** *x***, int** *y***, int** *length***);**

## DESCRIPTION

The direct opposite of vga\_drawscansegment(). The line of *length* pixels starting at **(***x***,** *y***)** is not drawn but instead the colorvalues are taken from the screen and copied into *color***\[0\] ..** *color***\[***length* **- 1\].** Svgalib versions was introduced in version 1.2.10. In high/truecolor modes, the length must be given in bytes, not pixels.

## SEE ALSO

[**svgalib**(7)](/svgalib/7.md), [**vgagl**(7)](/vgagl/7.md), [**libvga.config**(5)](/libvga.config/5.md), [**vga\_clear**(3)](/vga_clear/3.md), [**vga\_drawpixel**(3)](/vga_drawpixel/3.md), [**vga\_drawline**(3)](/vga_drawline/3.md), [**vga\_getpixel**(3)](/vga_getpixel/3.md), [**vga\_drawscanline**(3)](/vga_drawscanline/3.md), [**vga\_drawscansegment**(3)](/vga_drawscansegment/3.md)

## AUTHOR

This manual page was edited by Michael Weller \<eowmob@exp-math.uni-essen.de\>. The referenced function and its documentation are due to Bill Randle \<billr@master.CNA.TEK.COM\>.
