success_anil
success_anil

Reputation: 3658

Audio only while streaming a mp4 file to Android Device

I 've set Wowza streaming server to stream mp4 videos to Android phones. Android phone can play the RTSP stream successfully but here It only plays audio of the file not the video.

Upvotes: 0

Views: 1616

Answers (1)

Dariusz Bacinski
Dariusz Bacinski

Reputation: 8700

Did you set surface (VideoView or SurfaceView) on which you would like to display video? You have to run setDisplay before running playback.

Problems with video can also be caused by starting playback too early. You should start player after surface is created. If you want to start playback at start of the Activity, you should do it on surfaceCreated event. You can listen to this event by implementing SurfaceHolder.Callback

Can you provide some source codes?

You can also try to follow Android ApiDemos. Video streaming player example can be found at:

...android-sdk-windows\platforms\android-x\samples\ApiDemos\src\com\example\android\apis\media\MediaPlayerDemo_Video.java

Upvotes: 1

Related Questions