@zync/zync-screnplay-player 0.1.187

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (133) hide show
  1. package/dist/ZyncScreenplayPlayer.js +35 -0
  2. package/dist/bundle.js +2 -0
  3. package/dist/bundle.js.LICENSE.txt +54 -0
  4. package/dist/index.js +4 -0
  5. package/dist/screenplay/RemotionRenderer/RemotionRenderer.js +281 -0
  6. package/dist/screenplay/RemotionRenderer/Root.js +22 -0
  7. package/dist/screenplay/RemotionRenderer/components/LottieAnimationGlobal.js +116 -0
  8. package/dist/screenplay/RemotionRenderer/components/backgrounds/VirtualBackground.js +26 -0
  9. package/dist/screenplay/RemotionRenderer/components/backgrounds/VirtualBackgroundUnderlay.js +41 -0
  10. package/dist/screenplay/RemotionRenderer/components/captions/CaptionSimple.js +12 -0
  11. package/dist/screenplay/RemotionRenderer/components/effects/BrollFullscreen.js +27 -0
  12. package/dist/screenplay/RemotionRenderer/components/effects/GlitchText.js +22 -0
  13. package/dist/screenplay/RemotionRenderer/components/effects/HandoffNametag.js +7 -0
  14. package/dist/screenplay/RemotionRenderer/components/effects/LottieAnimation.js +64 -0
  15. package/dist/screenplay/RemotionRenderer/components/effects/Nametag.js +9 -0
  16. package/dist/screenplay/RemotionRenderer/components/effects/PhraseRainbowEffect.js +34 -0
  17. package/dist/screenplay/RemotionRenderer/components/effects/Sentence.js +50 -0
  18. package/dist/screenplay/RemotionRenderer/components/effects/Title.js +12 -0
  19. package/dist/screenplay/RemotionRenderer/components/layouts/BrollGreenScreen.js +742 -0
  20. package/dist/screenplay/RemotionRenderer/components/layouts/BrollSplitScreen.js +714 -0
  21. package/dist/screenplay/RemotionRenderer/components/layouts/BrollStudioBackdrop.js +620 -0
  22. package/dist/screenplay/RemotionRenderer/components/layouts/DynamicTriangle.js +618 -0
  23. package/dist/screenplay/RemotionRenderer/components/layouts/Handoff.js +161 -0
  24. package/dist/screenplay/RemotionRenderer/components/layouts/IntroVideo.js +1330 -0
  25. package/dist/screenplay/RemotionRenderer/components/layouts/KeyPointOverlayDepth.js +397 -0
  26. package/dist/screenplay/RemotionRenderer/components/layouts/Keyword.js +539 -0
  27. package/dist/screenplay/RemotionRenderer/components/layouts/KeywordStudioBackdrop.js +714 -0
  28. package/dist/screenplay/RemotionRenderer/components/layouts/MotionStill.js +381 -0
  29. package/dist/screenplay/RemotionRenderer/components/layouts/MotionStillFullScreen.js +178 -0
  30. package/dist/screenplay/RemotionRenderer/components/layouts/MotionStillGreenScreen.js +568 -0
  31. package/dist/screenplay/RemotionRenderer/components/layouts/MotionStillGreenScreenV2.js +731 -0
  32. package/dist/screenplay/RemotionRenderer/components/layouts/MotionStillStudioBackdrop.js +588 -0
  33. package/dist/screenplay/RemotionRenderer/components/layouts/SimpleFrame.js +183 -0
  34. package/dist/screenplay/RemotionRenderer/components/layouts/SimpleFrameBroll.js +181 -0
  35. package/dist/screenplay/RemotionRenderer/components/layouts/SimpleFrameSentence.js +17 -0
  36. package/dist/screenplay/RemotionRenderer/components/layouts/SimpleFrameZoomCut.js +13 -0
  37. package/dist/screenplay/RemotionRenderer/components/layouts/TextWithVideo.js +373 -0
  38. package/dist/screenplay/RemotionRenderer/components/layouts/quote-bubble-animation.json +1 -0
  39. package/dist/screenplay/RemotionRenderer/components/utils/BlurOverlay.js +19 -0
  40. package/dist/screenplay/RemotionRenderer/components/utils/ChromaKeyedVideo.js +59 -0
  41. package/dist/screenplay/RemotionRenderer/components/utils/FaceCenteredVideo.js +562 -0
  42. package/dist/screenplay/RemotionRenderer/components/utils/PausableImg.js +124 -0
  43. package/dist/screenplay/RemotionRenderer/components/utils/README.md +80 -0
  44. package/dist/screenplay/RemotionRenderer/components/utils/SafeZones.js +69 -0
  45. package/dist/screenplay/RemotionRenderer/components/utils/StretchText.js +124 -0
  46. package/dist/screenplay/RemotionRenderer/components/utils/StretchTextDemo.js +66 -0
  47. package/dist/screenplay/RemotionRenderer/config.js +8 -0
  48. package/dist/screenplay/RemotionRenderer/development.js +1370 -0
  49. package/dist/screenplay/RemotionRenderer/helpers/cleanFacemetadata.js +29 -0
  50. package/dist/screenplay/RemotionRenderer/helpers/convertToSeconds.js +14 -0
  51. package/dist/screenplay/RemotionRenderer/helpers/faceBasedVideoStyles.js +212 -0
  52. package/dist/screenplay/RemotionRenderer/helpers/faceCenteredVideoTransforms.js +468 -0
  53. package/dist/screenplay/RemotionRenderer/helpers/getContrastColor.js +15 -0
  54. package/dist/screenplay/RemotionRenderer/helpers/getVideoOrientation.js +21 -0
  55. package/dist/screenplay/RemotionRenderer/helpers/hexToRgb.js +48 -0
  56. package/dist/screenplay/RemotionRenderer/hooks/useLottieReplaceColor.js +45 -0
  57. package/dist/screenplay/RemotionRenderer/hooks/useOrientationBased.js +29 -0
  58. package/dist/screenplay/RemotionRenderer/hooks/useTimeInterpolate.js +54 -0
  59. package/dist/screenplay/RemotionRenderer/hooks/useVirtualBackground.js +38 -0
  60. package/dist/screenplay/RemotionRenderer/index.js +3 -0
  61. package/dist/screenplay/RemotionRenderer/main/lib/Sequence.js +76 -0
  62. package/dist/screenplay/RemotionRenderer/main/lib/layouts/DefaultLayout.js +72 -0
  63. package/dist/screenplay/RemotionRenderer/main/lib/layouts/DynamicTriangleLayout.js +54 -0
  64. package/dist/screenplay/RemotionRenderer/main/lib/layouts/HandoffLayout.js +50 -0
  65. package/dist/screenplay/RemotionRenderer/main/lib/layouts/IntroVideoLayout.js +33 -0
  66. package/dist/screenplay/RemotionRenderer/main/lib/layouts/KeywordLayout.js +36 -0
  67. package/dist/screenplay/RemotionRenderer/main/lib/layouts/LayoutFactory.js +68 -0
  68. package/dist/screenplay/RemotionRenderer/main/lib/layouts/MotionStillLayout.js +36 -0
  69. package/dist/screenplay/RemotionRenderer/main/lib/layouts/SimpleFrameLayout.js +43 -0
  70. package/dist/screenplay/RemotionRenderer/main/lib/layouts/TextWithVideoLayout.js +52 -0
  71. package/dist/screenplay/RemotionRenderer/main/screenplaySchema.js +92 -0
  72. package/dist/screenplay/RemotionRenderer/registeredComponents.js +91 -0
  73. package/dist/screenplay/RemotionRenderer/theme/config.js +8 -0
  74. package/dist/screenplay/RemotionRenderer/theme/hooks/useTheme.js +24 -0
  75. package/dist/screenplay/RemotionRenderer/theme/hooks/useThemedComponents.js +101 -0
  76. package/dist/screenplay/RemotionRenderer/theme/themes/bigbold/BigBoldNameTag.js +147 -0
  77. package/dist/screenplay/RemotionRenderer/theme/themes/bigbold/BigBoldSentence.js +138 -0
  78. package/dist/screenplay/RemotionRenderer/theme/themes/bigbold/BigBoldTitle.js +136 -0
  79. package/dist/screenplay/RemotionRenderer/theme/themes/default/CaptionColor.js +67 -0
  80. package/dist/screenplay/RemotionRenderer/theme/themes/default/CaptionColorInverse.js +67 -0
  81. package/dist/screenplay/RemotionRenderer/theme/themes/default/CaptionColorShadow.js +66 -0
  82. package/dist/screenplay/RemotionRenderer/theme/themes/default/CaptionElegant.js +134 -0
  83. package/dist/screenplay/RemotionRenderer/theme/themes/default/CaptionEmphasis.js +122 -0
  84. package/dist/screenplay/RemotionRenderer/theme/themes/default/CaptionPunctuated.js +84 -0
  85. package/dist/screenplay/RemotionRenderer/theme/themes/default/CaptionWordBoom.js +88 -0
  86. package/dist/screenplay/RemotionRenderer/theme/themes/default/CaptionWordBubble.js +91 -0
  87. package/dist/screenplay/RemotionRenderer/theme/themes/default/CaptionWordPopup.js +118 -0
  88. package/dist/screenplay/RemotionRenderer/theme/themes/default/DefaultCaption.js +62 -0
  89. package/dist/screenplay/RemotionRenderer/theme/themes/default/HandoffNametag/handoffNametagConfig.js +59 -0
  90. package/dist/screenplay/RemotionRenderer/theme/themes/default/HandoffNametag.js +173 -0
  91. package/dist/screenplay/RemotionRenderer/theme/themes/default/Nametag.js +129 -0
  92. package/dist/screenplay/RemotionRenderer/theme/themes/default/Sentence/AnimatedSentence.js +20 -0
  93. package/dist/screenplay/RemotionRenderer/theme/themes/default/Sentence/AnimatedSentenceDefault.js +29 -0
  94. package/dist/screenplay/RemotionRenderer/theme/themes/default/Sentence/SentenceSimple.helpers.js +61 -0
  95. package/dist/screenplay/RemotionRenderer/theme/themes/default/Sentence.js +86 -0
  96. package/dist/screenplay/RemotionRenderer/theme/themes/default/Title.js +112 -0
  97. package/dist/screenplay/RemotionRenderer/theme/themes/default/constants.js +1 -0
  98. package/dist/screenplay/RemotionRenderer/theme/themes/glassmorphism/Nametag.js +134 -0
  99. package/dist/screenplay/RemotionRenderer/theme/themes/glassmorphism/Sentence.js +49 -0
  100. package/dist/screenplay/RemotionRenderer/theme/themes/glassmorphism/Title.js +108 -0
  101. package/dist/screenplay/RemotionRenderer/theme/themes/glassmorphism/animations.js +30 -0
  102. package/dist/screenplay/RemotionRenderer/theme/themes/glassmorphism/config.js +9 -0
  103. package/dist/screenplay/RemotionRenderer/theme/themes/glitch/GlitchNametag.js +252 -0
  104. package/dist/screenplay/RemotionRenderer/theme/themes/glitch/GlitchSentence.js +156 -0
  105. package/dist/screenplay/RemotionRenderer/theme/themes/glitch/GlitchTitle.js +142 -0
  106. package/dist/screenplay/RemotionRenderer/theme/themes/glitch/components/DisplacedText.js +66 -0
  107. package/dist/screenplay/RemotionRenderer/theme/themes/glitch/components/GlitchAnimatedLine.js +38 -0
  108. package/dist/screenplay/RemotionRenderer/theme/themes/glitch/components/SplitSentence.js +80 -0
  109. package/dist/screenplay/RemotionRenderer/theme/themes/glitch/helpers.js +32 -0
  110. package/dist/screenplay/RemotionRenderer/theme/themes/none/Nametag.js +3 -0
  111. package/dist/screenplay/RemotionRenderer/theme/themes/none/Title.js +3 -0
  112. package/dist/screenplay/RemotionRenderer/theme/themes/pushpull/PushPullNametag.js +165 -0
  113. package/dist/screenplay/RemotionRenderer/theme/themes/pushpull/PushPullSentence.js +94 -0
  114. package/dist/screenplay/RemotionRenderer/theme/themes/pushpull/PushPullTitle.js +98 -0
  115. package/dist/screenplay/RemotionRenderer/theme/themes/pushpull/designs/sentence.js +92 -0
  116. package/dist/screenplay/RemotionRenderer/theme/themes/pushpull/designs/title.js +119 -0
  117. package/dist/screenplay/RemotionRenderer/theme/themes/sports/Nametag.js +122 -0
  118. package/dist/screenplay/RemotionRenderer/theme/themes/sports/SportsCaption.js +93 -0
  119. package/dist/screenplay/RemotionRenderer/theme/themes/sports/SportsSentence.js +76 -0
  120. package/dist/screenplay/RemotionRenderer/theme/themes/sports/Title.js +90 -0
  121. package/dist/screenplay/RemotionRenderer/theme/themes/sports/shared.js +62 -0
  122. package/dist/screenplay/RemotionRenderer/theme/themes/sportsbounce/Nametag.js +145 -0
  123. package/dist/screenplay/RemotionRenderer/theme/themes/sportsbounce/SportsBounceSentence.js +148 -0
  124. package/dist/screenplay/RemotionRenderer/theme/themes/sportsbounce/Title.js +160 -0
  125. package/dist/screenplay/RemotionRenderer/tracks/AudioTrack.js +23 -0
  126. package/dist/screenplay/RemotionRenderer/tracks/CaptionsVideoTrack.js +23 -0
  127. package/dist/screenplay/RemotionRenderer/tracks/DynamicVideoComposition.js +31 -0
  128. package/dist/screenplay/RemotionRenderer/tracks/EffectsVideoTrack.js +23 -0
  129. package/dist/screenplay/RemotionRenderer/tracks/LayoutVideoTrack.js +141 -0
  130. package/dist/screenplay/RemotionRenderer/tracks/Soundtrack.js +16 -0
  131. package/dist/screenplay/RemotionRenderer/tracks/Watermark.js +23 -0
  132. package/dist/screenplay/RemotionRenderer/tracks/transitions/GlitchOne.js +92 -0
  133. package/package.json +45 -0
@@ -0,0 +1,742 @@
1
+ import React from "react";
2
+ import { AbsoluteFill, Audio, Easing, Img, OffthreadVideo, useVideoConfig } from "remotion";
3
+ import { useOrientationBased } from "../../hooks/useOrientationBased.js";
4
+ import { useTimeInterpolate } from "../../hooks/useTimeInterpolate.js";
5
+ import { CHROME_PADDING } from "../../config.js";
6
+ import FaceCenteredVideo from "../utils/FaceCenteredVideo";
7
+ import PausableImg from "../utils/PausableImg";
8
+ import { BlurOverlay } from "../utils/BlurOverlay";
9
+ import { useVirtualBackground } from "../../hooks/useVirtualBackground";
10
+ import { VirtualBackgroundUnderlay } from "../backgrounds/VirtualBackgroundUnderlay";
11
+ var Square = function Square(_ref) {
12
+ var children = _ref.children,
13
+ brollUrl = _ref.brollUrl,
14
+ brollVideoWidthTransition = _ref.brollVideoWidthTransition,
15
+ brollVideoHeightTransition = _ref.brollVideoHeightTransition,
16
+ brollVideoTopTransition = _ref.brollVideoTopTransition,
17
+ brollVideoLeftTransition = _ref.brollVideoLeftTransition,
18
+ mainVideoWidthTransition = _ref.mainVideoWidthTransition,
19
+ mainVideoHeightTransition = _ref.mainVideoHeightTransition,
20
+ mainVideoTopTransition = _ref.mainVideoTopTransition,
21
+ mainVideoLeftTransition = _ref.mainVideoLeftTransition,
22
+ logoUrl = _ref.logoUrl,
23
+ logoLeft = _ref.logoLeft,
24
+ logoTop = _ref.logoTop,
25
+ frameColor = _ref.frameColor,
26
+ startVideoFrom = _ref.startVideoFrom,
27
+ noBackgroundVideoUrl = _ref.noBackgroundVideoUrl,
28
+ sourceVideoOrientation = _ref.sourceVideoOrientation,
29
+ videoUrl = _ref.videoUrl,
30
+ faceMetadata = _ref.faceMetadata,
31
+ noBackgroundVideoEffects = _ref.noBackgroundVideoEffects,
32
+ showVirtual = _ref.showVirtual,
33
+ virtualBgUrl = _ref.virtualBgUrl;
34
+ var _useVideoConfig = useVideoConfig(),
35
+ width = _useVideoConfig.width,
36
+ height = _useVideoConfig.height;
37
+ return /*#__PURE__*/React.createElement(AbsoluteFill, {
38
+ style: {
39
+ backgroundColor: frameColor || "transparent",
40
+ padding: 0,
41
+ isolation: "isolate"
42
+ }
43
+ }, brollUrl && /*#__PURE__*/React.createElement("div", {
44
+ style: {
45
+ position: "absolute",
46
+ overflow: "hidden",
47
+ width: "100%",
48
+ height: brollVideoHeightTransition,
49
+ transform: "translateX(-50%) scale(1.25)",
50
+ transformOrigin: "center center",
51
+ left: "50%",
52
+ zIndex: 2,
53
+ // Add gradient mask for fade to transparent effect in square
54
+ mask: "linear-gradient(to bottom, black 0%, black 60%, transparent 100%)",
55
+ WebkitMask: "linear-gradient(to bottom, black 0%, black 60%, transparent 100%)"
56
+ }
57
+ }, /*#__PURE__*/React.createElement(OffthreadVideo, {
58
+ src: brollUrl,
59
+ style: {
60
+ height: "100%",
61
+ objectFit: "cover",
62
+ width: "100%",
63
+ filter: !showVirtual && noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim && noBackgroundVideoUrl ? "brightness(0.7)" : undefined
64
+ },
65
+ muted: true
66
+ })), /*#__PURE__*/React.createElement("div", {
67
+ style: {
68
+ position: "absolute",
69
+ overflow: "hidden",
70
+ width: mainVideoWidthTransition,
71
+ height: mainVideoHeightTransition,
72
+ top: mainVideoTopTransition,
73
+ left: mainVideoLeftTransition,
74
+ zIndex: 2
75
+ }
76
+ }, showVirtual && virtualBgUrl ? /*#__PURE__*/React.createElement(VirtualBackgroundUnderlay, {
77
+ url: virtualBgUrl,
78
+ top: 0,
79
+ left: 0,
80
+ width: "100%",
81
+ height: "100%",
82
+ zIndex: 2
83
+ }) : null, faceMetadata ? /*#__PURE__*/React.createElement(FaceCenteredVideo, {
84
+ startFrom: startVideoFrom,
85
+ src: noBackgroundVideoUrl,
86
+ faceMetadata: faceMetadata,
87
+ containerWidth: mainVideoWidthTransition,
88
+ containerHeight: mainVideoHeightTransition,
89
+ useAveragePosition: true,
90
+ centerHorizontally: true,
91
+ transparent: true
92
+ }) : /*#__PURE__*/React.createElement(OffthreadVideo, {
93
+ startFrom: startVideoFrom,
94
+ src: noBackgroundVideoUrl,
95
+ muted: false,
96
+ transparent: true,
97
+ style: {
98
+ height: "100%",
99
+ objectFit: "cover",
100
+ width: "100%",
101
+ objectPosition: sourceVideoOrientation === "portrait" ? "0% 30%" : undefined
102
+ }
103
+ })), /*#__PURE__*/React.createElement("div", {
104
+ style: {
105
+ position: "absolute",
106
+ overflow: "hidden",
107
+ width: mainVideoWidthTransition,
108
+ height: mainVideoHeightTransition,
109
+ top: mainVideoTopTransition,
110
+ left: mainVideoLeftTransition,
111
+ zIndex: 0
112
+ }
113
+ }, faceMetadata ? /*#__PURE__*/React.createElement(FaceCenteredVideo, {
114
+ startFrom: startVideoFrom,
115
+ src: videoUrl,
116
+ transparent: false,
117
+ faceMetadata: faceMetadata,
118
+ containerWidth: mainVideoWidthTransition,
119
+ containerHeight: mainVideoHeightTransition,
120
+ useAveragePosition: true,
121
+ centerHorizontally: true,
122
+ muted: true,
123
+ style: {
124
+ zIndex: 0,
125
+ filter: !showVirtual && noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim && noBackgroundVideoUrl ? "brightness(0.7)" : undefined
126
+ }
127
+ }) : /*#__PURE__*/React.createElement(OffthreadVideo, {
128
+ startFrom: startVideoFrom,
129
+ src: videoUrl,
130
+ muted: true,
131
+ transparent: false,
132
+ style: {
133
+ zIndex: 0,
134
+ height: "100%",
135
+ objectFit: "cover",
136
+ width: "100%",
137
+ objectPosition: sourceVideoOrientation === "portrait" ? "0% 30%" : undefined,
138
+ filter: !showVirtual && noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim && noBackgroundVideoUrl ? "brightness(0.7)" : undefined
139
+ }
140
+ })), /*#__PURE__*/React.createElement(BlurOverlay, {
141
+ show: !showVirtual && (noBackgroundVideoEffects === null || noBackgroundVideoEffects === void 0 ? void 0 : noBackgroundVideoEffects.backgroundBlur) && noBackgroundVideoUrl,
142
+ width: width,
143
+ height: height,
144
+ zIndex: 1
145
+ }), noBackgroundVideoUrl && (showVirtual || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.facePop || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundBlur) && faceMetadata ? /*#__PURE__*/React.createElement(AbsoluteFill, {
146
+ style: {
147
+ position: "absolute",
148
+ overflow: "hidden",
149
+ width: mainVideoWidthTransition,
150
+ height: mainVideoHeightTransition,
151
+ top: mainVideoTopTransition,
152
+ left: mainVideoLeftTransition,
153
+ zIndex: 9
154
+ }
155
+ }, /*#__PURE__*/React.createElement(FaceCenteredVideo, {
156
+ src: noBackgroundVideoUrl,
157
+ startFrom: startVideoFrom,
158
+ containerWidth: mainVideoWidthTransition,
159
+ containerHeight: mainVideoHeightTransition,
160
+ faceMetadata: faceMetadata,
161
+ useAveragePosition: true,
162
+ centerHorizontally: true,
163
+ noBackgroundVideoEffects: noBackgroundVideoEffects,
164
+ transparent: true,
165
+ muted: true
166
+ })) : null, noBackgroundVideoUrl && (showVirtual || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.facePop || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundBlur) && !faceMetadata ? /*#__PURE__*/React.createElement(AbsoluteFill, {
167
+ style: {
168
+ position: "absolute",
169
+ overflow: "hidden",
170
+ width: mainVideoWidthTransition,
171
+ height: mainVideoHeightTransition,
172
+ top: mainVideoTopTransition,
173
+ left: mainVideoLeftTransition,
174
+ zIndex: 9
175
+ }
176
+ }, /*#__PURE__*/React.createElement(OffthreadVideo, {
177
+ startFrom: startVideoFrom,
178
+ src: noBackgroundVideoUrl,
179
+ muted: true,
180
+ transparent: true,
181
+ style: {
182
+ position: "relative",
183
+ top: "50%",
184
+ objectFit: "cover",
185
+ width: mainVideoWidthTransition,
186
+ height: mainVideoHeightTransition,
187
+ borderRadius: "30px",
188
+ filter: noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.facePop ? "brightness(1.1) contrast(1.15) saturate(1.05)" : undefined,
189
+ transform: "translateY(-50%)"
190
+ }
191
+ })) : null, /*#__PURE__*/React.createElement(AbsoluteFill, {
192
+ style: {
193
+ zIndex: 10
194
+ }
195
+ }, children), logoUrl ? /*#__PURE__*/React.createElement("div", {
196
+ style: {
197
+ position: "fixed",
198
+ left: logoLeft,
199
+ top: logoTop,
200
+ padding: 20,
201
+ zIndex: 10
202
+ }
203
+ }, /*#__PURE__*/React.createElement(PausableImg, {
204
+ delayRenderTimeoutInMilliseconds: 61000,
205
+ style: {
206
+ width: "225px",
207
+ maxHeight: "auto",
208
+ objectFit: "contain"
209
+ },
210
+ src: logoUrl
211
+ })) : null);
212
+ };
213
+ var Portrait = function Portrait(_ref2) {
214
+ var children = _ref2.children,
215
+ brollUrl = _ref2.brollUrl,
216
+ brollVideoWidthTransition = _ref2.brollVideoWidthTransition,
217
+ brollVideoHeightTransition = _ref2.brollVideoHeightTransition,
218
+ brollVideoTopTransition = _ref2.brollVideoTopTransition,
219
+ brollVideoLeftTransition = _ref2.brollVideoLeftTransition,
220
+ mainVideoWidthTransition = _ref2.mainVideoWidthTransition,
221
+ mainVideoHeightTransition = _ref2.mainVideoHeightTransition,
222
+ mainVideoTopTransition = _ref2.mainVideoTopTransition,
223
+ mainVideoLeftTransition = _ref2.mainVideoLeftTransition,
224
+ logoUrl = _ref2.logoUrl,
225
+ logoLeft = _ref2.logoLeft,
226
+ logoTop = _ref2.logoTop,
227
+ frameColor = _ref2.frameColor,
228
+ orientation = _ref2.orientation,
229
+ startVideoFrom = _ref2.startVideoFrom,
230
+ noBackgroundVideoUrl = _ref2.noBackgroundVideoUrl,
231
+ sourceVideoOrientation = _ref2.sourceVideoOrientation,
232
+ videoUrl = _ref2.videoUrl,
233
+ faceMetadata = _ref2.faceMetadata,
234
+ noBackgroundVideoEffects = _ref2.noBackgroundVideoEffects,
235
+ showVirtual = _ref2.showVirtual,
236
+ virtualBgUrl = _ref2.virtualBgUrl;
237
+ var _useVideoConfig2 = useVideoConfig(),
238
+ width = _useVideoConfig2.width,
239
+ height = _useVideoConfig2.height;
240
+ return /*#__PURE__*/React.createElement(AbsoluteFill, {
241
+ style: {
242
+ backgroundColor: frameColor || "transparent",
243
+ padding: 0,
244
+ isolation: "isolate"
245
+ }
246
+ }, brollUrl && /*#__PURE__*/React.createElement("div", {
247
+ style: {
248
+ position: "absolute",
249
+ overflow: "hidden",
250
+ borderRadius: orientation === "landscape" ? "0px" : "20px",
251
+ width: "100%",
252
+ height: brollVideoHeightTransition,
253
+ top: brollVideoTopTransition,
254
+ left: brollVideoLeftTransition,
255
+ zIndex: 2,
256
+ transformOrigin: "center center",
257
+ transform: "scale(1.1)",
258
+ // Add gradient mask for fade to transparent effect in portrait
259
+ mask: "linear-gradient(to bottom, black 0%, black 60%, transparent 100%)",
260
+ WebkitMask: "linear-gradient(to bottom, black 0%, black 60%, transparent 100%)"
261
+ }
262
+ }, /*#__PURE__*/React.createElement(OffthreadVideo, {
263
+ src: brollUrl,
264
+ style: {
265
+ height: "100%",
266
+ objectFit: "cover",
267
+ width: "100%",
268
+ filter: !showVirtual && noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim && noBackgroundVideoUrl ? "brightness(0.7)" : undefined
269
+ },
270
+ muted: true
271
+ })), /*#__PURE__*/React.createElement("div", {
272
+ style: {
273
+ position: "absolute",
274
+ overflow: "hidden",
275
+ borderRadius: "20px",
276
+ width: mainVideoWidthTransition,
277
+ height: mainVideoHeightTransition,
278
+ top: mainVideoTopTransition,
279
+ left: mainVideoLeftTransition,
280
+ zIndex: 2
281
+ }
282
+ }, showVirtual && virtualBgUrl ? /*#__PURE__*/React.createElement(VirtualBackgroundUnderlay, {
283
+ url: virtualBgUrl,
284
+ top: 0,
285
+ left: 0,
286
+ width: "100%",
287
+ height: "100%",
288
+ borderRadius: "20px",
289
+ zIndex: 2
290
+ }) : null, faceMetadata ? /*#__PURE__*/React.createElement(FaceCenteredVideo, {
291
+ startFrom: startVideoFrom,
292
+ src: noBackgroundVideoUrl,
293
+ faceMetadata: faceMetadata,
294
+ containerWidth: mainVideoWidthTransition,
295
+ containerHeight: mainVideoHeightTransition,
296
+ useAveragePosition: true,
297
+ centerHorizontally: false,
298
+ transparent: true
299
+ }) : /*#__PURE__*/React.createElement(OffthreadVideo, {
300
+ startFrom: startVideoFrom,
301
+ src: noBackgroundVideoUrl,
302
+ muted: false,
303
+ transparent: true,
304
+ style: {
305
+ height: "100%",
306
+ objectFit: "cover",
307
+ width: "100%",
308
+ objectPosition: sourceVideoOrientation === "portrait" ? "0% 30%" : undefined
309
+ }
310
+ })), /*#__PURE__*/React.createElement("div", {
311
+ style: {
312
+ position: "absolute",
313
+ overflow: "hidden",
314
+ borderRadius: "20px",
315
+ width: mainVideoWidthTransition,
316
+ height: mainVideoHeightTransition,
317
+ top: mainVideoTopTransition,
318
+ left: mainVideoLeftTransition,
319
+ transform: "scale(1)",
320
+ zIndex: 0
321
+ }
322
+ }, faceMetadata ? /*#__PURE__*/React.createElement(FaceCenteredVideo, {
323
+ startFrom: startVideoFrom,
324
+ src: videoUrl,
325
+ faceMetadata: faceMetadata,
326
+ containerWidth: mainVideoWidthTransition,
327
+ containerHeight: mainVideoHeightTransition,
328
+ noBackgroundVideoEffects: noBackgroundVideoEffects,
329
+ useAveragePosition: true,
330
+ muted: true,
331
+ transparent: false,
332
+ style: {
333
+ zIndex: 0
334
+ }
335
+ }) : /*#__PURE__*/React.createElement(OffthreadVideo, {
336
+ startFrom: startVideoFrom,
337
+ src: videoUrl,
338
+ muted: true,
339
+ transparent: false,
340
+ style: {
341
+ zIndex: 0,
342
+ height: "100%",
343
+ objectFit: "cover",
344
+ width: "100%",
345
+ objectPosition: sourceVideoOrientation === "portrait" ? "0% 30%" : undefined,
346
+ filter: !showVirtual && noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim && noBackgroundVideoUrl ? "brightness(0.7)" : undefined
347
+ }
348
+ })), /*#__PURE__*/React.createElement(BlurOverlay, {
349
+ show: !showVirtual && (noBackgroundVideoEffects === null || noBackgroundVideoEffects === void 0 ? void 0 : noBackgroundVideoEffects.backgroundBlur) && noBackgroundVideoUrl,
350
+ width: width,
351
+ height: height,
352
+ zIndex: 1
353
+ }), noBackgroundVideoUrl && (showVirtual || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.facePop || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundBlur) && faceMetadata ? /*#__PURE__*/React.createElement(AbsoluteFill, {
354
+ style: {
355
+ position: "absolute",
356
+ overflow: "hidden",
357
+ borderRadius: "20px",
358
+ width: mainVideoWidthTransition,
359
+ height: mainVideoHeightTransition,
360
+ top: mainVideoTopTransition,
361
+ left: mainVideoLeftTransition,
362
+ transform: "scale(1)",
363
+ zIndex: 9
364
+ }
365
+ }, /*#__PURE__*/React.createElement(FaceCenteredVideo, {
366
+ src: noBackgroundVideoUrl,
367
+ startFrom: startVideoFrom,
368
+ containerWidth: mainVideoWidthTransition,
369
+ containerHeight: mainVideoHeightTransition,
370
+ faceMetadata: faceMetadata,
371
+ useAveragePosition: true,
372
+ centerHorizontally: false,
373
+ noBackgroundVideoEffects: noBackgroundVideoEffects,
374
+ transparent: true,
375
+ muted: true
376
+ })) : null, noBackgroundVideoUrl && (showVirtual || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.facePop || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundBlur) && !faceMetadata ? /*#__PURE__*/React.createElement(AbsoluteFill, {
377
+ style: {
378
+ position: "absolute",
379
+ overflow: "hidden",
380
+ borderRadius: "20px",
381
+ width: mainVideoWidthTransition,
382
+ height: mainVideoHeightTransition,
383
+ top: mainVideoTopTransition,
384
+ left: mainVideoLeftTransition,
385
+ transform: "scale(1)",
386
+ zIndex: 9
387
+ }
388
+ }, /*#__PURE__*/React.createElement(OffthreadVideo, {
389
+ startFrom: startVideoFrom,
390
+ src: noBackgroundVideoUrl,
391
+ muted: true,
392
+ transparent: true,
393
+ style: {
394
+ position: "relative",
395
+ width: mainVideoWidthTransition,
396
+ height: mainVideoHeightTransition,
397
+ top: "50%",
398
+ objectFit: "cover",
399
+ borderRadius: "30px",
400
+ filter: noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.facePop ? "brightness(1.1) contrast(1.15) saturate(1.05)" : undefined,
401
+ transform: "translateY(-50%)"
402
+ }
403
+ })) : null, /*#__PURE__*/React.createElement(AbsoluteFill, {
404
+ style: {
405
+ zIndex: 3
406
+ }
407
+ }, children), logoUrl ? /*#__PURE__*/React.createElement("div", {
408
+ style: {
409
+ position: "fixed",
410
+ left: logoLeft,
411
+ top: logoTop,
412
+ padding: 20,
413
+ zIndex: 10
414
+ }
415
+ }, /*#__PURE__*/React.createElement(PausableImg, {
416
+ delayRenderTimeoutInMilliseconds: 61000,
417
+ style: {
418
+ width: "225px",
419
+ maxHeight: "auto",
420
+ objectFit: "contain"
421
+ },
422
+ src: logoUrl
423
+ })) : null);
424
+ };
425
+ var Landscape = function Landscape(_ref3) {
426
+ var children = _ref3.children,
427
+ brollUrl = _ref3.brollUrl,
428
+ brollVideoWidthTransition = _ref3.brollVideoWidthTransition,
429
+ brollVideoHeightTransition = _ref3.brollVideoHeightTransition,
430
+ mainVideoWidthTransition = _ref3.mainVideoWidthTransition,
431
+ mainVideoHeightTransition = _ref3.mainVideoHeightTransition,
432
+ mainVideoTopTransition = _ref3.mainVideoTopTransition,
433
+ mainVideoLeftTransition = _ref3.mainVideoLeftTransition,
434
+ logoUrl = _ref3.logoUrl,
435
+ logoLeft = _ref3.logoLeft,
436
+ logoTop = _ref3.logoTop,
437
+ frameColor = _ref3.frameColor,
438
+ orientation = _ref3.orientation,
439
+ startVideoFrom = _ref3.startVideoFrom,
440
+ noBackgroundVideoUrl = _ref3.noBackgroundVideoUrl,
441
+ sourceVideoOrientation = _ref3.sourceVideoOrientation,
442
+ faceMetadata = _ref3.faceMetadata,
443
+ noBackgroundVideoEffects = _ref3.noBackgroundVideoEffects,
444
+ showVirtual = _ref3.showVirtual,
445
+ virtualBgUrl = _ref3.virtualBgUrl;
446
+ var _useVideoConfig3 = useVideoConfig(),
447
+ width = _useVideoConfig3.width,
448
+ height = _useVideoConfig3.height;
449
+ return /*#__PURE__*/React.createElement(AbsoluteFill, {
450
+ style: {
451
+ backgroundColor: frameColor || "transparent",
452
+ padding: 0,
453
+ isolation: "isolate"
454
+ }
455
+ }, brollUrl && /*#__PURE__*/React.createElement("div", {
456
+ style: {
457
+ position: "absolute",
458
+ overflow: "hidden",
459
+ transformOrigin: "center center",
460
+ transform: "translate(-50%, -50%)",
461
+ borderRadius: orientation === "landscape" ? "0px" : "20px",
462
+ width: brollVideoWidthTransition,
463
+ height: brollVideoHeightTransition,
464
+ top: "50%",
465
+ left: "50%",
466
+ zIndex: orientation === "landscape" ? 1 : 2
467
+ }
468
+ }, /*#__PURE__*/React.createElement(OffthreadVideo, {
469
+ src: brollUrl,
470
+ style: {
471
+ height: "100%",
472
+ objectFit: "cover",
473
+ width: "100%",
474
+ filter: !showVirtual && noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim && noBackgroundVideoUrl ? "brightness(0.7)" : undefined
475
+ },
476
+ muted: true
477
+ })), /*#__PURE__*/React.createElement("div", {
478
+ style: {
479
+ position: "absolute",
480
+ overflow: "hidden",
481
+ borderRadius: "20px",
482
+ width: mainVideoWidthTransition,
483
+ height: mainVideoHeightTransition,
484
+ top: mainVideoTopTransition,
485
+ left: mainVideoLeftTransition,
486
+ zIndex: 2
487
+ }
488
+ }, showVirtual && virtualBgUrl ? /*#__PURE__*/React.createElement(VirtualBackgroundUnderlay, {
489
+ url: virtualBgUrl,
490
+ top: 0,
491
+ left: 0,
492
+ width: "100%",
493
+ height: "100%",
494
+ borderRadius: "20px",
495
+ zIndex: 2
496
+ }) : null, faceMetadata ? /*#__PURE__*/React.createElement(FaceCenteredVideo, {
497
+ startFrom: startVideoFrom,
498
+ src: noBackgroundVideoUrl,
499
+ faceMetadata: faceMetadata,
500
+ containerWidth: mainVideoWidthTransition,
501
+ containerHeight: mainVideoHeightTransition,
502
+ useAveragePosition: true,
503
+ transparent: true
504
+ }) : /*#__PURE__*/React.createElement(OffthreadVideo, {
505
+ startFrom: startVideoFrom,
506
+ src: noBackgroundVideoUrl,
507
+ muted: false,
508
+ transparent: true,
509
+ style: {
510
+ height: "100%",
511
+ objectFit: "cover",
512
+ width: "100%",
513
+ objectPosition: sourceVideoOrientation === "portrait" ? "0% 30%" : undefined
514
+ }
515
+ })), /*#__PURE__*/React.createElement(BlurOverlay, {
516
+ show: !showVirtual && (noBackgroundVideoEffects === null || noBackgroundVideoEffects === void 0 ? void 0 : noBackgroundVideoEffects.backgroundBlur) && noBackgroundVideoUrl,
517
+ width: width,
518
+ height: height,
519
+ zIndex: 1
520
+ }), noBackgroundVideoUrl && (showVirtual || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.facePop || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundBlur) && faceMetadata ? /*#__PURE__*/React.createElement(AbsoluteFill, {
521
+ style: {
522
+ position: "absolute",
523
+ overflow: "hidden",
524
+ borderRadius: "20px",
525
+ width: mainVideoWidthTransition,
526
+ height: mainVideoHeightTransition,
527
+ top: mainVideoTopTransition,
528
+ left: mainVideoLeftTransition,
529
+ zIndex: 9
530
+ }
531
+ }, /*#__PURE__*/React.createElement(FaceCenteredVideo, {
532
+ src: noBackgroundVideoUrl,
533
+ startFrom: startVideoFrom,
534
+ containerWidth: mainVideoWidthTransition,
535
+ containerHeight: mainVideoHeightTransition,
536
+ faceMetadata: faceMetadata,
537
+ useAveragePosition: true,
538
+ centerHorizontally: false,
539
+ noBackgroundVideoEffects: noBackgroundVideoEffects,
540
+ transparent: true,
541
+ muted: true
542
+ })) : null, noBackgroundVideoUrl && (showVirtual || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.facePop || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundBlur) && !faceMetadata ? /*#__PURE__*/React.createElement(AbsoluteFill, {
543
+ style: {
544
+ position: "absolute",
545
+ overflow: "hidden",
546
+ borderRadius: "20px",
547
+ width: mainVideoWidthTransition,
548
+ height: mainVideoHeightTransition,
549
+ top: mainVideoTopTransition,
550
+ left: mainVideoLeftTransition,
551
+ zIndex: 9
552
+ }
553
+ }, /*#__PURE__*/React.createElement(OffthreadVideo, {
554
+ startFrom: startVideoFrom,
555
+ src: noBackgroundVideoUrl,
556
+ muted: true,
557
+ transparent: true,
558
+ style: {
559
+ position: "relative",
560
+ top: "50%",
561
+ height: "100%",
562
+ objectFit: "cover",
563
+ width: "100%",
564
+ borderRadius: "30px",
565
+ filter: noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.facePop ? "brightness(1.1) contrast(1.15) saturate(1.05)" : undefined,
566
+ transform: "translateY(-50%)"
567
+ }
568
+ })) : null, /*#__PURE__*/React.createElement(AbsoluteFill, {
569
+ style: {
570
+ zIndex: 13
571
+ }
572
+ }, children), logoUrl ? /*#__PURE__*/React.createElement("div", {
573
+ style: {
574
+ position: "fixed",
575
+ left: logoLeft,
576
+ top: logoTop,
577
+ padding: 20,
578
+ zIndex: 10
579
+ }
580
+ }, /*#__PURE__*/React.createElement(PausableImg, {
581
+ delayRenderTimeoutInMilliseconds: 61000,
582
+ style: {
583
+ width: "225px",
584
+ maxHeight: "auto",
585
+ objectFit: "contain"
586
+ },
587
+ src: logoUrl
588
+ })) : null);
589
+ };
590
+
591
+ // Configuration for different orientation split screens
592
+ var BrollGreenScreen = function BrollGreenScreen(_ref4) {
593
+ var videoUrl = _ref4.videoUrl,
594
+ startVideoFrom = _ref4.startVideoFrom,
595
+ brollUrl = _ref4.brollUrl,
596
+ muted = _ref4.muted,
597
+ frameColor = _ref4.frameColor,
598
+ logoUrl = _ref4.logoUrl,
599
+ children = _ref4.children,
600
+ sourceVideoOrientation = _ref4.sourceVideoOrientation,
601
+ _ref4$disableTransiti = _ref4.disableTransitionSounds,
602
+ disableTransitionSounds = _ref4$disableTransiti === void 0 ? false : _ref4$disableTransiti,
603
+ noBackgroundVideoUrl = _ref4.noBackgroundVideoUrl,
604
+ durationInFrames = _ref4.durationInFrames,
605
+ faceMetadata = _ref4.faceMetadata,
606
+ noBackgroundVideoEffects = _ref4.noBackgroundVideoEffects;
607
+ var _useVideoConfig4 = useVideoConfig(),
608
+ width = _useVideoConfig4.width,
609
+ height = _useVideoConfig4.height;
610
+ var _useVirtualBackground = useVirtualBackground(),
611
+ isVirtual = _useVirtualBackground.isVirtual,
612
+ virtualBgUrl = _useVirtualBackground.url;
613
+ var showVirtual = isVirtual && !!noBackgroundVideoUrl;
614
+
615
+ // Convert duration from frames to seconds (assuming 30 fps)
616
+ var durationInSeconds = durationInFrames / 30;
617
+
618
+ // Configure orientation-specific layouts
619
+ var _useOrientationBased = useOrientationBased({
620
+ portrait: {
621
+ // Portrait: Broll on top, main video on bottom (swapped positions)
622
+ mainVideoWidth: width,
623
+ mainVideoHeight: height * 0.8,
624
+ mainVideoTop: height * 0.2,
625
+ mainVideoLeft: 0,
626
+ brollVideoWidth: width,
627
+ brollVideoHeight: height * 0.6,
628
+ brollVideoTop: CHROME_PADDING,
629
+ brollVideoLeft: CHROME_PADDING,
630
+ logoTop: CHROME_PADDING * 2,
631
+ logoLeft: CHROME_PADDING * 2,
632
+ BrollGreenScreenComponent: Portrait
633
+ },
634
+ landscape: {
635
+ // Landscape: Broll fullscreen with portrait video (3:4 aspect ratio) aligned to the right
636
+ mainVideoWidth: width,
637
+ mainVideoHeight: height * 0.86,
638
+ mainVideoTop: CHROME_PADDING + height * 0.14,
639
+ mainVideoLeft: 0,
640
+ brollVideoWidth: width,
641
+ brollVideoHeight: height * 0.65,
642
+ brollVideoTop: 0,
643
+ brollVideoLeft: 0,
644
+ logoTop: CHROME_PADDING * 2,
645
+ logoLeft: CHROME_PADDING * 2,
646
+ BrollGreenScreenComponent: Square
647
+ },
648
+ square: {
649
+ // Square: Main video on top, broll on bottom
650
+ mainVideoWidth: width,
651
+ mainVideoHeight: height * 0.86,
652
+ mainVideoTop: CHROME_PADDING + height * 0.14,
653
+ mainVideoLeft: 0,
654
+ brollVideoWidth: width,
655
+ brollVideoHeight: height * 0.5,
656
+ brollVideoTop: 0,
657
+ brollVideoLeft: 0,
658
+ logoTop: CHROME_PADDING * 2,
659
+ logoLeft: CHROME_PADDING * 2,
660
+ BrollGreenScreenComponent: Square
661
+ }
662
+ }),
663
+ BrollGreenScreenComponent = _useOrientationBased.BrollGreenScreenComponent,
664
+ mainVideoWidth = _useOrientationBased.mainVideoWidth,
665
+ mainVideoHeight = _useOrientationBased.mainVideoHeight,
666
+ mainVideoTop = _useOrientationBased.mainVideoTop,
667
+ mainVideoLeft = _useOrientationBased.mainVideoLeft,
668
+ brollVideoWidth = _useOrientationBased.brollVideoWidth,
669
+ brollVideoHeight = _useOrientationBased.brollVideoHeight,
670
+ brollVideoTop = _useOrientationBased.brollVideoTop,
671
+ brollVideoLeft = _useOrientationBased.brollVideoLeft,
672
+ logoTop = _useOrientationBased.logoTop,
673
+ logoLeft = _useOrientationBased.logoLeft,
674
+ orientation = _useOrientationBased.orientation;
675
+
676
+ // Transition timing - starting full screen, transitioning to split screen, then back to full screen
677
+ var transitionTimings = [0, 0.5, durationInSeconds - 0.5, durationInSeconds]; // Start at 0, split at 0.5, return to original at 1.0
678
+
679
+ // Main video transitions
680
+ var mainVideoWidthTransition = useTimeInterpolate(transitionTimings, [width, mainVideoWidth, mainVideoWidth, width], {
681
+ extrapolateRight: "clamp",
682
+ easing: Easing["in"](Easing.quad)
683
+ });
684
+ var mainVideoHeightTransition = useTimeInterpolate(transitionTimings, [height, mainVideoHeight, mainVideoHeight, height], {
685
+ extrapolateRight: "clamp",
686
+ easing: Easing["in"](Easing.quad)
687
+ });
688
+ var mainVideoTopTransition = useTimeInterpolate(transitionTimings, [0, mainVideoTop, mainVideoTop, 0], {
689
+ extrapolateRight: "clamp",
690
+ easing: Easing["in"](Easing.quad)
691
+ });
692
+ var mainVideoLeftTransition = useTimeInterpolate(transitionTimings, [0, mainVideoLeft, mainVideoLeft, 0], {
693
+ extrapolateRight: "clamp",
694
+ easing: Easing["in"](Easing.quad)
695
+ });
696
+
697
+ // Broll video transitions (start offscreen and move into position)
698
+ var brollVideoWidthTransition = useTimeInterpolate(transitionTimings, [0, brollVideoWidth, brollVideoWidth, 0], {
699
+ extrapolateRight: "clamp",
700
+ easing: Easing["in"](Easing.quad)
701
+ });
702
+ var brollVideoHeightTransition = useTimeInterpolate(transitionTimings, [0, brollVideoHeight, brollVideoHeight, 0], {
703
+ extrapolateRight: "clamp",
704
+ easing: Easing["in"](Easing.quad)
705
+ });
706
+ var brollVideoTopTransition = useTimeInterpolate(transitionTimings, orientation === "portrait" ? [-brollVideoHeight, brollVideoTop, brollVideoTop, -brollVideoHeight] : [0, brollVideoTop, brollVideoTop, 0], {
707
+ extrapolateRight: "clamp",
708
+ easing: Easing["in"](Easing.quad)
709
+ });
710
+ var brollVideoLeftTransition = useTimeInterpolate(transitionTimings, orientation === "portrait" ? [width / 2 - brollVideoWidth / 2, brollVideoLeft, brollVideoLeft, width / 2 - brollVideoWidth / 2] : [0, brollVideoLeft, brollVideoLeft, 0], {
711
+ extrapolateRight: "clamp",
712
+ easing: Easing["in"](Easing.quad)
713
+ });
714
+ return /*#__PURE__*/React.createElement(React.Fragment, null, !disableTransitionSounds && /*#__PURE__*/React.createElement(Audio, {
715
+ src: "https://cdn.zync.ai/assets/static/swoosh.mp3",
716
+ volume: 0.25
717
+ }), /*#__PURE__*/React.createElement(BrollGreenScreenComponent, {
718
+ brollUrl: brollUrl,
719
+ brollVideoWidthTransition: brollVideoWidthTransition,
720
+ brollVideoHeightTransition: brollVideoHeightTransition,
721
+ brollVideoTopTransition: brollVideoTopTransition,
722
+ brollVideoLeftTransition: brollVideoLeftTransition,
723
+ mainVideoWidthTransition: mainVideoWidthTransition,
724
+ mainVideoHeightTransition: mainVideoHeightTransition,
725
+ mainVideoTopTransition: mainVideoTopTransition,
726
+ mainVideoLeftTransition: mainVideoLeftTransition,
727
+ logoUrl: logoUrl,
728
+ frameColor: frameColor,
729
+ orientation: orientation,
730
+ startVideoFrom: startVideoFrom,
731
+ noBackgroundVideoUrl: noBackgroundVideoUrl,
732
+ sourceVideoOrientation: sourceVideoOrientation,
733
+ logoLeft: logoLeft,
734
+ logoTop: logoTop,
735
+ videoUrl: videoUrl,
736
+ faceMetadata: faceMetadata,
737
+ noBackgroundVideoEffects: noBackgroundVideoEffects,
738
+ showVirtual: showVirtual,
739
+ virtualBgUrl: virtualBgUrl
740
+ }, children));
741
+ };
742
+ export { BrollGreenScreen };