Search code examples
androidmedia-playerlogcatmessage

How to disable Android MediaPlayer debug messages


When using MediaPlayer I get the following lines of debug messages in LogCat constantly repeating:

02-13 14:30:52.090: V/MediaPlayer(21345): getVideoWidth
02-13 14:30:52.090: V/MediaPlayer-JNI(21345): getVideoWidth: 480
02-13 14:30:52.090: V/MediaPlayer(21345): getVideoHeight
02-13 14:30:52.090: V/MediaPlayer-JNI(21345): getVideoHeight: 360
02-13 14:30:52.100: V/MediaPlayer-JNI(21345): isPlaying: 0

My buffer soon fills up and I miss my other important messages. Is there anyway to disable this? Doing an exclusive filter in LogCat doesn't work because the buffer is still filled up in the background.


Solution

  • You can remove it by adding ^(?!MediaPlayer) to logcat filter Log Tag (regex) field: https://www.evernote.com/l/ABjh04WocVlGBp_wUBuQyefZIc_9aa8WP8QB/image.png