Questions tagged [surfaceflinger]

SurfaceFlinger is Android's window compositor. Use this tag for questions specific to SurfaceFlinger component of Android. In addtion, add android tag as well.

SurfaceFlinger is Android's window compositor. Use this tag for questions specific to SurfaceFlinger component of Android. In addtion, add tag too.

100 questions
2
votes
0 answers

Main android screen doesn't go back up after resuming from suspend

I am debugging a bug where the android main screen won't show up after resuming from suspend (after hitting end-key). Sometimes it can go back up, but when it doesn't, it will keep the screen dim and black, but the shell is still working. I can…
2
votes
0 answers

Optimize Android 2.3 on hardware without graphic acceleration

I have some arm-based device with Android 2.3. Unfortunately there is no graphic acceleration, so compositing of final image in surface flinger is done using software opengl - and this is really slow. The main problem is with glDrawArrays method…
thearti
  • 371
  • 2
  • 6
1
vote
0 answers

Need some detail of how SurfaceFlinger and BufferQueue works on Android platform

I'm investigating the issue with application hang. The issue is only reproducible on Samsung S22 with adaptive fps feature ON. My app uses opengl to render its content. Also we use VideoView widget from Android SDK to playback some short movies. The…
1
vote
0 answers

How to wirte file in surfaceflinger?

I want to save some data to file. I add code into SurfaceFlinger. And change uid to root. And add sdcard_rw group. But it can not be working. This is my code: ALOGI("open file before"); int fd = open("/mnt/sdcard/test.bmp", O_RDWR| O_CREAT,…
Getname
  • 78
  • 8
1
vote
1 answer

Android 9: get "Black image" when take screenshot using SurfaceControl with specified minLayer & maxLayer

I'm developing a system app on Android Pie (Android 9). I need to capture screen but not whole screen, i just need to capture from layer 1 (for Wallpaper) to layer 2 (for Application). I used SurfaceControl like this: Rect crop = new Rect(0, 0,…
TuanPM
  • 685
  • 8
  • 29
1
vote
1 answer

Why do I see too many surfaceflinger screenshot entries in logcat?

On my device, I see the following entries in the logcat: 06-01 13:08:12.062 2135 2135 I SurfaceFlinger: screenshot (StatusBar#0) 06-01 13:08:12.167 2135 2135 I SurfaceFlinger: screenshot (Splash Screen com.android.settings#0) 06-01 13:08:12.271 …
rpattabi
  • 9,984
  • 5
  • 45
  • 53
1
vote
0 answers

How to specify the layerStack for a VirtualDisplay created by DisplayManager?

According to android's official document: virtual displays Virtual displays may share the same set of layers as the main display (the layer stack) or have their own set. It is known that DisplayManager.createVirtualDisplay() can create a virtual…
1
vote
1 answer

ScreenshotClient update() call results in memory leak

I am working on a Jetson TK1 board. I have modified the code for screencap application to read the contents of the screen in a while loop and save the data as images. For this, I use the update() method from the ScreenshotClient class. After running…
Nithyesh
  • 105
  • 8
1
vote
1 answer

Why Overlay planes may be less efficient than GL Composition?

I have been reading this URL to understand surface flinger. https://source.android.com/devices/graphics/arch-sf-hwc Wherein, the below block I am unable to understand. It would be great if someone explains with an example. Overlay planes may be…
DrunkenMaster
  • 1,218
  • 3
  • 14
  • 28
1
vote
1 answer

What Does "FrameTimeNanos" mean in "Choreographer.FrameCallback"? HW_VSYNC time or APP_VSYNC time?

I've read the source code of DispSync and so on, but it's too complicate. What I've learnt is that "FrameCallback" is triggered by APP_VSYNC event, which may have time offset from HW_VSYNC. So, how could I know the precise time of HW_VSYNC? If the…
pippo
  • 53
  • 5
1
vote
1 answer

Android UI behaves differently with different display hardware

My android device behaves in a strange manner when I connect a 1366 X 768 lvds display. The UI is different from what I was getting with HDMI connected. I'm getting a different home screen with some other wallpaper and more than that the navigation…
1
vote
0 answers

Android init.rc's statements for changing surfaceflinger's gid

In android filesystem, a init.rc script has statements to change or append user and groups for surfaceflinger like below. service surfaceflinger /system/bin/surfaceflinger class main user system group graphics…
Kool Shin
  • 11
  • 2
1
vote
0 answers

Draw the contents of fb1 to the screen with SDL

I'm working on an Android app compatibility project which involves having two compositors draw to 2 different framebuffers, the main compositor (Lipstick, a wayland compositor) draws to fb0. Surfaceflinger after an fb swap with /dev/graphics/fb0…
nh1402
  • 75
  • 1
  • 9
1
vote
1 answer

Frame Listener for Android Virtual Display (NDK internal build)

I'm building an internal shared library for Android platform. I have the signing keystore from the device manufacturer. My library is making use of ScreenRecord.cpp internal file from Android source. Recording works fine with the MediaCodec…
Usman.3D
  • 1,791
  • 3
  • 16
  • 27
1
vote
1 answer

Frame Drop issue with video playback

I am experiencing frame drop issue with video playback. We just moved from ICS to KK4.4. Video is very small 320x240 resolution. There is no audio to make things simple. Systrace is at following location:…