سؤال

In the android displaying processes, SurfaceFlinger does an important role in that situation.

By the way, are there any methods to notice the SurfaceFlinger starting or stopping at the application level?

Or any other displaying processes to observe?

I want to know about the time difference between touching and displaying.

هل كانت مفيدة؟

المحلول

The SurfaceFlinger process does not start or stop while applications are running. If it does, the system restarts.

It sounds like you're interested in knowing the latency between when you touch the screen, and when the results of that touch are visible. You can use systrace to observe the various events, though this requires a fair understanding of the system. (Start with this doc.)

In general, an app can expect 2 to 2.5 frames of latency between cause and effect. On the N5, with the DispSync mechanism, this can be reduced to 1.5 - 2 frames.

نصائح أخرى

There's no public API for 3rd party apps to access the surface flinger. If you are working at the platform level (your own device or custom ROM) then you'd have to add your own timing mechanism between the input subsystem and the surface flinger.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top