类 VideoBlock

java.lang.Object
io.agentscope.core.message.ContentBlock
io.agentscope.core.message.VideoBlock
所有已实现的接口:
State

public final class VideoBlock extends ContentBlock
Represents video content in a message.

This content block supports video from two sources:

  • URL source - video files accessible via HTTP/HTTPS URLs or local file URLs
  • Base64 source - video encoded as Base64 strings with MIME type

Video blocks enable advanced multimodal AI interactions where agents need to process or analyze video content such as presentations, tutorials, surveillance footage, or other visual media that includes motion and temporal elements.

  • 构造器详细资料

    • VideoBlock

      public VideoBlock(Source source)
      Creates a new video block with source.
      参数:
      source - The video source (URL or Base64)
  • 方法详细资料

    • getSource

      public Source getSource()
      Gets the source of this video content.
      返回:
      The video source containing URL or Base64 data
    • getFps

      public Float getFps()
      Gets the frames per second (FPS) of the video.
      返回:
      The frames per second value
    • getMaxFrames

      public Integer getMaxFrames()
      Gets the maximum number of frames to capture from the video.
      返回:
      The maximum number of frames
    • getMinPixels

      public Integer getMinPixels()
      Gets the minimum pixel threshold for input video frames.
      返回:
      The minimum pixel threshold
    • getMaxPixels

      public Integer getMaxPixels()
      Gets the maximum pixel threshold for input video frames.
      返回:
      The maximum pixel threshold
    • getTotalPixels

      public Integer getTotalPixels()
      Gets the total pixels of all frames extracted from the video (single image pixels × total frames).
      返回:
      The total pixels
    • builder

      public static VideoBlock.Builder builder()
      Creates a new builder for constructing VideoBlock instances.
      返回:
      A new builder instance