android UI format not match issue on imx7d android-pie

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

android UI format not match issue on imx7d android-pie

ソリューションへジャンプ
922件の閲覧回数
patrickzhang1024
Contributor II

Hi,

       I'm porting a new LCD to my imx7d DIY development board.

kernel: 4.14

android: 9

      Screen size is 320x240, physical format is RGB565. And I get a very weird issue. The main screen and some android applications can showing correctly. But some android applications are not refresh.

      If I do further debugging, I can find in FbDisplay.cpp, the updateScreen() function report buffer format is RGBA8888 but config format is RGB565, so the refresh operation is stopped.

 

     If I force the 

getBE().mRenderEngine =

         RE::impl::RenderEngine::create(HAL_PIXEL_FORMAT_RGBA_8888 

to be 

getBE().mRenderEngine =

            RE::impl::RenderEngine::create(HAL_PIXEL_FORMAT_RGB_565

those android application can show on the screen, but red and blue pixel are oppsite. If I use this method, I can't monitor the screen on my PC.

I want to know what thing cause this format not match issue and how do I perfectly fix it?

タグ(2)
0 件の賞賛
返信
1 解決策
837件の閲覧回数
patrickzhang1024
Contributor II

Hi Zhiming,

 

    Thank you with your suggestion. I already find out a solution to fix that issue. By rotate the screen orientation in kotlin project. Probably, layout height is too long for android framework to resize. I should change the width:height in my layout.

 

Regards!

PatrickZ

元の投稿で解決策を見る

0 件の賞賛
返信
4 返答(返信)
885件の閲覧回数
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hello,

This may have something to do with the code of the application that is having problems, the application is using 32bit data, so in the HAL layer code the return is RGB888. You need to look at the code of the application again to try to fix the problem.

https://github.com/nxp-imx-android/android-imx_platform_hardware_imx/blob/p9.0.0_2.3.4/display/displ...

Best Regards,
Zhiming

0 件の賞賛
返信
880件の閲覧回数
patrickzhang1024
Contributor II

Hi Zhiming,

    Do you mean it might be something wrong in the android kotlin application? The config.format in Fbdisplay is all right, and I think the issue is comes from surfaceflinger. The buffer.format remains RGBA8888.

 

Regards!

Patrick Zhang

0 件の賞賛
返信
845件の閲覧回数
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hello,

As my understanding about surfaceflinger, the surfaceflinger is a Render Engine, it receives the operations from application layer  and then call the fbdisplay to display. So the issue could from application layer, the app tells Render Engine how to render a frame. I don't think the Render Engine is designed for one pixel format, the pixel format should be set from the app layer.

Best Regards,
Zhiming

0 件の賞賛
返信
838件の閲覧回数
patrickzhang1024
Contributor II

Hi Zhiming,

 

    Thank you with your suggestion. I already find out a solution to fix that issue. By rotate the screen orientation in kotlin project. Probably, layout height is too long for android framework to resize. I should change the width:height in my layout.

 

Regards!

PatrickZ

0 件の賞賛
返信