Question
getting bitmap ID from C++ code
Hello,
I have user parameters in my device and every single parameter will have 5 image. Image will be choosen acorrding the working scenario.
I want to store bitmap ID in my memory area so want to get bitmap ID from C++ code.
Touchgfx generates "BitmapDatabase.hpp" . It ıncludes bit map IDs like below
// Generated by imageconverter. Please, do not edit!
#ifndef BITMAPDATABASE_HPP
#define BITMAPDATABASE_HPP
#include <touchgfx/hal/Types.hpp>
#include <touchgfx/lcd/LCD.hpp>
#include <touchgfx/Bitmap.hpp>
const uint16_t BITMAP_A_ID = 0;
const uint16_t BITMAP_B_ID = 1;
namespace BitmapDatabase
{
const touchgfx::Bitmap::BitmapData* getInstance();
uint16_t getInstanceSize();
}
#endifand I try to add below two lines to my C file
extern "C" const uint16_t BITMAP_A_ID ;
extern "C" const uint16_t BITMAP_B_ID ;or
extern const uint16_t BITMAP_A_ID ;
extern const uint16_t BITMAP_B_ID ;
But both lines caueses error and I cant reach to bitmap ID.
How can I get bitmap IDs from touchgfx generated C++ code ?
Thanks.
