top of page
Video Player

Video Player

Category:

AddIn:

Scope:

Code Snippets:

Supports Material List:

Status Screen Widgets:

License:

Visual Stimuli

Base Elements

Local

Triggered

yes

no

Standard EventIDE license

In this article:


Introduction


The Video Player element enables precise presentation of video-based visual stimuli within EventIDE experiments. It supports flexible playback control, detailed runtime monitoring, and advanced visual effects, making it suitable for perceptual, cognitive, and affective research paradigms that rely on dynamic audiovisual content.


The element plays video clips stored in the Material Library and can handle multiple clips organized into a switchable stimulus set, ensuring accurate timing and reproducibility across trials.


Key Features


  • Flexible playback modes, including manual, single-play, and looped playback.

  • Precise runtime control over playback position, frame index, time, and volume.

  • Accurate timing audit, including start time, end time, actual frame rate, and playback duration.

  • Support for multiple video clips via the Material Library with runtime switching.

  • Advanced visual effects, including opacity, color masking, blurring, pixelation, scrambling, and jitter.

  • Direct rendering mode for high-performance stimulus presentation beyond standard event composition.

  • Spatial control, including position, size, rotation, pivot point, and Z-ordering.

  • Alpha masking support, enabling transparency effects and stimulus cutouts.

  • Runtime-trigger monitoring, allowing detection of playback completion for experimental control logic.


Properties

Name

Description

Constraints

Type

On runtime change

Settings





Playback Mode

Defines video playback mode: manual, single-play on event onset, or looped playback

Normal

stPlayMethod

Direct Rendering

Enables fast direct rendering bypassing normal event composition

Design-time

Boolean

Start Position

Start position of playback (0–100% of clip duration)

Normal

Double

Current Position

Current playback position (0–100%); can be read or adjusted at runtime

Normal

Double

Media Timeout

Maximum timeout for loading or seeking media (ms)

Design-time

clTime

Clip Info





Frame Rate

Original frame rate of the current clip (fps)

Status

Double

Duration

Duration of the current clip (seconds)

Status

Double

Number of Frames

Total number of frames in the clip

Status

Int32

Frame Size

Original resolution of the video clip

Status

clSize

Playback Control





Is Playing

Indicates or controls playback state (play/pause)

Normal

Boolean

Volume

Audio volume (0–100%)

Normal

Double

Balance

Stereo audio balance (left ↔ right)

Normal

Double

Runtime Status





Start Time

Event time when playback started

Status

clTime

Current Time

Current playback position in milliseconds

Normal

clTime

Current Frame

Current playback frame index

Normal

Double

End Time

Event time when playback ended

Status

clTime

Is Triggered

Indicates whether playback has completed since event activation

Normal

Boolean

Actual Framerate

Actual runtime playback frame rate

Status

Double

Material List





Selected Index

Index of the selected video clip

Normal

Int32

Selected Item

Name of the selected video clip

Normal

String

Item Count

Total number of video clips in the list

Status

Int32

Visual Appearance





Alpha Masking

Uses video luminance as opacity mask

Design-time

Int32

AntiAliasing

Enables antialiasing for smoother rendering

Normal

Boolean

Position

Screen position of the video viewport

Normal

clPoint

Size

Size of the video viewport

Normal

clSize

Z Order

Z-order of the element within the event

Status

Int32

Pivot Point

Defines pivot alignment for rotation and scaling

Normal

stAlignment

Visible

Controls element visibility

Normal

Boolean

Rotation

Rotation angle in degrees

Normal

Double

Effects





Transparent Color

Color set as transparent

Normal

stColor

Transparent Tolerance

Tolerance for transparency matching

Normal

Int32

Color Mask

Multiplies pixel colors with a mask color

Normal

stColor

Opacity

Opacity of rendered content

Normal

Int32

Contrast

Contrast adjustment

Normal

Int32

Brightness

Brightness adjustment

Normal

Int32

Saturation

Color saturation adjustment

Normal

Double

Pixelation

Pixelation intensity

Normal

Int32

Blurring

Gaussian blur radius

Normal

Int32

Scrambling

Proportion of scrambled voxels

Normal

Double

Scrambling Grid Size

Grid size for scrambling effect

Normal

clSize

Positional Jitter





Reset Jitter Now

Resets positional jitter

Runtime action

Boolean

Current Jitter

Current jitter offset

Status

clPoint

Jitter Range

Range of random positional jitter

Normal

clSize

Test Jitter

Tests current jitter configuration

Design-time

Boolean

Control





Is Enabled

Omits the element when false

Design-time

Boolean

Title

Title of the element

Design-time

String


Practical Use


The Video Player element is typically used as a primary visual stimulus in experiments involving motion, audiovisual perception, or naturalistic stimuli.


Technique 1: Trial-based video stimulus

This technique demonstrates how to present video stimuli, switch between multiple clips at runtime, and detect playback completion using proxy variables.


  1. Add the Video Player element

    Insert a Video Player element into the desired parent event that represents the stimulus screen.

  2. Load video stimuli into the Material Library

  3. Assign video clips to Video Player element

    Drag and drop one or more video clips from the Material Library directly onto the Video Player element in the Element Panel.

    The clips are added to the element’s internal Material List and can be accessed by Selected Index Property.

  4. Configure playback mode

    Set the Playback Mode property according to the experimental design (e.g. Single playback on event onset for automatic presentation, or Manual playback for full runtime control).

  5. Select video clips at runtime

    Create a proxy variable for the Selected Index property.

    This allows the experiment logic or script to dynamically select which video clip from the material list is played during runtime (e.g. based on trial conditions or randomization).

  6. Monitor playback completion

    Create a proxy variable for the Is Triggered property.

    This variable becomes true each time video playback reaches the end, allowing precise detection of stimulus completion for timing, flow control, or response evaluation.

  7. Integrate with experiment flow

    Use the Is Triggered proxy variable to:

    - Advance to the next event using flow route condition

    - Enable participant responses

    - Trigger logging or adaptive logics.


Technique 2: Manual Playback and Dynamic Adjustments


  1. Configure Playback Mode to Manual playback.

  2. Add proxy variables to Current Position (or Current Time) and Is Playing properties.

  3. Use proxy variable in code snippets to control playback.

//Example: restart video playback at the beginning of a  trial
CurrentPosition = 0;
IsPlaying = true;
  1. For dynamic adjustments of the video you can use proxy variables linked to visual properties of the Video Player element, for example you can apply visual effects (e.g., blur, contrast, scrambling) dynamically to manipulate perceptual load.


Notes

  • For timing-critical experiments, consider enabling Direct Rendering to reduce rendering overhead.

  • The Actual Framerate property can be used to verify stimulus presentation fidelity.

  • Audio playback can be precisely controlled or muted using Volume and Balance.

  • Visual effects and jitter can be combined to create controlled stimulus degradation or uncertainty.

  • The Video Player integrates seamlessly with eye tracking, EEG, and behavioral response elements for multimodal experiment.

  • For short video clips and experiments that require precise frame-level control, deterministic timing, or variable playback speed, the use of the Video Sequencer DX element is recommended instead of the standard Video Player element.

  • Video Sequencer DX provides greater control over individual frames and playback timing, making it more suitable for paradigms that demand high temporal accuracy or non-linear video presentation.

bottom of page