AdFormatC is a SceneGraph Group component that displays a full-width banner and reduces the video playback area to prevent the banner from overlapping live content. It is the only ad format that directly emits videoHeightReduction and videoOffsetY fields to signal the required video resize to its parent.
Interface fields
Configuration object built by
AdManager.BuildNodeConfig. Triggers onAdConfigChanged.| Key | Type | Default | Description |
|---|---|---|---|
media_url | string | — | URL of the banner image |
position | string | "bottom" | top, top-left, top-right, bottom (default), bottom-left, or bottom-right |
width_percent | float | 100.0 | Banner width as a percentage of the base viewport width |
height_percent | float | 15.0 | Banner height as a percentage of the base viewport height |
fit_mode | string | "fit" | "fill" maps to scaleToFill; anything else maps to scaleToFit |
viewport | assocarray | design size | {x, y, w, h} of the base (full-screen) area |
Set to
true once the Poster reports a ready load status. AdManager observes this to start the impression session.Set to
true on a load failure. AdManager destroys the slot, and videoHeightReduction and videoOffsetY are reset to 0.Pixel height consumed by this banner. Written during
onAdConfigChanged and reset to 0 on error or fade-out completion.Vertical pixel offset for the video origin. Non-zero only when the banner is positioned at the top. Reset to
0 on error or fade-out completion.How it reduces the video viewport
Format C uses the base viewport (full-screen area) rather than the live video viewport. The banner height is computed as a percentage of the base viewport height:- Bottom — banner is placed at
y = oy + sh - bannerH.videoOffsetY = 0,videoHeightReduction = bannerH. - Top — banner is placed at
y = oy.videoOffsetY = bannerH,videoHeightReduction = bannerH.
AdManager then reads these values via GetCReductionForSlot and calls RecomputeVideoReductionAndEmit to aggregate reductions from both c:top and c:bottom slots. The total is clamped so the remaining video height never falls below 480 px.
Visual behaviour
Format C uses the same 50 ms fade timer as Formats A and B. On a successful image load the banner fades in over approximately 300 ms. When the slot is destroyed,FadeOut is called; once the opacity reaches 0.0, both videoHeightReduction and videoOffsetY are reset to 0 so the video expands back to its original dimensions.
XML component definition
Slot keys
| Slot key | Position |
|---|---|
c:top | Banner at the top of the screen; video pushed down |
c:bottom | Banner at the bottom of the screen; video height reduced from below |
AdManager aggregates their reductions and clamps the total against the 480 px minimum video height.