ICatchIPancamRender interface

  1. package com.icatchtek.pancam.customer;
  2. public interface ICatchIPancamRender {
  3. ...
  4. }

This class is used to set the rendering mode, including normal rendering, panoramic rendering provided by the SDK. Or rendering without the SDK, the app takes frames from the SDK to complete its unique logic, such as AI recognition, special body tracking, image classification, etc. This interface will be inherited by ICatchIPancamPreview and ICatchIPancamVideoPlayback, which are also interfaces.

Public methods

enableRender

  1. boolean enableRender(ICatchISurfaceContext surfaceContext)
  2. throws com.icatchtek.reliant.customer.exception.IchInvalidSessionException,
  3. com.icatchtek.reliant.customer.exception.IchPermissionDeniedException,
  4. com.icatchtek.reliant.customer.exception.IchInvalidArgumentException

Enable The SDK rendering without GL rendering. The SDK wil ensure the aspect ratio of the video stream, and then display the picture to the SurfaceContext specified by the user.
Parameters:

  • surfaceContext - The surface context which will be used to draw stream frames.

Returns:
Return true if no error happened, otherwise return false.
Throws:

  • com.icatchtek.reliant.customer.exception.IchInvalidSessionException - invalid session exception.
  • com.icatchtek.reliant.customer.exception.IchPermissionDeniedException - stream running exception, this method should be called before stream started.
  • com.icatchtek.reliant.customer.exception.IchInvalidArgumentException = invalid argument exception.

enableGLRender

  1. ICatchIPancamGL enableGLRender()
  2. throws com.icatchtek.reliant.customer.exception.IchInvalidSessionException,
  3. com.icatchtek.reliant.customer.exception.IchPermissionDeniedException

Enable The SDK rendering with GL feature, this method will provide an interface which called ICatchIPancamGL. App should use this interface to set GL feature provided by iCatch SDK.
Returns:
The instance of ICatchIPancamGL’s implementation.
Throws:

  • com.icatchtek.reliant.customer.exception.IchInvalidSessionException - session invalid.
  • com.icatchtek.reliant.customer.exception.IchPermissionDeniedException - stream running exception, this method should be called before stream started.

enableGLRender

  1. ICatchIPancamGL enableGLRender(int panoramaType)
  2. throws com.icatchtek.reliant.customer.exception.IchInvalidSessionException,
  3. com.icatchtek.reliant.customer.exception.IchPermissionDeniedException

Enable The SDK rendering with GL feature, this method will provide an interface which called ICatchIPancamGL. App should use this interface to set GL feature provided by iCatch SDK.
Parameters:

  • panoramaType - the type of panorama, such as asteroid,

Returns:
The instance of ICatchIPancamGL’s implementation.
Throws:

  • com.icatchtek.reliant.customer.exception.IchInvalidSessionException - session invalid.
  • com.icatchtek.reliant.customer.exception.IchPermissionDeniedException - stream running exception, this method should be called before stream started.

disableRender

  1. ICatchIStreamProvider disableRender()
  2. throws com.icatchtek.reliant.customer.exception.IchInvalidSessionException,
  3. com.icatchtek.reliant.customer.exception.IchPermissionDeniedException

Disable SDK rendering, this means that the app needs to fetch frames, decode, render This method will return an interface named ICatchIStreamProvider for App developers to get format information, frame information, etc.
Parameters:

  • panoramaType - the type of panorama, such as asteroid,

Returns:
The instance of ICatchIStreamProvider’s implementation.
Throws:

  • com.icatchtek.reliant.customer.exception.IchInvalidSessionException - session invalid.
  • com.icatchtek.reliant.customer.exception.IchPermissionDeniedException - stream running exception, this method should be called before stream started.