FTDI Community

Please login or register.

Login with username, password and session length.
Advanced Search  

News:

Welcome to the FTDI Community!

Please read our Welcome Note

Technical Support enquires
please contact the team
@ FTDI Support


New Bridgetek Community is now open

Please note that we have created the Bridgetek Community to discuss all Bridgetek products e.g. EVE, MCU.

Please follow this link and create a new user account to get started.

Bridgetek Community

Author Topic: EVE-813 + CMD_SETROTATE + PALETTED8 problem  (Read 1355 times)

mrm78

  • Newbie
  • *
  • Posts: 2
    • View Profile
EVE-813 + CMD_SETROTATE + PALETTED8 problem
« on: March 19, 2018, 07:54:17 AM »

Hi Dear FTDI Support Team. :)

Currently I am working on an Application using your FT813 chip (Hardware-Version 1.00) .

It’s a great Chip, but currently I am struggling with a Problem using the CMD_SETROTATE command and Displaying an 480x 800 pixel (PALETTED8 format) background picture.

I converted an Picture with your “pngp2pa.exe” (Version V0.4) Tool and loaded the Data into the GRAM.

The Picture will be shown not correctly (it seems to be stretched horizontaly and the Red channel seems to destroy the picture)

Maybe somebody can help me with this problem?

Thank you,

Marcel Cevani

Greetings from Germany.

STRACK LIFT AUTOMATION GmbH

------------------------------------------

Source-Code I used to display the Picture:

u32 pic_adr = 0;
u32 pal_adr = 1000000UL;
                                       
u16 pic_fmt    = PALETTED8;
u16 pic_width  = 480;
u16 pic_height = 800;
u16 pic_stride = 480;
s16 x = 0;
s16 y = 0;
                           
addCL_u32(CMD_DLSTART);
addCL_u32(CLEAR_COLOR_RGB(0, 0, 0));
addCL_u32(CLEAR(1,1,1));
addCL_u32(VERTEX_FORMAT(0));
addCL_SetRotate(2);
                                 
addCL_u32(SAVE_CONTEXT());
addCL_u32(BITMAP_HANDLE(0));
addCL_u32(BITMAP_LAYOUT(pic_fmt, pic_stride & 0x3ff, pic_height & 0x1ff));
addCL_u32(BITMAP_LAYOUT_H(pic_stride >> 10, pic_height >> 9));
addCL_u32(BITMAP_SIZE(NEAREST, BORDER, BORDER, pic_width & 0x1ff, pic_height & 0x1ff));
addCL_u32(BITMAP_SIZE_H(pic_width >> 9, pic_height >> 9));
addCL_u32(BITMAP_SOURCE(pic_adr));
addCL_u32(BEGIN(BITMAPS));
addCL_u32(BLEND_FUNC(ONE, ZERO));
addCL_u32(COLOR_MASK(0,0,0,1));
addCL_u32(PALETTE_SOURCE(pal_adr + 3));
addCL_u32(VERTEX2F(x, y));
addCL_u32(BLEND_FUNC(DST_ALPHA, ONE_MINUS_DST_ALPHA));
addCL_u32(COLOR_MASK(1,0,0,0));
addCL_u32(PALETTE_SOURCE(pal_adr + 2));
addCL_u32(VERTEX2F(x, y));
addCL_u32(COLOR_MASK(0,1,0,0));
addCL_u32(PALETTE_SOURCE(pal_adr + 1));
addCL_u32(VERTEX2F(x, y));
addCL_u32(COLOR_MASK(0,0,1,0));
addCL_u32(PALETTE_SOURCE(pal_adr));
addCL_u32(VERTEX2F(x, y));
addCL_u32(END());
addCL_u32(RESTORE_CONTEXT());
                                 
addCL_u32(DISPLAY());
Ft_GPU_DLSwap();
Ft_Gpu_Hal_WaitCmdfifo_empty();
Logged

FTDI Community

  • Administrator
  • Full Member
  • *****
  • Posts: 229
    • View Profile
Re: EVE-813 + CMD_SETROTATE + PALETTED8 problem
« Reply #1 on: March 19, 2018, 01:04:19 PM »

Hello Marcel,

Thanks for your question. We also received your email with details of the issue and are currently looking into it for you.

Best Regards,
FTDI Community
Logged

pauljiao

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: EVE-813 + CMD_SETROTATE + PALETTED8 problem
« Reply #2 on: April 18, 2018, 09:46:24 AM »

Hi Marcel,
  I tried your code and it works fine for me.

  I enclosed the converted EVE Paletted8 format data for you to reference(with .raw file extension), which is working on my side.


  The pngp2pa.exe requires the pngquant.exe was run for the input file in advance. pngquant is the utility to make sure the input PNG file is in correct format.

   Let me know if it is working for you.
Logged