kernel logo到開機動畫之間閃現黑屏(android 5.X)

來源:互聯網
上載者:User

標籤:

在BootAnimation開始繪圖之前,會先做一次clear screen的動作,避免出現前面的圖幹擾到BootAnimation的顯示。

通過check main_log先確認播放開機動畫是哪個function,在對應function刪除clear screen的動作的對應代碼。
/frameworks/base/cmds/bootanimation/BootAnimation.cpp
450bool BootAnimation::android()
451{
452 initTexture(&mAndroid[0], mAssets, "images/android-logo-mask.png");
453 initTexture(&mAndroid[1], mAssets, "images/android-logo-shine.png");
454
 
/*-刪除clear screen對應code-*/
455 // clear screen
456 glShadeModel(GL_FLAT);
457 glDisable(GL_DITHER);
458 glDisable(GL_SCISSOR_TEST);
459 glClearColor(0,0,0,1);
460 glClear(GL_COLOR_BUFFER_BIT);
461 eglSwapBuffers(mDisplay, mSurface);
/*-刪除clear screen對應code-*/


462
463 glEnable(GL_TEXTURE_2D);
464 glTexEnvx(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE);
465
......
 
 
594bool BootAnimation::movie()
......
/*-刪除clear screen對應code-*/
700 // clear screen
701 glShadeModel(GL_FLAT);
702 glDisable(GL_DITHER);
703 glDisable(GL_SCISSOR_TEST);
704 glDisable(GL_BLEND);
705 glClearColor(0,0,0,1);
706 glClear(GL_COLOR_BUFFER_BIT);
707
708 eglSwapBuffers(mDisplay, mSurface);
/*-刪除clear screen對應code-*/
709
......
 
 
 
1128bool BootAnimation::MTKmovie()
......
/*-刪除clear screen對應code-*/
1222 // clear screen
1223 glDisable(GL_DITHER);
1224 glDisable(GL_SCISSOR_TEST);
1225 glDisable(GL_BLEND);
1226 glClear(GL_COLOR_BUFFER_BIT);
1227
1228 eglSwapBuffers(mDisplay, mSurface);
/*-刪除clear screen對應code-*/
1229
 

著作權聲明:本文為博主原創文章,未經博主允許不得轉載。

kernel logo到開機動畫之間閃現黑屏(android 5.X)

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.