๋ฒ๊ทธ ์ค๋ช
ํ๋ ์ด์ด๋ฅผ ์ด ๋๋ง๋ค ์ฝ์์ ๋ค์๊ณผ ๊ฐ์ ์ค๋ฅ๊ฐ ์ธ์๋์์ต๋๋ค.
2021-06-30 09:24:44.141532+0200 Media Creations[39379:12785401] [ProcessSuspension] 0x10c4dd0b0 - ProcessAssertion: Failed to acquire RBS MediaPlayback assertion 'WebKit Media Playback' for process with PID 39379, error: Error Domain=RBSAssertionErrorDomain Code=3 "Required client entitlement is missing" UserInfo={RBSAssertionAttribute=<RBSDomainAttribute| domain:"com.apple.webkit" name:"MediaPlayback" sourceEnvironment:"(null)">, NSLocalizedFailureReason=Required client entitlement is missing}
๋ด YoutubePlayerController๋ ๋ค์๊ณผ ๊ฐ์ต๋๋ค.
final YoutubePlayerController _controller = YoutubePlayerController(
initialVideoId: videoId,
flags: YoutubePlayerFlags(
enableCaption: false,
hideThumbnail: true,
forceHD: true,
autoPlay: false,
startAt: startAt,
),
);
์ฌํํ๊ธฐ ์ํด
IOS์์ YoutubePlayerFlutter ์ด๊ธฐ
์์๋๋ ํ๋
์ค๋ฅ ์์ด ํ๋ ์ด์ด๋ฅผ ์ฝ๋๋ค.
์คํฌ๋ฆฐ์ท
ํด๋นํ๋ ๊ฒฝ์ฐ ๋ฌธ์ ๋ฅผ ์ค๋ช
ํ๋ ๋ฐ ๋์์ด ๋๋ ์คํฌ๋ฆฐ์ท์ ์ถ๊ฐํ์ธ์.
๊ธฐ์ ์ ์ธ๋ถ ์ฌํญ:
์ถ๊ฐ ์ปจํ
์คํธ
๋ด YoutubePlayer ์ฝ๋๋ ๋ค์๊ณผ ๊ฐ์ต๋๋ค.
return OrientationBuilder(
builder: (_, __) => YoutubePlayer(
key: UniqueKey(),
showVideoProgressIndicator: true,
onReady: _controller.play,
controller: _controller,
controlsTimeOut: const Duration(seconds: 2),
actionsPadding: const EdgeInsets.only(bottom: 10),
progressIndicatorColor: _theme.primaryColor,
onEnded: (_) => _controller.pause(),
bottomActions: [
Padding(
padding: const EdgeInsets.only(
left: VideoFullScreenButton.paddingSize +
VideoFullScreenButton.size * 2,
right: VideoFullScreenButton.paddingSize,
),
child: CurrentPosition(),
),
ProgressBar(
colors: ProgressBarColors(
playedColor: _theme.primaryColor,
handleColor: _theme.primaryColor,
),
isExpanded: true,
),
GestureDetector(
onTap: () => launch(
Strings.youtubeUrlFromId(
videoId,
seconds: _controller.value.position.inSeconds,
),
),
child: const Padding(
padding: EdgeInsets.only(
left: VideoFullScreenButton.paddingSize,
right: VideoFullScreenButton.paddingSize,
),
child: FaIcon(
FontAwesomeIcons.externalLinkAlt,
color: Colors.white,
size: VideoFullScreenButton.size,
),
),
),
VideoFullScreenButton(
preloadedFullScreen: isFullScreen,
key: UniqueKey(),
onTap: (isFullScreen) => _onVideoFullScreenTap(
isFullScreen,
context,
_controller,
),
),
],
),
);
๋ด ํ๋ก์ ํธ์ ๋๋ฝ๋ ๊ฒ์ด ์์ต๋๊น? ๋ฌธ์ํ์๋ฉด ๋ฐ๋ก ๋ต๋ณ๋๋ฆฌ๊ฒ ์ต๋๋ค.
๋๋ ๊ฐ์ ๋ฌธ์ ๋ฅผ ๊ฐ์ง๊ณ ์๋ค
์ด ๊ฒฝ๊ณ ๋ Info.plist๋ฅผ ์ฐธ์กฐํฉ๋๊น?
@PcolBP ํด๊ฒฐ์ฑ ์ ์ฐพ์์ต๋๊น?
๋ถํํ๋ YoutubePlayerFlutter์๋ ์์ต๋๋ค. ํด๋น ํ๋ก์ ํธ์ ๊ฒฝ์ฐ YoutubePlayerFlutter์ ๋นํด ๋ ๋์ ์ฑ๋ฅ์ ์ ๊ณตํ๊ณ ๊ทธ ์ดํ๋ก ์ค๋ฅ๊ฐ ์ธ์๋์ง ์๊ธฐ ๋๋ฌธ์ YoutubePlayerIframe์ผ๋ก ์ ํํ์ต๋๋ค.
๊ฐ์ฅ ์ ์ฉํ ๋๊ธ
๋๋ ๊ฐ์ ๋ฌธ์ ๋ฅผ ๊ฐ์ง๊ณ ์๋ค