Breadcrumbs

Set up video playback

Convert video to bink

  1. Open the Bink2ForUnreal.exe in ...\Pixotope\[Version number]\Pixotope Engine\Engine\Binaries\ThirdParty\Bink

    image-20231006-134905.png


  2. Select a video file and click "BINK VIDEO"

    image-20231006-134915.png


  3. Specify the encoding options

    image-20231006-134923.png


  4. Click "Bink” to start the encoding

    image-20231006-134933.png

Copy to content folder

  1. Create a Movies folder in [Linked project]\Content\

  2. Copy the video to into this folder

Create Bink Media Player

  1. Right click in the Content Browser

  2. Create a Miscellaneous > Bink Media Player asset

    image-20231006-134953.png


  3. Open the asset and choose the created file as your source

    Screenshot 2023-10-06 at 16.23.27.png


  4. For later Blueprint control make sure Start immediately and Looping are checked

    • you need to have "start immediately" checked and then pause it

      unchecking it will not make it work in a blueprint

      Screenshot 2023-10-09 at 09.19.44.png


You need one player per video stream.

Create Media Texture

  1. Right click the Bink Media Player asset in the Content Browser

  2. Click "Create Media Texture"

    image-20231006-135010.png


  3. Drag the created Media texture onto your object

  4. Double click the material to open the Material Editor

  5. Plug the RGB texture output into the Emissive Color to simulate an actively lit display

    image-20231006-135020.png


  6. Correct the scaling of your object to fit the video’s aspect ratio

Create a blueprint

  1. Create an Actor based Blueprint Class by right clicking in the Content Browser and selecting Blueprint Class and name it for example BP_bink

    Screenshot 2023-10-09 at 11.35.37.png


    Screenshot 2023-10-09 at 11.36.26.png


  2. Create a Bink Media Player > Object Reference variable

    1. Create a new variable by clicking on the + icon

      Screenshot 2023-10-09 at 11.45.43.png


    2. Select Bink Media Player > Object Reference as the variable type

      image-20231006-135041.png


    3. Click the Eye icon and then "Compile" to expose it to the Details panel

    4. Drag it into the level

  3. Link the Bink Media Player asset to it

    1. Select the blueprint in the level and go to the Details panel

    2. Select the Bink Media Player asset you had created before

      Screenshot 2023-10-09 at 12.42.44.png


Add blueprint events

  1. Go to the Event Graph of the blueprint you added

  2. Add Bink Media Player > Pause function on BeginPlay using the Bink Media Player Object Reference as a target

    Screenshot 2023-10-09 at 13.04.33.png


    Screenshot 2023-10-09 at 13.05.22.png


  3. Add a Play control

    1. Right click to search for Add Custom Event, add it and name it "Play"

      Screenshot 2023-10-09 at 12.49.18.png


    2. Add a Bink Media Player > Play function and add the Bink Media Player Object Reference as a target

      Screenshot 2023-10-09 at 13.06.51.png


      Screenshot 2023-10-09 at 13.07.11.png


You can also use Set Rate for Pause and Play

  • Rate = 0.0 → Pause

  • Rate = 1.0 → Play

Example blueprints for more advanced controls

Checkout the example blueprints for more advanced controls like

  • Play from a specific time

  • Change the video source URL

Click to expand...

Play from time

image-20231006-135131.png
image-20231006-135138.png

Change the video source URL

image-20231006-135155.png

This function can be used in combination with a Tab, Dropdown or Playlist widget inside the Control panel.

image-20231006-135215.png
image-20231006-135205.png

Control the video playback via a control panel

  1. Create a new control panel

  2. Select the BP_bink object in the Engine tab

  3. Drag the function to control onto the canvas and select a Trigger widget

    Screenshot 2023-10-09 at 13.41.00.png


    Screenshot 2023-10-09 at 13.42.01.png


  4. Repeat this step with other control functions you have created