Android VideoView - time point definition in video

I use VideoView to display video. I use setOnPreparedListener and setOnCompletionListener to do things before and after the start and end of the video.

I was wondering how I can find some time in the video. For example, for example, I want to write a log to a file when a video has been playing for 10 seconds. How can I detect the 10s mark?

Thank you, Chris

+5
source share
1 answer

Step # 1: use postDelayed()or something to gain control every second or so.

№2: getCurrentPosition() , . , .

# 3: , , .

, Android , , .

+5

All Articles