0

什么是大量广告?以及如何使用 Vast 广告react-jw-player以及调试的各种工具是什么?

4

1 回答 1

1

VAST 代表视频广告服务模板。简单地说,它是由 IAB 开发的 XML 脚本。作为最流行的广告标准,VAST 在广告服务器和视频播放器之间创建了一个通信链接。VAST 是由互动广告局定义和发布的规范,它为广告服务器和视频播放器之间的通信要求设定了标准,以便展示视频广告。

现在在 react-jw-player 中使用它是相当棘手的。我们可以使用 customProps 来使用广告对象。

import "./styles.css";
import ReactJWPlayer from "react-jw-player";

export default function App() {
  let newScheduleArray = [
    {
      tag: [
        "https://pubads.g.doubleclick.net/gampad/ads?sz=640x480&iu=/124319096/external/single_ad_samples&ciu_szs=300x250&impl=s&gdfp_req=1&env=vp&output=vast&unviewed_position_start=1&cust_params=deployment%3Ddevsite%26sample_ct%3Dskippablelinear&correlator=[timestamp]"
      ],
      type: "linear",
      offset: 25
    },
    {
      tag: [
        "https://pubads.g.doubleclick.net/gampad/ads?sz=640x480&iu=/124319096/external/single_ad_samples&ciu_szs=300x250&impl=s&gdfp_req=1&env=vp&output=vast&unviewed_position_start=1&cust_params=deployment%3Ddevsite%26sample_ct%3Dskippablelinear&correlator=[timestamp]"
      ],
      type: "linear",
      offset: 125
    },
    {
      tag: [
        "https://pubads.g.doubleclick.net/gampad/ads?sz=640x480&iu=/124319096/external/single_ad_samples&ciu_szs=300x250&impl=s&gdfp_req=1&env=vp&output=vast&unviewed_position_start=1&cust_params=deployment%3Ddevsite%26sample_ct%3Dskippablelinear&correlator=[timestamp]"
      ],
      type: "linear",
      offset: 225
    }
  ];

  const ads = {
    admessage: "This video will resume in xx seconds",
    adscheduleid: "your_ad_schedule_id",
    client: "vast",
    cuetext: "Advertisement",
    outstream: false,
    preloadAds: false,
    vpaidcontrols: false,
    rules: {
      startOnSeek: "pre",
      timeBetweenAds: 0
    },
    schedule: newScheduleArray
  };

  return (
    <div className="App">
      <h1>React JwPlayer with Vast Ads</h1>
      <ReactJWPlayer
        file="http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4"
        playerId="123"
        playerScript="https://cdn.jwplayer.com/libraries/someid.js"
        customProps={{ advertising: { ...ads } }}
      />
    </div>
  );
}

现在谈论广告很好但是如何使用jwPlayer的各种工具:

  1. https://developer.jwplayer.com/jwplayer/reference/get_v2-advertising-schedules-ad-schedule-id-ad-schedule-extension
  2. https://developer-tools.jwplayer.com/ad-tester
  3. 大量演示广告:https ://foliovision.com/player/vast/sample-vast-tags
  4. JW 镜头:Chrome 插件: https ://extpose.com/ext/104286/en

这就是所有人

于 2022-01-17T18:17:09.880 回答