组件置于video上层方法.txt 684 B

1234567891011121314
  1. cocoscreator 组件置于video上面方法:
  2. Android端修改:
  3. 1. AppActivity-->onCreateView方法
  4. Cocos2dxGLSurfaceView glSurfaceView = new Cocos2dxGLSurfaceView(this);
  5. glSurfaceView.setZOrderMediaOverlay(true);
  6. glSurfaceView.getHolder().setFormat(PixelFormat.TRANSLUCENT);
  7. glSurfaceView.setEGLConfigChooser(8, 8, 8, 8, 16, 8);
  8. SDKWrapper.getInstance().setGLSurfaceView(glSurfaceView, this);
  9. 2. 依赖项目 libcocos2dx-->Cocos2dxVideoHelper-->_createVideoView方法
  10. 注释 videoView.setZOrderOnTop(true);
  11. 3. 触摸video上组件,需要注释video的touch事件。libcocos2dx-->Cocos2dxVideoView->onTouchEvent
  12. 直接return false