Video Player 界面,展示 Sintel 预告片的示例画面。
Video Player 界面,展示 Sintel 预告片的示例画面。
© copyright Blender Foundation | durian.blender.org · CC BY 3.0
← 所有原生指南

Xodera Plugins · Bubble Native

Xodera Video Player Native

在应用内显示课程、产品演示和受支持的直播流,提供播放控制、全屏以及可用的语言轨道。

Public beta guides · Haptics instructions are in its Bubble listing

Public beta offer: free Bubble install · 7-day card trial, then US$1.50/month per plugin/project.

文档审阅日期:2026年11月6日

实用示例

培训应用中的章节链接

学习者需要重新播放演示的某一步,而无需跳转到外部播放器。

`source_url = Current Lesson’s video URL`;`poster_url = Current Lesson’s cover`;每个章节存储应用拥有的开始时间。

章节点击 → 如果更换源,等待 `source_loaded` → Seek 到 `position_seconds` → Play。使用 Set playback rate 进行详细演示,按需使用 Enter fullscreen。

读取 `position_seconds`、`duration_seconds` 和 `is_fullscreen`;你的工作流仅为当前源存储课程进度。

在 `player_error` 时,显示 `error_code`,保留进度并提供 Reload video。完成事件并不证明已通过课程或安全评估。

使用直接视频文件或受支持的流。此播放器不导出视频。

市场列表中的视频演示

仅凭产品图片无法说明商品的使用方式,但站外视频会打断购买流程。

`source_url = Selected Listing’s demonstration URL`;`poster_url = its thumbnail`;`muted = yes` 用于有意静音的首次预览。

打开所选列表 → 绑定其视频 → 在用户操作后 Play。提供 Set muted 以获取声音,提供 Enter fullscreen 以进行更近的检查。将 `is_active` 绑定到详情视图是否可见。

使用 `has_source`、`is_buffering` 和 `status` 区分视频缺失、加载中和就绪状态。

在更换源时,停止使用旧的进度和轨道选择。当所选文件不受支持时,显示缩略图回退。

使用直接视频文件或受支持的流。此播放器不导出视频。

在受支持的流中选择可用的语言轨道

多语言应用需要提供特定来源实际包含的轨道。

`source_url = Selected Programme’s accepted stream URL`; 源本身必须提供兼容的音频/字幕轨道。

在 `tracks_changed` 上,读取当前的 `audio_tracks_json` 和 `subtitle_tracks_json`;在应用中构建选项,并使用当前索引调用 Select audio track 或 Select subtitle track。

使用 `selected_audio_index`、`selected_subtitle_index` 和 `source_generation` 将选择关联到此来源。

每次来源更改后重新构建选项。如果轨道缺失或不受支持,保留默认轨道并诚实地显示其可用性。

使用直接视频文件或受支持的流。此播放器不导出视频。

当前可用功能

Public beta. Use the documented controls and actions; test supported formats, permissions and device behavior in your own native app. Browser preview does not validate native device output.

构建工作流

使用下面可用的测试版操作,并在目标设备上测试结果。

这些示例使用了诸如 Lesson、Message 和 Order 的应用记录。请将它们替换为您自己的数据类型和元素名称。示例媒体地址必须替换为您自己的文件。

  1. 设置 source_url = Selected Lesson's video_url 和 poster_url = Selected Lesson's poster_url。播放 MP4 时使用 auto 或 progressive;播放 HLS 流时使用 hls。

  2. 在 playback_ready 之后,使用 Seek 在已保存的 position_seconds 处恢复。用户启动 Play。将 is_active 设置为课程视图是否打开。

  3. 添加 Play、Pause、Seek、Set playback rate 和 Enter fullscreen 控件。显示 position_seconds 和 duration_seconds。

  4. 在 tracks_changed 之后,显示此视频可用的 audio_tracks_json 和 subtitle_tracks_json 选项。将所选索引传递给 Select audio track 或 Select subtitle track。在 ended 事件发生时,保存进度。

工作流图 — 不是应用截图

一次性配置

在 BestPlugins → Dashboard → Plugins 中创建或选择您的 Bubble 应用项目。选择 Xodera Video Player Native,复制其密钥,然后打开 Bubble → Plugins → Xodera Video Player Native 并粘贴到 licensing_api_key。保存一次;随后使用以下操作。每个项目中的每个插件都有其自己的密钥。

使用直接的视频或流地址。YouTube 或 Vimeo 网页地址并非直接视频文件。播放不需要摄像头或麦克风访问。

一次性配置
  1. 在 BestPlugins → Dashboard → Plugins 中创建或选择您的 Bubble 应用项目。
  2. 选择此插件并复制其项目密钥。
  3. Open Bubble → Plugins → this plugin. Paste its project key into licensing_api_key and save.
  4. 添加元素,选择您的应用数据并构建以下工作流。
  5. In the dashboard, review and confirm the 7-day card trial for this plugin. It then costs US$1.50/month per app project, including development and production. Cancel before the trial ends to avoid the first charge.
安装和订阅

For Audio Player, Video Player, Photo Editor, Audio Recorder, Files Kit and Haptics: free Bubble installation, a 7-day trial with a card, then US$1.50 per month per plugin and app project. Development and production are included, with no operation cap. File-size and feature limits still apply. Review billing and cancellation before confirming. Other plugins remain unavailable for purchase.

将结果保存到您的应用中

示例 WatchProgress:owner = Current User、lesson = Selected Lesson、seconds = Video Player's position_seconds、duration = Video Player's duration_seconds。仅为当前选定的视频保存。轨道索引属于该视频,不应存为永久语言选择。

失败、取消与恢复

在 player_error 上,显示 error_code 并提供 Reload video。它会重新加载但不启动播放。选择其他来源会清除旧的轨道选择。离开视图时视频暂停;用户按下 Play 继续。

功能与限制

速度:0.5、1、1.5 和 2。音量:0–1。格式:auto、progressive、HLS 以及仅 Android 的 DASH。可用轨道取决于文件。使用 -1 关闭轨道;-2 表示未知,无法选择。无编辑、视频导出、DRM、画中画或永久离线缓存。

设置、操作和结果

在 Bubble 中使用这些名称。计划中的功能会单独标记。

可用的测试版设置

元素设置

source_url · textposter_url · textcontent_type · textrate · numbervolume · numbermuted · yes/noloop · yes/nois_active · yes/nodisabled · yes/nonative_controls · yes/noui_text_json · textlanguage · text

状态

is_playing · yes/nois_buffering · yes/nopending_play · yes/nois_live · yes/nomuted · yes/noloop · yes/nohas_source · yes/nois_fullscreen · yes/noposition_seconds · numberduration_seconds · numbervolume · numberrate · numbersource_generation · numberselected_audio_index · numberselected_subtitle_index · numberstatus · textaudio_tracks_json · textsubtitle_tracks_json · texterror_code · texterror_message · text

事件

source_changedsource_loadedplayback_readyplaying_changedtime_changedendedtracks_changedfullscreen_changedplayer_error

操作及其输入

PlayPauseStop and rewindReload videoSeekSet volumeSet mutedSet playback rateEnter fullscreenSelect audio trackSelect subtitle track
元素设置 · 12
source_urltext · 默认: ""
示例值https://bestplugins.online/native-samples/lesson.mp4
示例 Bubble 表达式Selected Lesson's video_url
所选音频、视频或图像文件的地址。使用此插件支持的文件类型。
poster_urltext · 默认: ""
示例值https://bestplugins.online/native-samples/poster.jpg
示例 Bubble 表达式Selected Lesson's poster_url
使用当前业务记录的值;根据以下限制进行验证。
content_typetext · 默认: "auto"
示例值auto
示例 Bubble 表达式Selected Lesson's video_content_type
使用当前业务记录的值;根据以下限制进行验证。
ratenumber · 默认: 1
示例值1.5
示例 Bubble 表达式Speed Dropdown's value
使用当前业务记录的值;根据以下限制进行验证。
volumenumber · 默认: 1
示例值0.8
示例 Bubble 表达式Volume Slider's value
使用当前业务记录的值;根据以下限制进行验证。
mutedyes/no · 默认: false
示例值no
示例 Bubble 表达式Mute Checkbox is checked
使用当前业务记录的值;根据以下限制进行验证。
loopyes/no · 默认: false
示例值no
示例 Bubble 表达式Selected Lesson's repeat_enabled
使用当前业务记录的值;根据以下限制进行验证。
is_activeyes/no · 默认: true
示例值yes
示例 Bubble 表达式GuideHost's view_is_active (your yes/no custom state)
在此视图打开时设为是。离开时设为否,以便停止播放或当前工作。
disabledyes/no · 默认: false
示例值no
示例 Bubble 表达式GuideHost's is_busy (your yes/no custom state)
当应用忙碌或此操作不可用时禁用该元素。
native_controlsyes/no · 默认: false
示例值no
示例 Bubble 表达式App Settings' use_native_video_controls
显示或隐藏设备的标准视频控制。
ui_text_jsontext · 默认: "{}"
示例值{}
示例 Bubble 表达式App Settings' player_labels_json (supported keys only)
可选的 JSON,包含支持的按钮标签。留空则使用内置文本。
languagetext · 默认: "auto"
示例值uk
示例 Bubble 表达式Current User's preferred_language
将 language=auto 设置为跟随支持的设备或浏览器语言。输入支持的语言代码以明确选择。
操作及其输入 · 11
Play

无操作参数

Pause

无操作参数

Stop and rewind

无操作参数

Reload video

无操作参数

Seek
position_secondsnumber · 默认: —
示例值45
示例 Bubble 表达式Selected Chapter's start_seconds
使用当前业务记录的值;根据以下限制进行验证。
Set volume
volumenumber · 默认: —
示例值0.8
示例 Bubble 表达式Volume Slider's value
使用当前业务记录的值;根据以下限制进行验证。
Set muted
mutedyes/no · 默认: —
示例值no
示例 Bubble 表达式Mute Checkbox is checked
使用当前业务记录的值;根据以下限制进行验证。
Set playback rate
ratenumber · 默认: —
示例值1.5
示例 Bubble 表达式Speed Dropdown's value
使用当前业务记录的值;根据以下限制进行验证。
Enter fullscreen

无操作参数

Select audio track
indexnumber · 默认: —
示例值0
示例 Bubble 表达式Selected row's current_source_index
使用当前业务记录的值;根据以下限制进行验证。
Select subtitle track
indexnumber · 默认: —
示例值0
示例 Bubble 表达式Selected row's current_source_index
使用当前业务记录的值;根据以下限制进行验证。
状态和事件

状态

is_playing · yes/no

所选项目的当前值。请在相关事件后读取。

is_buffering · yes/no

所选项目的当前值。请在相关事件后读取。

pending_play · yes/no

所选项目的当前值。请在相关事件后读取。

is_live · yes/no

所选项目的当前值。请在相关事件后读取。

muted · yes/no

所选项目的当前值。请在相关事件后读取。

loop · yes/no

所选项目的当前值。请在相关事件后读取。

has_source · yes/no

所选项目的当前值。请在相关事件后读取。

is_fullscreen · yes/no

所选项目的当前值。请在相关事件后读取。

position_seconds · number

所选项目的当前值。请在相关事件后读取。

duration_seconds · number

所选项目的当前值。请在相关事件后读取。

volume · number

所选项目的当前值。请在相关事件后读取。

rate · number

所选项目的当前值。请在相关事件后读取。

source_generation · number

所选项目的当前值。请在相关事件后读取。

selected_audio_index · number

所选项目的当前值。请在相关事件后读取。

selected_subtitle_index · number

所选项目的当前值。请在相关事件后读取。

status · text

此操作的当前结果。在保存成功之前使用匹配的完成事件。idle,loading,readyToPlay,error

audio_tracks_json · text

所选项目的当前值。请在相关事件后读取。

subtitle_tracks_json · text

所选项目的当前值。请在相关事件后读取。

error_code · text

上一次操作的错误信息。显示有帮助的提示并提供相应的重试。

error_message · text

上一次操作的错误信息。显示有帮助的提示并提供相应的重试。

事件

source_changed

当此事件发生时,从同一元素读取相关状态。

source_loaded

当此事件发生时,从同一元素读取相关状态。

playback_ready

当此事件发生时,从同一元素读取相关状态。

playing_changed

当此事件发生时,从同一元素读取相关状态。

time_changed

当此事件发生时,从同一元素读取相关状态。

ended

当此事件发生时,从同一元素读取相关状态。

tracks_changed

当此事件发生时,从同一元素读取相关状态。

fullscreen_changed

当此事件发生时,从同一元素读取相关状态。

player_error

当此事件发生时,从同一元素读取相关状态。

开发者常问问题

我可以导出所选片段吗?

不。Seek 和全屏会改变播放,而不是视频字节。

订阅是如何运作的?

For Audio Player, Video Player, Photo Editor, Audio Recorder, Files Kit and Haptics: free Bubble installation, a 7-day trial with a card, then US$1.50 per month per plugin and app project. Development and production are included, with no operation cap. File-size and feature limits still apply. Review billing and cancellation before confirming. Other plugins remain unavailable for purchase.

相关指南

如需帮助,请告知我们您使用的插件和设备、尝试的操作以及发生的情况。请使用不含个人数据的示例。切勿分享您的密钥或私有文件。