HISPlayer supports multiple rendering modes to suit different use cases and platforms. The recommended mode for XR/VR applications is External Surface for optimal performance & latency and DRM L1 support. Other modes like RenderTexture, Material, and RawImage are also available.
This mode uses XR Video Layers, which are managed inside the HISPlayer SDK for high resolution video rendering performance and DRM L1 support. It is the preferred choice for immersive experiences on Android XR headsets (e.g., Meta Quest, Pico, Galaxy XR, etc).
- Create an empty GameObject.
Important: There is no need to add any additional components. The HISPlayer SDK will automatically add the XR Video Layer component internally.
- In your script (inheriting from
HISPlayerManager), set therenderModetoHISPlayerRenderMode.ExternalSurfacein theMultiStreamProperties.
- Set the XR Layer properties related to External Surface:
- Video Screen: Attach the Unity Game Object's Transform where video will be rendered.
- Order: Order of the rendered video relative to the whole Unity scene: 1 (Default) or higher will render the video over everything the camera renders. -1 or lower will render the video behind everything. Never put 0 which is the order of Unity's own Default Scene Layer. Set unique value across multiple streams to avoid multipe video rendering order conflict. Stereo layer takes two orders - this one and the next.
- Projection: Select the projection type. Quad is a flat/rectilinear screen placed by the Video Screen above. Equirect360 and Equirect180 wrap it around the viewer for 360/180° video.
- Stereo Mode: Select stereoscopic mode. None for Monoscopic video. Left Right or Top Bottom for stereoscopic video. A stereo layer occupies two composition orders - the one above and the next one up.
- Match Video Aspect: Match the render surface quad to the video's aspect ratio. For example a 21:9 film is not stretched to fill a 16:9 quad. The quad never grows past the Video Screen's scale. Quad only.
- Radius: Radius in metres of the equirect sphere. 0 is default for 360 video to make it infinite. Equirect 360/180 only.
Important: Do not set the
StreamProperties.externalSurfaceproperty. This property is set automatically by the SDK.
This mode renders video to a RenderTexture, which can then be displayed on any 3D object or UI element. It is suitable for both XR and non‑XR projects.
- Create a RenderTexture asset via Assets > Create > RenderTexture.
- Create a Material, assign the RenderTexture to its
_MainTex property, and ensure it uses theHISPlayer/HISPlayerDefaultShadershader for correct video rendering.
- Set the
renderModetoHISPlayerRenderMode.RenderTexturein theMultiStreamPropertiesand assign the RenderTexture to therenderTexturefield in yourHISPlayerManagerscript.
- Assign the created Material to the MeshRenderer (or the appropriate renderer component) of the GameObject that will display the video.
Tip: Pre‑configured assets are available in the package:
- RenderTexture:
Packages/HISPlayerSDK/HisPlayer/Resources/RenderTextures/HISPlayerRenderTexture.renderTexture- Material:
Packages/HISPlayerSDK/HisPlayer/Resources/Materials/HISPlayerDefaultMaterialRenderTexture.mat(already uses the correct shader)
For Linear Color Space projects, it is essential to use the HISPlayer/HISPlayerDefaultShader shader in your Material to correct color issues. The pre‑configured Material (HISPlayerDefaultMaterialRenderTexture.mat) already includes this shader.
This mode renders video directly onto a standard Unity Material, which can be applied to any 3D object with a MeshRenderer.
- Create a Material and ensure it uses the
HISPlayer/HISPlayerDefaultShadershader for correct video rendering.
- Set the
renderModetoHISPlayerRenderMode.Materialin theMultiStreamPropertiesand assign the Material to thematerialfield in yourHISPlayerManagerscript.
- Assign the created Material to the MeshRenderer (or the appropriate renderer component) of the GameObject that will display the video.
Tip: Pre‑configured assets are available in the package:
- Material:
Packages/HISPlayerSDK/HisPlayer/Resources/Materials/HISPlayerDefaultMaterial.mat(already uses the correct shader)
For Linear Color Space projects, it is essential to use the HISPlayer/HISPlayerDefaultShader shader in your Material to correct color issues. The pre‑configured Material (HISPlayerDefaultMaterial.mat) already includes this shader.
This mode renders video to a RawImage component on a Unity UI Canvas, ideal for 2D overlays or in‑game menus.
- Create a RawImage UI element (GameObject > UI > Raw Image). A Canvas will be created automatically if none exists.
- Set the
renderModetoHISPlayerRenderMode.RawImagein theMultiStreamPropertiesand assign the RawImage to therawImagefield in yourHISPlayerManagerscript.
No additional shader changes are required for Raw Image mode.








