Interface VideoManager

All Superinterfaces:
AutoCloseable
All Known Implementing Classes:
DummyVideoManager, VLCVideoManager

public interface VideoManager extends AutoCloseable
Responsible for loading and preparing video players.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static interface 
     
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    closePlayer(net.minecraft.util.Identifier id)
    Close a video player and remove it from this manager's pool.
    getOrCreate(net.minecraft.util.Identifier id)
    Get a video player by its identifier, or create it if it does not exist.
    getPlayer(net.minecraft.util.Identifier id)
    Get a video player by its identifier.
    net.fabricmc.fabric.api.resource.IdentifiableResourceReloadListener
    Get a resource reload listener responsible for loading video files.
    Get a video handle factory that will create handles compatible with this video manager.
    Get the extensions that this implementation supports.

    Methods inherited from interface java.lang.AutoCloseable

    close
  • Method Details

    • getPlayer

      VideoPlayer getPlayer(net.minecraft.util.Identifier id)
      Get a video player by its identifier.
      Parameters:
      id - Identifier to use.
      Returns:
      Corresponding video player, or null if no video player by this ID exists.
    • getOrCreate

      VideoPlayer getOrCreate(net.minecraft.util.Identifier id)
      Get a video player by its identifier, or create it if it does not exist.
      Parameters:
      id - Identifier to use.
      Returns:
      The video player.
    • closePlayer

      boolean closePlayer(net.minecraft.util.Identifier id)
      Close a video player and remove it from this manager's pool.
      Parameters:
      id - Video player ID.
      Returns:
      If this video player was found.
    • getReloadListener

      net.fabricmc.fabric.api.resource.IdentifiableResourceReloadListener getReloadListener()
      Get a resource reload listener responsible for loading video files.
      Returns:
      Reload listener.
    • supportedExtensions

      Collection<String> supportedExtensions()
      Get the extensions that this implementation supports.
      Returns:
      A collection of extensions, excluding the period. ('mp4', NOT '.mp4')
    • getVideoHandleFactory

      VideoHandleFactory getVideoHandleFactory()
      Get a video handle factory that will create handles compatible with this video manager.
      Returns:
      The video handle factory.