BRT Community

Please login or register.

Login with username, password and session length
Advanced search  

News:

Welcome to the Bridgetek Community!

Please read our Welcome Note

Technical Support enquires
please contact the team
@ Bridgetek Support

Please refer to our website for detailed information on all our products - Bridgetek - Bridging Technology

Author Topic: Display Image Directly from Flash Memory EVE4  (Read 78 times)

vdc

  • Newbie
  • *
  • Posts: 16
    • View Profile
Display Image Directly from Flash Memory EVE4
« on: August 01, 2022, 05:49:57 PM »

Hi,

I tried to display an image directly from the flash. But it won't display.

This is the code I use to for display
Code: [Select]


#define FLUID_COMPRESSED_ADDRESS 1361024
#define FLUID_COMPRESSED_SIZE 167040
#define FLUID_COMPRESSED_W 360
#define FLUID_COMPRESSED_H 464


Gpu_CoCmd_FlashHelper_SwitchFullMode(phost);
App_WrCoCmd_Buffer(phost, COLOR_RGB(0xFF, 0xCA, 0x18));
Gpu_CoCmd_SetBitmap(phost, 0x800000 | (FLUID_COMPRESSED_ADDRESS / 32), COMPRESSED_RGBA_ASTC_4x4_KHR, 360, 464);
App_WrCoCmd_Buffer(phost, BEGIN(BITMAPS));
App_WrCoCmd_Buffer(phost, VERTEX2F(300*16, 150*16)); // App_WrCoCmd_Buffer(phost, VERTEX2II(300, 150, 0, 0));
App_WrCoCmd_Buffer(phost, END());



Here is the Flash map file.

Code: [Select]
unified.blob                                      : 0       : 4096 
EDF Block                                         : 4096    : 192   
Belmont_Logo_575x272_RGB565.raw                   : 4288    : 312832
FluidBag_358x464_RGB565.raw                       : 317120  : 332224
Prime_Empty_353x504_RGB565.raw                    : 649344  : 355840
Prime_Full_353x504_RGB565.raw                     : 1005184 : 355840
FluidBag_360x464_COMPRESSED_RGBA_ASTC_4x4_KHR.raw : 1361024 : 167040



I based on the example from EAB generated to display, but it doesn't show anything. Do I need to do anything else? In the EAB, I select exhaustive as ASTC Preset, I just wonder if I need to use ASTC Options to make this works.

P/s: If I draw the image from y = 0 then this works. VERTEX2F(300*16, 0*16) OR VERTEX2II(300, 0, 0, 0). This works fine starting at y = 0. But I don't want my image starting from 0. Is there other way to do this?

Best regards,
« Last Edit: August 01, 2022, 09:04:19 PM by vdc »
Logged