Пример #1
0
  private int setPreviewRect() {
    Rect outRect =
        new Rect(
            VideoConst.PREVIEW_RECT_X,
            VideoConst.PREVIEW_RECT_Y,
            VideoConst.PREVIEW_RECT_X + VideoConst.PREVIEW_RECT_W,
            VideoConst.PREVIEW_RECT_Y + VideoConst.PREVIEW_RECT_H);

    TVManager tvManager = TVManager.getInstance(null);
    InputService inputManager = (InputService) tvManager.getService(InputService.InputServiceName);
    if (null != inputManager) {
      return inputManager.setScreenOutputRect(InputService.INPUT_OUTPUT_MAIN, outRect);
    }
    return -1;
  }
 protected TVManager getTVMngr() {
   if (dummyMode) {
     return null;
   } else {
     return TVManager.getInstance(context);
   }
 }