EasyManua.ls Logo

Bridgetek FT801 - CMD_SNAPSHOT - Take a Snapshot of the Current Screen

Default Icon
263 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
FT800 Series Programmer Guide
Version 2.1
Document Reference No.: BRT_000030 Clearance No.: BRT#037
245
Product Page
Document Feedback Copyright © Bridgetek Limited
5.54 CMD_SNAPSHOT - take a snapshot of the current screen
This command causes the co-processor engine to take a snapshot of the current screen,
and write the result into RAM_G as a ARGB4 bitmap. The size of the bitmap is the size of
the screen, given by the REG_HSIZE and REG_VSIZE registers.
During the snapshot process, the display should be disabled by setting REG_PCLK to 0 to
avoid display glitch.
Because co-processor engine needs to write the result into the destination address, the
destination address must be never used or referenced by graphics engine.
C prototype
void cmd_snapshot( uint32_t ptr );
Parameters
ptr
Snapshot destination address, in RAM_G
Command layout
+0
CMD_SNAPSHOT(0xffffff1f)
+4
ptr
Examples
To take a snapshot of the current 160 x 120 screen, then use it as a bitmap in the
new display list:
wr(REG_PCLK,0);//Turn off the PCLK
wr16(REG_HSIZE,120);
wr16(REG_WSIZE,160);
cmd_snapshot(0);//Taking snapshot.
wr(REG_PCLK,5);//Turn on the PCLK
wr16(REG_HSIZE,272);
wr16(REG_WSIZE,480);
cmd_dlstart();
cmd(CLEAR(1,1,1));
cmd(BITMAP_SOURCE(0));
cmd(BITMAP_LAYOUT(ARGB4, 2 * 160, 120));
cmd(BITMAP_SIZE(NEAREST, BORDER, BORDER, 160, 120));
cmd(BEGIN(BITMAPS));
cmd(VERTEX2II(10, 10, 0, 0));
Code snippet 18 CMD_SNAPSHOT 160x120screen

Table of Contents