5

I have a problem with my SurfaceView, i need it for display video, i put transparent background to don't see a black screen in background when video is on load, and don't see black lines when scrolling while video is playing. My application display videos, like instagram (same style).

The problem is, the surfaceview/video is displayed over the anctionbar, and i don't want this. I know the problem is "setZOrderOnTop" but if i remove it, i'll get back the black background and scrolling problem. So, any idea ?

That's my code:

       //Video
       Video.setZOrderOnTop(true);
       final SurfaceHolder surfaceHolder = Video.getHolder();
       surfaceHolder.setFixedSize(taillePreview, taillePreview);
       surfaceHolder.setFormat(PixelFormat.TRANSPARENT);
       surfaceHolder.addCallback(MainActivity.this);

Thank's for helping.

Keveun
  • 153
  • 1
  • 7
  • I'd also like to know the answer to this (although in my case the problem is the NavigationDrawer, not the ActionBar), but after a week of Googling I haven't found any answers :-( If I find anything, I'll post an answer, but it's not looking good.... – David John Welsh Jul 31 '15 at 02:16
  • Did you find the answer ? I have the same issue... – AndroidCoolestRulest Jan 26 '16 at 12:57

0 Answers0