user447863
user447863

Reputation: 31

Paint on a VideoView

I am trying to code an app where you can paint (Finger paint) free hand on a running video in a VideoView. I have the two things running sepaerately but not together. I can draw my paint on a blanc screen and i can play my video on my videoView, which is implementet in an xml layout.

Is there a way to overlay the xml videoview View with an other View which can be drawable?

Upvotes: 3

Views: 1534

Answers (2)

Fernando Prieto Moyano
Fernando Prieto Moyano

Reputation: 925

I think your best option is to draw on SurfaceView, instead of using VideoView. SurfaceView provides lots of functions that VideoView doesn't, like correct the aspect ratio dependps on the screen size or whatever.

See the next thread, where some people talk about draw on SurfaceView:

how to draw image on surfaceView

Cheers!

Upvotes: 1

Cheryl Simon
Cheryl Simon

Reputation: 46844

The FrameLayout is designed for overlaying multiple views on top of each other. Provided your paint view is mostly transparent, you should be able to overlay it over the video view in a FrameLayout.

Upvotes: 2

Related Questions