Jump to content

Component: GLCD Bitmap Drawer FAT (Graphical Library): Difference between revisions

From Flowcode Help
No edit summary
m Text replacement - "width="90%" style="background-color:#D8C9D8; color:#4B008D;"" to "width="90%" class="mtx-class-macrohead""
 
(17 intermediate revisions by 3 users not shown)
Line 5: Line 5:
|-
|-
| width="20%" style="color:gray;" | Version
| width="20%" style="color:gray;" | Version
| 2.2
| 3.0
|-
|-
| width="20%" style="color:gray;" | Category
| width="20%" style="color:gray;" | Category
Line 15: Line 15:
A component to simplify the process of drawing bitmap images to a graphical display. Reads Bitmap files directly from a SD card formatted with a FAT file system. Compatible with 24-bit &  Monochrome Bitmaps. The gLCD object property specifies which LCD component to draw the bitmap to. Compatible with GLCD, NeoPixel, MIACv3, HT16K33
A component to simplify the process of drawing bitmap images to a graphical display. Reads Bitmap files directly from a SD card formatted with a FAT file system. Compatible with 24-bit &  Monochrome Bitmaps. The gLCD object property specifies which LCD component to draw the bitmap to. Compatible with GLCD, NeoPixel, MIACv3, HT16K33


==Component Source Code==
==Version information==
 
Please click here to download the component source project: [https://www.flowcode.co.uk/wiki/componentsource/FC_Comp_Source_Lib_Draw_Bitmap_FAT.fcfx FC_Comp_Source_Lib_Draw_Bitmap_FAT.fcfx]


Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/FC_Comp_Source_Lib_Draw_Bitmap_FAT.fcfx FC_Comp_Source_Lib_Draw_Bitmap_FAT.fcfx]
Library Version, Component Version, Date, Author, Info
20, 1.0, 26-07-24, BR, Added pallet buffer allowing 4,8-bit bitmaps to function


==Detailed description==
==Detailed description==


''No detailed description exists yet for this component''
''No detailed description exists yet for this component''
Line 37: Line 26:
==Examples==
==Examples==


Here is an example that will scan for bitmap files in the root of the SD card and display them on a graphical display.


{{Zip|BitmapDrawer_File_Demo.zip|Bitmap Drawer File Demo}}




The zip file contains the Flowcode project as well as some example bitmap image files taken from Pixabay.


Place the bitmap files in the same folder as the project file for the simulation to work.


Place the bitmap files on the root of the SD card for the embedded hardware to work.




''<span style="color:red;">No additional examples</span>''




Line 53: Line 43:
==Macro reference==
==Macro reference==


{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
===Display_BMP===
{| class="mtx-class-macrotable wikitable"
|-
|-
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetHeight'''
| width="90%" class="mtx-class-macrohead" | '''Display_BMP'''
|-
|-
| colspan="2" | Returns the height of the loaded bitmap file in pixels.&nbsp;
| colspan="2" | Draws the bitmap image onto the display at the corrdinates X and Y. Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound&nbsp;
|-
|-
|-
|-
Line 64: Line 55:
| width="90%" | Filename
| width="90%" | Filename
|-
|-
| colspan="2" | The filename of the bitmap we want to measure&nbsp;
| colspan="2" | Bitmap file to open from current directory on SD card 8.3 format&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | X
|-
| colspan="2" | X Axis coordinate, specifies the location of the left edge of the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | Y
|-
| colspan="2" | Y Axis coordinate, specifies the location of the top edge of the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | Orientation
|-
| colspan="2" | 0=Normal, 1=90 Degrees CW, 2=180 Degrees, 3=270 Degrees CW&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | Transparency
|-
| colspan="2" | 0=Off, 1=On Don't Draw Any Pixels which match the transparent colour&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | Flip
|-
| colspan="2" | 0=Normal, 1=FlipWidth, 2=FlipHeight, 3=FlipBoth&nbsp;
|-
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u16-icon.png]] - UINT
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" style="border-top: 2px solid #000;" | ''Return''
| width="90%" style="border-top: 2px solid #000;" | ''Return''
|}
|}




{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
===Display_BMP_Fast===
{| class="mtx-class-macrotable wikitable"
|-
|-
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetWidth'''
| width="90%" class="mtx-class-macrohead" | '''Display_BMP_Fast'''
|-
|-
| colspan="2" | Returns the width of the loaded bitmap file in pixels.&nbsp;
| colspan="2" | Draws the bitmap image onto the display at the corrdinates X and Y. Speeds up drawing by not assigning X/Y coordinate for each pixel. Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound&nbsp;
|-
|-
|-
|-
Line 82: Line 99:
| width="90%" | Filename
| width="90%" | Filename
|-
|-
| colspan="2" | The filename of the bitmap we want to measure&nbsp;
| colspan="2" | Bitmap file to open from current directory on SD card 8.3 format&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | X
|-
| colspan="2" | X Axis coordinate, specifies the location of the left edge of the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | Y
|-
| colspan="2" | Y Axis coordinate, specifies the location of the top edge of the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-bool-icon.png]] - BOOL
| width="90%" | Mode
|-
| colspan="2" | 0=RowByRow, 1=FullWindow(Y Flipped)&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-bool-icon.png]] - BOOL
| width="90%" | Orientation
|-
| colspan="2" | 0=Default, 1=Rotated 90 Degrees (only works with Mode 0)&nbsp;
|-
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u16-icon.png]] - UINT
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" style="border-top: 2px solid #000;" | ''Return''
| width="90%" style="border-top: 2px solid #000;" | ''Return''
|}
|}




{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
===Display_BMP_Fast_Partial===
{| class="mtx-class-macrotable wikitable"
|-
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]]
| width="90%" class="mtx-class-macrohead" | '''Display_BMP_Fast_Partial'''
|-
| colspan="2" | Draws a partial bitmap image onto the display at the coordinates X and Y. Speeds up drawing by not assigning X/Y coordinate for each pixel. Allows drawing a percentage of the bitmap width and height from a specified side (top/bottom, left/right). Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound&nbsp;
|-
|-
| width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING
| width="90%" | Filename
|-
| colspan="2" | Bitmap file to open from current directory on SD card 8.3 format&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | X
|-
|-
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| colspan="2" | X Axis coordinate, specifies the location of the left edge of the bitmap image&nbsp;
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetTransparentColour'''
|-
|-
| colspan="2" | Sets the transparency colour, the colour that is not drawn when transparency is enabled.&nbsp;
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | Y
|-
| colspan="2" | Y Axis coordinate, specifies the location of the top edge of the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | WidthPercent
|-
|-
| colspan="2" | Percentage of bitmap width to draw. Range: 0-100&nbsp;
|-
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | R
| width="90%" | HeightPercent
|-
|-
| colspan="2" | &nbsp;
| colspan="2" | Percentage of bitmap height to draw. Range: 0-100&nbsp;
|-
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | G
| width="90%" | HorizontalSide
|-
|-
| colspan="2" | &nbsp;
| colspan="2" | Which horizontal side to draw from: 0=Left, 1=Right&nbsp;
|-
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | B
| width="90%" | VerticalSide
|-
| colspan="2" | Which vertical side to draw from: 0=Top, 1=Bottom&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-bool-icon.png]] - BOOL
| width="90%" | Mode
|-
| colspan="2" | 0=RowByRow, 1=FullWindow(Y Flipped)&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-bool-icon.png]] - BOOL
| width="90%" | Orientation
|-
|-
| colspan="2" | &nbsp;
| colspan="2" | 0=Default, 1=Rotated 90 Degrees (only works with Mode 0)&nbsp;
|-
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" style="border-top: 2px solid #000;" | ''Return''
| width="90%" style="border-top: 2px solid #000;" | ''Return''
|}
|}




{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
===Display_BMP_Partial===
{| class="mtx-class-macrotable wikitable"
|-
|-
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Display_BMP'''
| width="90%" class="mtx-class-macrohead" | '''Display_BMP_Partial'''
|-
|-
| colspan="2" | Draws the bitmap image from ROM onto the display at the corrdinates X and Y. Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound&nbsp;
| colspan="2" | Draws a partial bitmap image onto the display at the coordinates X and Y. Allows drawing a percentage of the bitmap width and height from a specified side (top/bottom, left/right). Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound&nbsp;
|-
|-
|-
|-
Line 139: Line 208:
|-
|-
| colspan="2" | Y Axis coordinate, specifies the location of the top edge of the bitmap image&nbsp;
| colspan="2" | Y Axis coordinate, specifies the location of the top edge of the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | WidthPercent
|-
| colspan="2" | Percentage of bitmap width to draw. Range: 0-100&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | HeightPercent
|-
| colspan="2" | Percentage of bitmap height to draw. Range: 0-100&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | HorizontalSide
|-
| colspan="2" | Which horizontal side to draw from: 0=Left, 1=Right&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | VerticalSide
|-
| colspan="2" | Which vertical side to draw from: 0=Top, 1=Bottom&nbsp;
|-
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
Line 160: Line 249:




{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
===Display_Scaled_BMP===
{| class="mtx-class-macrotable wikitable"
|-
|-
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Display_BMP_Fast'''
| width="90%" class="mtx-class-macrohead" | '''Display_Scaled_BMP'''
|-
|-
| colspan="2" | Draws the bitmap image from ROM onto the display at the corrdinates X and Y. Attempts to draw a row at a time by not forcing coordinates for every pixel so may not work on some displays. Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound&nbsp;
| colspan="2" | Draws the bitmap image onto the display at the corrdinates X and Y. Scales the bitmap to the specified width and height. Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound&nbsp;
|-
|-
|-
|-
Line 182: Line 272:
|-
|-
| colspan="2" | Y Axis coordinate, specifies the location of the top edge of the bitmap image&nbsp;
| colspan="2" | Y Axis coordinate, specifies the location of the top edge of the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | Width
|-
| colspan="2" | The size in pixels to draw the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | Height
|-
| colspan="2" | The size in pixels to draw the bitmap image&nbsp;
|-
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
Line 203: Line 303:




===Display_Scaled_BMP_Fast===
{| class="mtx-class-macrotable wikitable"
|-
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]]
| width="90%" class="mtx-class-macrohead" | '''Display_Scaled_BMP_Fast'''
|-
| colspan="2" | Draws the bitmap image onto the display at the corrdinates X and Y. Scales the bitmap to the specified width and height. Speeds up drawing by not assigning X/Y coordinate for each pixel. Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound&nbsp;
|-
|-
| width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING
| width="90%" | Filename
|-
| colspan="2" | Bitmap file to open from current directory on SD card 8.3 format&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | X
|-
| colspan="2" | X Axis coordinate, specifies the location of the left edge of the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | Y
|-
| colspan="2" | Y Axis coordinate, specifies the location of the top edge of the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | Width
|-
| colspan="2" | The size in pixels to draw the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" | Height
|-
| colspan="2" | The size in pixels to draw the bitmap image&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-bool-icon.png]] - BOOL
| width="90%" | Mode
|-
| colspan="2" | 0=RowByRow, 1=FullWindow(Y Flipped)&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-bool-icon.png]] - BOOL
| width="90%" | Orientation
|-
| colspan="2" | 0=Default, 1=Rotated 90 Degrees (only works with Mode 0)&nbsp;
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" style="border-top: 2px solid #000;" | ''Return''
|}
===GetHeight===
{| class="mtx-class-macrotable wikitable"
|-
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]]
| width="90%" class="mtx-class-macrohead" | '''GetHeight'''
|-
| colspan="2" | Returns the height of the loaded bitmap file in pixels.&nbsp;
|-
|-
| width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING
| width="90%" | Filename
|-
| colspan="2" | The filename of the bitmap we want to measure&nbsp;
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" style="border-top: 2px solid #000;" | ''Return''
|}
===GetWidth===
{| class="mtx-class-macrotable wikitable"
|-
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]]
| width="90%" class="mtx-class-macrohead" | '''GetWidth'''
|-
| colspan="2" | Returns the width of the loaded bitmap file in pixels.&nbsp;
|-
|-
| width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING
| width="90%" | Filename
|-
| colspan="2" | The filename of the bitmap we want to measure&nbsp;
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u16-icon.png]] - UINT
| width="90%" style="border-top: 2px solid #000;" | ''Return''
|}
===SetTransparentColour===
{| class="mtx-class-macrotable wikitable"
|-
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]]
| width="90%" class="mtx-class-macrohead" | '''SetTransparentColour'''
|-
| colspan="2" | Sets the transparency colour, the colour that is not drawn when transparency is enabled.&nbsp;
|-
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | R
|-
| colspan="2" | &nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | G
|-
| colspan="2" | &nbsp;
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
| width="90%" | B
|-
| colspan="2" | &nbsp;
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
| width="90%" style="border-top: 2px solid #000;" | ''Return''
|}




==Property reference==
==Property reference==


{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
{| class="mtx-class-macrotable wikitable"
|-
|-
| width="10%" align="center" style="background-color:#D8C9D8;" | [[File:Fc9-prop-icon.png]]
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-prop-icon.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Properties'''  
| width="90%" class="mtx-class-macrohead" | '''Properties'''  
|-
|-
|-
|-
Line 227: Line 441:
|-
|-
| colspan="2" | Automatically detects if the graphical LCD object is colour or monochrome&nbsp;
| colspan="2" | Automatically detects if the graphical LCD object is colour or monochrome&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
| width="90%" | Pallet Buffer
|-
| colspan="2" | Dedicates an area of RAM to be used as a pallet buffer allowing 4-bit and 8-bit bitmaps to be drawn efficiently. No: No additional RAM is used and only 1-bit and 24-bit bitmaps are supported. Yes: 768 additional bytes of RAM are used and 1-bit, 4-bit, 8-bit and 24-bit bitmaps are supported.&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
| width="90%" | Use File Index
|-
| colspan="2" | Allows multiple files to be accessed at once.&nbsp;
|-
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
| width="90%" | Use File Path
|-
| colspan="2" | Allows a path to be specified for accessing bitmap files. e.g. Images\&nbsp;
|}
|}
==Component Source Code==
Please click here to download the component source project: [https://www.flowcode.co.uk/wiki/componentsource/FC_Comp_Source_Lib_Draw_Bitmap_FAT.fcfx FC_Comp_Source_Lib_Draw_Bitmap_FAT.fcfx]
Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/FC_Comp_Source_Lib_Draw_Bitmap_FAT.fcfx FC_Comp_Source_Lib_Draw_Bitmap_FAT.fcfx]

Latest revision as of 14:23, 13 July 2026

Author Matrix TSL
Version 3.0
Category Graphical Library


GLCD Bitmap Drawer FAT component

A component to simplify the process of drawing bitmap images to a graphical display. Reads Bitmap files directly from a SD card formatted with a FAT file system. Compatible with 24-bit & Monochrome Bitmaps. The gLCD object property specifies which LCD component to draw the bitmap to. Compatible with GLCD, NeoPixel, MIACv3, HT16K33

Version information

Library Version, Component Version, Date, Author, Info
20, 1.0, 26-07-24, BR, Added pallet buffer allowing 4,8-bit bitmaps to function

Detailed description

No detailed description exists yet for this component

Examples

Here is an example that will scan for bitmap files in the root of the SD card and display them on a graphical display.

Bitmap Drawer File Demo


The zip file contains the Flowcode project as well as some example bitmap image files taken from Pixabay.

Place the bitmap files in the same folder as the project file for the simulation to work.

Place the bitmap files on the root of the SD card for the embedded hardware to work.



Macro reference

Display_BMP

Display_BMP
Draws the bitmap image onto the display at the corrdinates X and Y. Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound 
- STRING Filename
Bitmap file to open from current directory on SD card 8.3 format 
- UINT X
X Axis coordinate, specifies the location of the left edge of the bitmap image 
- UINT Y
Y Axis coordinate, specifies the location of the top edge of the bitmap image 
- BYTE Orientation
0=Normal, 1=90 Degrees CW, 2=180 Degrees, 3=270 Degrees CW 
- BYTE Transparency
0=Off, 1=On Don't Draw Any Pixels which match the transparent colour 
- BYTE Flip
0=Normal, 1=FlipWidth, 2=FlipHeight, 3=FlipBoth 
- BYTE Return


Display_BMP_Fast

Display_BMP_Fast
Draws the bitmap image onto the display at the corrdinates X and Y. Speeds up drawing by not assigning X/Y coordinate for each pixel. Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound 
- STRING Filename
Bitmap file to open from current directory on SD card 8.3 format 
- UINT X
X Axis coordinate, specifies the location of the left edge of the bitmap image 
- UINT Y
Y Axis coordinate, specifies the location of the top edge of the bitmap image 
- BOOL Mode
0=RowByRow, 1=FullWindow(Y Flipped) 
- BOOL Orientation
0=Default, 1=Rotated 90 Degrees (only works with Mode 0) 
- BYTE Return


Display_BMP_Fast_Partial

Display_BMP_Fast_Partial
Draws a partial bitmap image onto the display at the coordinates X and Y. Speeds up drawing by not assigning X/Y coordinate for each pixel. Allows drawing a percentage of the bitmap width and height from a specified side (top/bottom, left/right). Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound 
- STRING Filename
Bitmap file to open from current directory on SD card 8.3 format 
- UINT X
X Axis coordinate, specifies the location of the left edge of the bitmap image 
- UINT Y
Y Axis coordinate, specifies the location of the top edge of the bitmap image 
- BYTE WidthPercent
Percentage of bitmap width to draw. Range: 0-100 
- BYTE HeightPercent
Percentage of bitmap height to draw. Range: 0-100 
- BYTE HorizontalSide
Which horizontal side to draw from: 0=Left, 1=Right 
- BYTE VerticalSide
Which vertical side to draw from: 0=Top, 1=Bottom 
- BOOL Mode
0=RowByRow, 1=FullWindow(Y Flipped) 
- BOOL Orientation
0=Default, 1=Rotated 90 Degrees (only works with Mode 0) 
- BYTE Return


Display_BMP_Partial

Display_BMP_Partial
Draws a partial bitmap image onto the display at the coordinates X and Y. Allows drawing a percentage of the bitmap width and height from a specified side (top/bottom, left/right). Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound 
- STRING Filename
Bitmap file to open from current directory on SD card 8.3 format 
- UINT X
X Axis coordinate, specifies the location of the left edge of the bitmap image 
- UINT Y
Y Axis coordinate, specifies the location of the top edge of the bitmap image 
- BYTE WidthPercent
Percentage of bitmap width to draw. Range: 0-100 
- BYTE HeightPercent
Percentage of bitmap height to draw. Range: 0-100 
- BYTE HorizontalSide
Which horizontal side to draw from: 0=Left, 1=Right 
- BYTE VerticalSide
Which vertical side to draw from: 0=Top, 1=Bottom 
- BYTE Orientation
0=Normal, 1=90 Degrees CW, 2=180 Degrees, 3=270 Degrees CW 
- BYTE Transparency
0=Off, 1=On Don't Draw Any Pixels which match the transparent colour 
- BYTE Flip
0=Normal, 1=FlipWidth, 2=FlipHeight, 3=FlipBoth 
- BYTE Return


Display_Scaled_BMP

Display_Scaled_BMP
Draws the bitmap image onto the display at the corrdinates X and Y. Scales the bitmap to the specified width and height. Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound 
- STRING Filename
Bitmap file to open from current directory on SD card 8.3 format 
- UINT X
X Axis coordinate, specifies the location of the left edge of the bitmap image 
- UINT Y
Y Axis coordinate, specifies the location of the top edge of the bitmap image 
- UINT Width
The size in pixels to draw the bitmap image 
- UINT Height
The size in pixels to draw the bitmap image 
- BYTE Orientation
0=Normal, 1=90 Degrees CW, 2=180 Degrees, 3=270 Degrees CW 
- BYTE Transparency
0=Off, 1=On Don't Draw Any Pixels which match the transparent colour 
- BYTE Flip
0=Normal, 1=FlipWidth, 2=FlipHeight, 3=FlipBoth 
- BYTE Return


Display_Scaled_BMP_Fast

Display_Scaled_BMP_Fast
Draws the bitmap image onto the display at the corrdinates X and Y. Scales the bitmap to the specified width and height. Speeds up drawing by not assigning X/Y coordinate for each pixel. Return Values: 0=OK, 1=ColourDepthNotSupported, 237=FileNotFound 
- STRING Filename
Bitmap file to open from current directory on SD card 8.3 format 
- UINT X
X Axis coordinate, specifies the location of the left edge of the bitmap image 
- UINT Y
Y Axis coordinate, specifies the location of the top edge of the bitmap image 
- UINT Width
The size in pixels to draw the bitmap image 
- UINT Height
The size in pixels to draw the bitmap image 
- BOOL Mode
0=RowByRow, 1=FullWindow(Y Flipped) 
- BOOL Orientation
0=Default, 1=Rotated 90 Degrees (only works with Mode 0) 
- BYTE Return


GetHeight

GetHeight
Returns the height of the loaded bitmap file in pixels. 
- STRING Filename
The filename of the bitmap we want to measure 
- UINT Return


GetWidth

GetWidth
Returns the width of the loaded bitmap file in pixels. 
- STRING Filename
The filename of the bitmap we want to measure 
- UINT Return


SetTransparentColour

SetTransparentColour
Sets the transparency colour, the colour that is not drawn when transparency is enabled. 
- BYTE R
 
- BYTE G
 
- BYTE B
 
- VOID Return


Property reference

Properties
GLCD LinkTo
 
File LinkTo
 
ColourDisplay
Automatically detects if the graphical LCD object is colour or monochrome 
Pallet Buffer
Dedicates an area of RAM to be used as a pallet buffer allowing 4-bit and 8-bit bitmaps to be drawn efficiently. No: No additional RAM is used and only 1-bit and 24-bit bitmaps are supported. Yes: 768 additional bytes of RAM are used and 1-bit, 4-bit, 8-bit and 24-bit bitmaps are supported. 
Use File Index
Allows multiple files to be accessed at once. 
Use File Path
Allows a path to be specified for accessing bitmap files. e.g. Images\ 

Component Source Code

Please click here to download the component source project: FC_Comp_Source_Lib_Draw_Bitmap_FAT.fcfx

Please click here to view the component source code (Beta): FC_Comp_Source_Lib_Draw_Bitmap_FAT.fcfx