Commit b4acb77c authored by Hanruisong's avatar Hanruisong
Browse files

feat: 更新到 4.14.2

1.新增真机架构SDK。
parent 5aafef39
...@@ -407,23 +407,23 @@ ...@@ -407,23 +407,23 @@
DD54280B250B55AB0097614C /* icon_ad_mute@3x.png in Resources */ = {isa = PBXBuildFile; fileRef = DD542807250B55AB0097614C /* icon_ad_mute@3x.png */; }; DD54280B250B55AB0097614C /* icon_ad_mute@3x.png in Resources */ = {isa = PBXBuildFile; fileRef = DD542807250B55AB0097614C /* icon_ad_mute@3x.png */; };
DD54280C250B55AB0097614C /* icon_ad_mute@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = DD542808250B55AB0097614C /* icon_ad_mute@2x.png */; }; DD54280C250B55AB0097614C /* icon_ad_mute@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = DD542808250B55AB0097614C /* icon_ad_mute@2x.png */; };
DD54280D250B55AB0097614C /* icon_ad_mute_select@3x.png in Resources */ = {isa = PBXBuildFile; fileRef = DD542809250B55AB0097614C /* icon_ad_mute_select@3x.png */; }; DD54280D250B55AB0097614C /* icon_ad_mute_select@3x.png in Resources */ = {isa = PBXBuildFile; fileRef = DD542809250B55AB0097614C /* icon_ad_mute_select@3x.png */; };
DDCB1667260C5E690095BBD8 /* CCVodSDK.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DDCB1663260C5E620095BBD8 /* CCVodSDK.framework */; }; DD90602D2611DE4E0005D270 /* HDBaseUtils.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DD90602A2611DE460005D270 /* HDBaseUtils.framework */; };
DDCB1668260C5E690095BBD8 /* CCVodSDK.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = DDCB1663260C5E620095BBD8 /* CCVodSDK.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; DD90602E2611DE4E0005D270 /* HDBaseUtils.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = DD90602A2611DE460005D270 /* HDBaseUtils.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
DDCB166A260C5E6B0095BBD8 /* HDBaseUtils.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DDCB1664260C5E620095BBD8 /* HDBaseUtils.framework */; }; DD90602F2611DE510005D270 /* CCVodSDK.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DD9060292611DE460005D270 /* CCVodSDK.framework */; };
DDCB166B260C5E6B0095BBD8 /* HDBaseUtils.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = DDCB1664260C5E620095BBD8 /* HDBaseUtils.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; DD9060302611DE510005D270 /* CCVodSDK.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = DD9060292611DE460005D270 /* CCVodSDK.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
DDCB166E260C5E7A0095BBD8 /* vrlibraw.bundle in Resources */ = {isa = PBXBuildFile; fileRef = DDCB166C260C5E790095BBD8 /* vrlibraw.bundle */; }; DD9060332611DE5F0005D270 /* DWResource.bundle in Resources */ = {isa = PBXBuildFile; fileRef = DD9060312611DE5E0005D270 /* DWResource.bundle */; };
DDCB166F260C5E7A0095BBD8 /* DWResource.bundle in Resources */ = {isa = PBXBuildFile; fileRef = DDCB166D260C5E790095BBD8 /* DWResource.bundle */; }; DD9060342611DE5F0005D270 /* vrlibraw.bundle in Resources */ = {isa = PBXBuildFile; fileRef = DD9060322611DE5F0005D270 /* vrlibraw.bundle */; };
/* End PBXBuildFile section */ /* End PBXBuildFile section */
/* Begin PBXCopyFilesBuildPhase section */ /* Begin PBXCopyFilesBuildPhase section */
DDCB1669260C5E690095BBD8 /* Embed Frameworks */ = { DD0F24D3255E22B000DA2705 /* Embed Frameworks */ = {
isa = PBXCopyFilesBuildPhase; isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
dstPath = ""; dstPath = "";
dstSubfolderSpec = 10; dstSubfolderSpec = 10;
files = ( files = (
DDCB1668260C5E690095BBD8 /* CCVodSDK.framework in Embed Frameworks */, DD90602E2611DE4E0005D270 /* HDBaseUtils.framework in Embed Frameworks */,
DDCB166B260C5E6B0095BBD8 /* HDBaseUtils.framework in Embed Frameworks */, DD9060302611DE510005D270 /* CCVodSDK.framework in Embed Frameworks */,
); );
name = "Embed Frameworks"; name = "Embed Frameworks";
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
...@@ -993,10 +993,10 @@ ...@@ -993,10 +993,10 @@
DD542807250B55AB0097614C /* icon_ad_mute@3x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "icon_ad_mute@3x.png"; sourceTree = "<group>"; }; DD542807250B55AB0097614C /* icon_ad_mute@3x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "icon_ad_mute@3x.png"; sourceTree = "<group>"; };
DD542808250B55AB0097614C /* icon_ad_mute@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "icon_ad_mute@2x.png"; sourceTree = "<group>"; }; DD542808250B55AB0097614C /* icon_ad_mute@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "icon_ad_mute@2x.png"; sourceTree = "<group>"; };
DD542809250B55AB0097614C /* icon_ad_mute_select@3x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "icon_ad_mute_select@3x.png"; sourceTree = "<group>"; }; DD542809250B55AB0097614C /* icon_ad_mute_select@3x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "icon_ad_mute_select@3x.png"; sourceTree = "<group>"; };
DDCB1663260C5E620095BBD8 /* CCVodSDK.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = CCVodSDK.framework; sourceTree = "<group>"; }; DD9060292611DE460005D270 /* CCVodSDK.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = CCVodSDK.framework; sourceTree = "<group>"; };
DDCB1664260C5E620095BBD8 /* HDBaseUtils.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = HDBaseUtils.framework; sourceTree = "<group>"; }; DD90602A2611DE460005D270 /* HDBaseUtils.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = HDBaseUtils.framework; sourceTree = "<group>"; };
DDCB166C260C5E790095BBD8 /* vrlibraw.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; name = vrlibraw.bundle; path = CCVodSDK.framework/vrlibraw.bundle; sourceTree = "<group>"; }; DD9060312611DE5E0005D270 /* DWResource.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; name = DWResource.bundle; path = CCVodSDK.framework/DWResource.bundle; sourceTree = "<group>"; };
DDCB166D260C5E790095BBD8 /* DWResource.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; name = DWResource.bundle; path = CCVodSDK.framework/DWResource.bundle; sourceTree = "<group>"; }; DD9060322611DE5F0005D270 /* vrlibraw.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; name = vrlibraw.bundle; path = CCVodSDK.framework/vrlibraw.bundle; sourceTree = "<group>"; };
DDF1A579255E8A52007EE8B9 /* MobileCoreServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MobileCoreServices.framework; path = System/Library/Frameworks/MobileCoreServices.framework; sourceTree = SDKROOT; }; DDF1A579255E8A52007EE8B9 /* MobileCoreServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MobileCoreServices.framework; path = System/Library/Frameworks/MobileCoreServices.framework; sourceTree = SDKROOT; };
/* End PBXFileReference section */ /* End PBXFileReference section */
...@@ -1005,14 +1005,14 @@ ...@@ -1005,14 +1005,14 @@
isa = PBXFrameworksBuildPhase; isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
files = ( files = (
DDCB166A260C5E6B0095BBD8 /* HDBaseUtils.framework in Frameworks */, DD90602D2611DE4E0005D270 /* HDBaseUtils.framework in Frameworks */,
048AD12822CDCE83008C8911 /* libxml2.tbd in Frameworks */, 048AD12822CDCE83008C8911 /* libxml2.tbd in Frameworks */,
043441FF225EF2BB003F7EC1 /* CoreServices.framework in Frameworks */, 043441FF225EF2BB003F7EC1 /* CoreServices.framework in Frameworks */,
352CBDD91FD6980C00D24715 /* AudioToolbox.framework in Frameworks */, 352CBDD91FD6980C00D24715 /* AudioToolbox.framework in Frameworks */,
352CBDD71FD697E800D24715 /* MediaPlayer.framework in Frameworks */, 352CBDD71FD697E800D24715 /* MediaPlayer.framework in Frameworks */,
B88562A41DED1AC8008D1763 /* SystemConfiguration.framework in Frameworks */, B88562A41DED1AC8008D1763 /* SystemConfiguration.framework in Frameworks */,
B57CC7C018E2E581001A1696 /* AVFoundation.framework in Frameworks */, B57CC7C018E2E581001A1696 /* AVFoundation.framework in Frameworks */,
DDCB1667260C5E690095BBD8 /* CCVodSDK.framework in Frameworks */, DD90602F2611DE510005D270 /* CCVodSDK.framework in Frameworks */,
B57CC7BE18E2E575001A1696 /* CoreLocation.framework in Frameworks */, B57CC7BE18E2E575001A1696 /* CoreLocation.framework in Frameworks */,
B57CC7BC18E2E569001A1696 /* CoreMedia.framework in Frameworks */, B57CC7BC18E2E569001A1696 /* CoreMedia.framework in Frameworks */,
B547EC4C18E033FB00BC980C /* CoreGraphics.framework in Frameworks */, B547EC4C18E033FB00BC980C /* CoreGraphics.framework in Frameworks */,
...@@ -1847,7 +1847,7 @@ ...@@ -1847,7 +1847,7 @@
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
044C66A122D46DAE0032396F /* Demo.entitlements */, 044C66A122D46DAE0032396F /* Demo.entitlements */,
DDCB1662260C5E620095BBD8 /* SDK */, DD9060282611DE460005D270 /* SDK */,
0434420D225F0EDD003F7EC1 /* Classes */, 0434420D225F0EDD003F7EC1 /* Classes */,
B547EC5818E033FB00BC980C /* DWAppDelegate.h */, B547EC5818E033FB00BC980C /* DWAppDelegate.h */,
B547EC5918E033FB00BC980C /* DWAppDelegate.m */, B547EC5918E033FB00BC980C /* DWAppDelegate.m */,
...@@ -1874,13 +1874,13 @@ ...@@ -1874,13 +1874,13 @@
name = "Supporting Files"; name = "Supporting Files";
sourceTree = "<group>"; sourceTree = "<group>";
}; };
DDCB1662260C5E620095BBD8 /* SDK */ = { DD9060282611DE460005D270 /* SDK */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
DDCB166D260C5E790095BBD8 /* DWResource.bundle */, DD9060312611DE5E0005D270 /* DWResource.bundle */,
DDCB166C260C5E790095BBD8 /* vrlibraw.bundle */, DD9060322611DE5F0005D270 /* vrlibraw.bundle */,
DDCB1663260C5E620095BBD8 /* CCVodSDK.framework */, DD9060292611DE460005D270 /* CCVodSDK.framework */,
DDCB1664260C5E620095BBD8 /* HDBaseUtils.framework */, DD90602A2611DE460005D270 /* HDBaseUtils.framework */,
); );
path = SDK; path = SDK;
sourceTree = "<group>"; sourceTree = "<group>";
...@@ -1895,8 +1895,8 @@ ...@@ -1895,8 +1895,8 @@
B547EC4218E033FB00BC980C /* Sources */, B547EC4218E033FB00BC980C /* Sources */,
B547EC4318E033FB00BC980C /* Frameworks */, B547EC4318E033FB00BC980C /* Frameworks */,
B547EC4418E033FB00BC980C /* Resources */, B547EC4418E033FB00BC980C /* Resources */,
DDCB1669260C5E690095BBD8 /* Embed Frameworks */, DD0F24D3255E22B000DA2705 /* Embed Frameworks */,
DDCB1670260C5E9D0095BBD8 /* ShellScript */, DD9060352611DE780005D270 /* ShellScript */,
); );
buildRules = ( buildRules = (
); );
...@@ -2026,7 +2026,6 @@ ...@@ -2026,7 +2026,6 @@
0491DCF824B5604300DF40C7 /* icon_barrage_close@3x.png in Resources */, 0491DCF824B5604300DF40C7 /* icon_barrage_close@3x.png in Resources */,
0491DD2424B5604300DF40C7 /* icon_barrage_color_01@2x.png in Resources */, 0491DD2424B5604300DF40C7 /* icon_barrage_color_01@2x.png in Resources */,
04FFA9EA22647579008C2713 /* icon_play_full@2x.png in Resources */, 04FFA9EA22647579008C2713 /* icon_play_full@2x.png in Resources */,
DDCB166E260C5E7A0095BBD8 /* vrlibraw.bundle in Resources */,
DD54280C250B55AB0097614C /* icon_ad_mute@2x.png in Resources */, DD54280C250B55AB0097614C /* icon_ad_mute@2x.png in Resources */,
0491DCF224B5604300DF40C7 /* icon_barrage_set_return@3x.png in Resources */, 0491DCF224B5604300DF40C7 /* icon_barrage_set_return@3x.png in Resources */,
0491DD0F24B5604300DF40C7 /* icon_barrage_color_05@3x.png in Resources */, 0491DD0F24B5604300DF40C7 /* icon_barrage_color_05@3x.png in Resources */,
...@@ -2057,6 +2056,7 @@ ...@@ -2057,6 +2056,7 @@
04AB4A3722B1F22A00BB9BF9 /* icon_exercises_error@2x.png in Resources */, 04AB4A3722B1F22A00BB9BF9 /* icon_exercises_error@2x.png in Resources */,
04D60ED822719B9C0009C572 /* icon_play_vr_inselect_select@2x.png in Resources */, 04D60ED822719B9C0009C572 /* icon_play_vr_inselect_select@2x.png in Resources */,
043D4E6B22D5C91D00FCDCBE /* icon_sound_add@2x.png in Resources */, 043D4E6B22D5C91D00FCDCBE /* icon_sound_add@2x.png in Resources */,
DD9060332611DE5F0005D270 /* DWResource.bundle in Resources */,
04346AC8249720C6005A3396 /* icon_screenshot@2x.png in Resources */, 04346AC8249720C6005A3396 /* icon_screenshot@2x.png in Resources */,
04B7A661226B0E5E00951983 /* icon_question_multi_select@3x.png in Resources */, 04B7A661226B0E5E00951983 /* icon_question_multi_select@3x.png in Resources */,
04AB4A3F22B1F22A00BB9BF9 /* icon_exercises_answer_d_select@2x.png in Resources */, 04AB4A3F22B1F22A00BB9BF9 /* icon_exercises_answer_d_select@2x.png in Resources */,
...@@ -2090,7 +2090,6 @@ ...@@ -2090,7 +2090,6 @@
0414B00623F51AA0002C7F7D /* icon_pip@2x.png in Resources */, 0414B00623F51AA0002C7F7D /* icon_pip@2x.png in Resources */,
04FFA9F822647C84008C2713 /* icon_play_gif_normal@3x.png in Resources */, 04FFA9F822647C84008C2713 /* icon_play_gif_normal@3x.png in Resources */,
04F0B79F22602D8F0097C3CB /* icon_return_black@2x.png in Resources */, 04F0B79F22602D8F0097C3CB /* icon_return_black@2x.png in Resources */,
DDCB166F260C5E7A0095BBD8 /* DWResource.bundle in Resources */,
043D018722B76F1C008589DA /* icon_exercises_statistics_error@3x.png in Resources */, 043D018722B76F1C008589DA /* icon_exercises_statistics_error@3x.png in Resources */,
0491DD0124B5604300DF40C7 /* icon_barrage_set_normal@2x.png in Resources */, 0491DD0124B5604300DF40C7 /* icon_barrage_set_normal@2x.png in Resources */,
04FFA9D622647579008C2713 /* icon_play_return@3x.png in Resources */, 04FFA9D622647579008C2713 /* icon_play_return@3x.png in Resources */,
...@@ -2155,6 +2154,7 @@ ...@@ -2155,6 +2154,7 @@
04346AC0249720C6005A3396 /* brightness.png in Resources */, 04346AC0249720C6005A3396 /* brightness.png in Resources */,
04B7A65F226B0E5E00951983 /* icon_question_single_select@2x.png in Resources */, 04B7A65F226B0E5E00951983 /* icon_question_single_select@2x.png in Resources */,
0491DD1F24B5604300DF40C7 /* icon_barrage_color_select@3x.png in Resources */, 0491DD1F24B5604300DF40C7 /* icon_barrage_color_select@3x.png in Resources */,
DD9060342611DE5F0005D270 /* vrlibraw.bundle in Resources */,
04BAA93D22D4787B000495B4 /* icon_screen_list@2x.png in Resources */, 04BAA93D22D4787B000495B4 /* icon_screen_list@2x.png in Resources */,
04AB4A2622B1F22A00BB9BF9 /* icon_exercises_answer_g_normal@2x.png in Resources */, 04AB4A2622B1F22A00BB9BF9 /* icon_exercises_answer_g_normal@2x.png in Resources */,
04B7A65C226B0E5E00951983 /* icon_question_multi_select@2x.png in Resources */, 04B7A65C226B0E5E00951983 /* icon_question_multi_select@2x.png in Resources */,
...@@ -2204,7 +2204,7 @@ ...@@ -2204,7 +2204,7 @@
/* End PBXResourcesBuildPhase section */ /* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */ /* Begin PBXShellScriptBuildPhase section */
DDCB1670260C5E9D0095BBD8 /* ShellScript */ = { DD9060352611DE780005D270 /* ShellScript */ = {
isa = PBXShellScriptBuildPhase; isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
files = ( files = (
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
self.DWAccount_userId = @"391E6E3340A00767"; self.DWAccount_userId = @"391E6E3340A00767";
self.DWAccount_apikey = @"T8WdOUuvFEiOsou1xjDr4U73v12M7iNa"; self.DWAccount_apikey = @"T8WdOUuvFEiOsou1xjDr4U73v12M7iNa";
self.isOpenAd = [[[NSUserDefaults standardUserDefaults] objectForKey:@"isOpenAD"] boolValue]; self.isOpenAd = [[[NSUserDefaults standardUserDefaults] objectForKey:@"isOpenAD"] boolValue];
} }
return self; return self;
......
//版本号 //版本号
#define SDK_VERSION @"4.14.1" #define SDK_VERSION @"4.14.2"
#import <CCVodSDK/DWGIFManager.h> #import <CCVodSDK/DWGIFManager.h>
#import <CCVodSDK/DWAdInfo.h> #import <CCVodSDK/DWAdInfo.h>
......
File mode changed from 100755 to 100644
File mode changed from 100755 to 100644
...@@ -17,7 +17,7 @@ FOUNDATION_EXPORT const unsigned char HDBaseUtilsVersionString[]; ...@@ -17,7 +17,7 @@ FOUNDATION_EXPORT const unsigned char HDBaseUtilsVersionString[];
// In this header, you should import all the public headers of your framework using statements like #import <HDBaseUtils/PublicHeader.h> // In this header, you should import all the public headers of your framework using statements like #import <HDBaseUtils/PublicHeader.h>
//base库版本号 //base库版本号
#define HDBASESDK_VERSION @"1.0.9" #define HDBASESDK_VERSION @"1.0.10"
#import <HDBaseUtils/HDUniversalUtils.h> #import <HDBaseUtils/HDUniversalUtils.h>
......
File mode changed from 100755 to 100644
File mode changed from 100755 to 100644
File mode changed from 100755 to 100644
File mode changed from 100755 to 100644
File mode changed from 100755 to 100644
...@@ -1911,6 +1911,6 @@ footer.ty-footer { ...@@ -1911,6 +1911,6 @@ footer.ty-footer {
</head> </head>
<body class='typora-export' > <body class='typora-export' >
<div id='write' class = ''><h1><a name="集成指南" class="md-header-anchor"></a><span>集成指南</span></h1><h2><a name="1sdk集成" class="md-header-anchor"></a><span>1.SDK集成</span></h2><p><span>注意:为了更好的使用我们的产品,4.8.0版本以后,我们将SDK更改为framework类型,如升级遇到编译报错,打包上架报错等问题,请详见6.常见问题。</span></p><h3><a name="11-方法1cocoapods导入" class="md-header-anchor"></a><span>1.1 方法1:Cocoapods导入 </span></h3><p><span>执行 </span><code>pod search &#39;CCVodSDK&#39;</code></p><p><span>Podfile 文件中增加如下代码:</span> <div id='write' class = ''><h1><a name="集成指南" class="md-header-anchor"></a><span>集成指南</span></h1><h2><a name="1sdk集成" class="md-header-anchor"></a><span>1.SDK集成</span></h2><p><span>注意:为了更好的使用我们的产品,4.8.0版本以后,我们将SDK更改为framework类型,如升级遇到编译报错,打包上架报错等问题,请详见6.常见问题。</span></p><h3><a name="11-方法1cocoapods导入" class="md-header-anchor"></a><span>1.1 方法1:Cocoapods导入 </span></h3><p><span>执行 </span><code>pod search &#39;CCVodSDK&#39;</code></p><p><span>Podfile 文件中增加如下代码:</span>
<code>pod &#39;CCVodSDK&#39;</code></p><p><span>执行</span><code>pod install</code><span> 即可。</span></p><p><span>如果没有安装cocoapods,请执行 </span><code>sudo gem install cocoapods</code><span>命令,安装cocoapods。</span></p><p><span>如果搜索不到,请执行下述命令清除搜索列表缓存 </span><code>rm ~/Library/Caches/CocoaPods/search_index.json</code><span>,之后再调用search命令搜索。</span></p><h3><a name="12-方法2手动导入sdk" class="md-header-anchor"></a><span>1.2 方法2:手动导入SDK</span></h3><p><span>下载iOS_SDK_Demo,将项目中的SDK(或外级目录下的include文件夹导入项目),选择</span><code>Copy items if needed</code><span>,Finish,导入即可。</span></p><p><span>SDK依赖的系统库如下</span></p><ul><li><span>Foundation.framework</span></li><li><span>UIKit.framework</span></li><li><span>OpenGLES.framework</span></li><li><span>CoreMotion.framework</span></li><li><span>CoreVideo.framework</span></li><li><span>AVFoundation.framework</span></li><li><span>Security.framework</span></li><li><span>ImageIO.framework</span></li><li><span>AudioToolbox.framework</span></li><li><span>MobileCoreServices.framework</span></li><li><span>CoreMedia.framework</span></li></ul><p><span>项目 - TARGETS - Build Settings所有Other Linker Flags,添加-lxml2。</span></p><p><span>项目 - TARGETS - General - Frameworks.Libraries,and Embedded Content - 找到HDBaseUtils.framework、CCVodSDK.framework,将默认Do Not Embed修改为Embed &amp; Sign。</span></p><p><span>如果使用了DWPlayerSkinView和VR相关的功能,需要添加CCVodSDK.framework中的DWResource.bundle,vrlibraw.bundle,否则资源文件不能正常显示。添加方法:选中工程名,在右键菜单中选择Add Files to “工程名”…,从CCVodSDK.framework文件中选择DWResource.bundle,vrlibraw.bundle文件,并勾选“Copy items if needed”复选框,单击“Add”按钮,将资源文件添加到工程中。</span></p><h2><a name="2sdk-demo项目结构" class="md-header-anchor"></a><span>2.SDK demo项目结构</span></h2><figure><table><thead><tr><th><span>名称</span></th><th style='text-align:center;' ><span>描述</span></th></tr></thead><tbody><tr><td><span>Demo</span></td><td style='text-align:center;' ><span>iOS_SDK_Demo源码</span></td></tr><tr><td><span>doc</span></td><td style='text-align:center;' ><span>iOS点播SDK开发指南及离线API</span></td></tr><tr><td><span>include</span></td><td style='text-align:center;' ><span>SDK开放的头文件及静态库,同demo中的SDK文件夹</span></td></tr></tbody></table></figure><p><span>以下是iOS_SDK_Demo中,主要的目录结构及说明:</span></p><blockquote><p><span>Demo</span></p></blockquote><blockquote><blockquote><p><span>DWAppDelegate.h/m </span></p></blockquote></blockquote><blockquote><blockquote><p><span>DWConfigurationManager.h/m (Demo app的一些全局配置设置)</span></p></blockquote></blockquote><blockquote><blockquote><p><span>SDK (iOS点播SDK)</span></p></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>CCVodSDK.h (SDK头文件)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWPlayInfo.h (负责获取音视频对象数据)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWVodVideoModel.h (音视频model)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWVodAdInfoModel.h (广告model)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWPlayerView.h (继承自UIView,负责媒体播放,此类并不带播放相关UI,播放控制需自己实现)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWPlayerSkinView.h (带播放控制的PlayerView)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWDownloadSessionManager.h (下载管理中心,音视频下载功能通过此类来实现)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWDownloadModel.h (下载model)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWBatchDownloadUtility.h (批量下载功能,可以通过videos,批量来获取视频的下载链接)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWUploader.h (视频上传器)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWVideoCompressController.h (媒体选择页面,可以设置一些媒体压缩格式)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>... (其他相关类,请详见demo)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><p><span>Classes (Demo app 项目的主要类)</span></p></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWMainViewController.h/m (首页)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWVodPlayViewController.h/m (在线视频播放页)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWVodPlayerSkinViewController.h/m (视频播放页,SDK中自带皮肤的播放控制页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWDownloadManagerViewController.h/m (下载管理页)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWLocalPlayViewController.h/m (本地视频播放页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWUploadViewController.h/m (上传管理页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWUploadInfoSetupViewController.h/m (上传设置页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWMemberViewController.h/m (app相关配置页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWNetworkMonitorViewController.h/m (网络检测页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>Base (demo app基类文件夹)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>DWNavigationViewController.h/m</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>DWBaseViewController.h/m</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>Model(demo app Model文件夹)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>DWVodModel (demo中,媒体对象model)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>DWTableChooseModel </span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>DWUploadModel</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>CustomDirectorFactory</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>View (demo app View文件夹,包含点播demo主要的功能。具体内部类比较繁多,这里就不一一列举了,详见demo)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Main </span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Player (视频播放相关的view)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>VideoMark (视频打点)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Question (视频问答)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>SubTitle (视频字幕)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Authorize (授权验证)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Gif(GIF录制)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Visitor(访客信息收集器)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Exercises(课堂练习)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Ad (广告)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Download (下载)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Upload (上传)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>ProjectionScreen(视频投屏)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Barrage(视频弹幕)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Others (其余使用到的类)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>... (额外的其他功能,这里就不一一列举了)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><p><span>Plugins (工具类)</span></p></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>Tools (Demo中使用的一些通用方法)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>OCBarrage (视频弹幕控件)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>SDWebImage</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>MJExtension</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>Masonry</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>MBProgressHUD</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><p><span>Images (图片资源)</span></p></blockquote></blockquote><h2><a name="3快速集成" class="md-header-anchor"></a><span>3.快速集成</span></h2><p><span>注:快速集成主要提供的是视频播放、下载、上传功能等核心功能的使用方式。</span></p><h3><a name="31-视频播放功能" class="md-header-anchor"></a><span>3.1 视频播放功能</span></h3><h4><a name="311-在合适的位置设置audiosession" class="md-header-anchor"></a><span>3.1.1 在合适的位置设置AudioSession </span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang="" style="break-inside: unset;"><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">{ </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //设置全局AVAudioSession</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; NSError *categoryError = nil;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; BOOL success = [[AVAudioSession sharedInstance] setCategory:AVAudioSessionCategoryPlayback error:&amp;categoryError];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; if (!success)</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; NSLog(@"Error setting audio session category: %@", categoryError);</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; }</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; NSError *activeError = nil;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; success = [[AVAudioSession sharedInstance] setActive:YES error:&amp;activeError];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; if (!success)</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; NSLog(@"Error setting audio session active: %@", activeError);</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; }</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> }</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 468px;"></div><div class="CodeMirror-gutters" style="display: none; height: 468px;"></div></div></div></pre><h4><a name="312-通过获得场景账号useridapikeyvideoid来获取dwvodvideomodel对象无获得场景账号点击注册httpsadminbokecccomloginbo" class="md-header-anchor"></a><span>3.1.2 通过获得场景账号UserID、APIKey、VideoId,来获取DWVodVideoModel对象。无获得场景账号?</span><a href='https://admin.bokecc.com/login.bo'><span>点击注册</span></a></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang="" style="break-inside: unset;"><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; DWPlayInfo * playInfo = [[DWPlayInfo alloc]initWithUserId:@"账号ID" andVideoId:@"视频ID" key:@"APIKey" hlsSupport:@"1"];</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.timeoutSeconds = 30;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.mediatype = @"1";</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.verificationCode = @"授权验证码,没有此功能不需要设置";</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.roleId = @"客户端用户id,选填";</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.finishBlock = ^(DWVodVideoModel *vodVideo) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //成功回调</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; NSLog(@"%@",vodVideo);</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; };</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.errorBlock = ^(NSError *error) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //失败回调 &nbsp; &nbsp; &nbsp; </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; };</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; [playInfo start];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 390px;"></div><div class="CodeMirror-gutters" style="display: none; height: 390px;"></div></div></div></pre><h4><a name="313-创建dwplayerview默认播放器dwplayerskinview带皮肤的播放器对象添加到视图中待获取到dwvodvideomodel对象后传入即可播放在线视频" class="md-header-anchor"></a><span>3.1.3 创建DWPlayerView(默认播放器)/DWPlayerSkinView(带皮肤的播放器)对象添加到视图中,待获取到DWVodVideoModel对象后传入,即可播放在线视频</span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang="" style="break-inside: unset;"><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //创建默认播放器对象</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; self.playerView = [[DWPlayerView alloc]init];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; [self addSubview:self.playerView];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //或者创建带皮肤的播放器对象</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; self.playerSkinView = [[DWPlayerSkinView alloc]initSkinView];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; [self addSubview: self.playerSkinView]; &nbsp; &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //等待DWPlayInfo获取到DWVodVideoModel对象</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.finishBlock = ^(DWVodVideoModel *vodVideo) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //成功回调</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //NSLog(@"%@",vodVideo);</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; [self.playerView playVodViedo:videoModel withCustomId:nil];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; [self.playerView play];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //或者</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //[self.playerSkinView playVodViedo:vodVideo];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; };</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; ...</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 520px;"></div><div class="CodeMirror-gutters" style="display: none; height: 520px;"></div></div></div></pre><h3><a name="32-下载功能" class="md-header-anchor"></a><span>3.2 下载功能</span></h3><h4><a name="321-通过获得场景账号useridapikeyvideoid来获取dwvodvideomodel对象" class="md-header-anchor"></a><span>3.2.1 通过获得场景账号UserID、APIKey、VideoId,来获取DWVodVideoModel对象</span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang=""><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation"><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> //获取方式与视频获取方式一样,只不过hlsSupport参数要传@"0" </span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; DWPlayInfo * playInfo = [[DWPlayInfo alloc]initWithUserId:@"账号ID" andVideoId:@"视频ID" key:@"APIKey" hlsSupport:@"0"];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> ...</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 130px;"></div><div class="CodeMirror-gutters" style="display: none; height: 130px;"></div></div></div></pre><h4><a name="322-获取dwdownloadsessionmanager单例对象创建dwdownloadmodel对象通过调用startwithdownloadmodel方法即可开始下载" class="md-header-anchor"></a><span>3.2.2 获取DWDownloadSessionManager单例对象,创建DWDownloadModel对象,通过调用startWithDownloadModel:方法即可开始下载</span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang="" style="break-inside: unset;"><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //等待DWPlayInfo获取到DWVodVideoModel对象</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.finishBlock = ^(DWVodVideoModel *vodVideo) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //成功回调</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //得到需要下载的清晰度model,数据</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //这里根据自身业务逻辑进行调整,这里下载的第一个视频</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; DWVideoQualityModel * qualityModel = [videoModel.qualities firstObject];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; DWDownloadSessionManager * manager = [DWDownloadSessionManager manager];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //验证当前任务是否已经在下载队列中</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; if ([manager checkLocalResourceWithVideoId:videoModel.videoId WithQuality:qualityModel.quality]) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; return;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; }</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //没有此任务,创建DWDownloadModel对象,开始下载 &nbsp; &nbsp; &nbsp; &nbsp; </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; DWDownloadModel * model = [DWDownloadSessionManager createDownloadModel:videoModel Quality:qualityModel.quality AndOthersInfo:nil];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; if (!model) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; //DownloadModel创建失败,请检查参数</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; return;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; }</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; [manager startWithDownloadModel:model]; &nbsp; &nbsp; &nbsp; &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; };</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 624px;"></div><div class="CodeMirror-gutters" style="display: none; height: 624px;"></div></div></div></pre><h3><a name="33-上传功能" class="md-header-anchor"></a><span>3.3 上传功能</span></h3><h4><a name="331-通过dwvideocompresscontroller选择要上传的视频" class="md-header-anchor"></a><span>3.3.1 通过DWVideoCompressController,选择要上传的视频</span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang=""><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation"><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; DWVideoCompressController *imagePicker = [[DWVideoCompressController alloc] initWithQuality: DWUIImagePickerControllerQualityTypeMedium andSourceType:DWUIImagePickerControllerSourceTypePhotoLibrary andMediaType:DWUIImagePickerControllerMediaTypeMovie];</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; imagePicker.delegate = self;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; [self presentViewController:imagePicker animated:NO completion:nil];</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 156px;"></div><div class="CodeMirror-gutters" style="display: none; height: 156px;"></div></div></div></pre><h4><a name="332-获取到本地视频路径通过dwuploadsessionmanager创建dwuploadmodel开始上传" class="md-header-anchor"></a><span>3.3.2 获取到本地视频路径,通过DWUploadSessionManager创建DWUploadModel,开始上传</span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm md-focus" lang=""><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //注意!获取到上传路径之后,请务必调用moveToLocalWithVideoPath:方法获取SDK所需的视频url,否则可能会出现上传失败,找不到视频文件等情况。</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; NSURL *videoURL = [info objectForKey:UIImagePickerControllerMediaURL];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //选中视频以后,请务必调用此方法,否则可能会出现上传失败,找不到视频文件等情况。</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; self.videoPath = [self.manager moveToLocalWithVideoPath:[videoURL path]];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //填写完视频信息以后,通过DWUploadSessionManager创建DWUploadModel。</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; DWUploadModel * uploadModel = [DWUploadSessionManager createUploadModelWithUserId:userId Apikey:apiKey VideoTitle:videoTitle VideoDescription:videoDescription VideoTag:videoTag VideoPath:self.videoPath CategoryId:nil NotifyURL:nil];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //DWUploadModel创建成功以后,调用startWithUploadModel:方法,即可开始上传视频</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; [self.manager startWithUploadModel:uploadModel];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 364px;"></div><div class="CodeMirror-gutters" style="display: none; height: 364px;"></div></div></div></pre></div> <code>pod &#39;CCVodSDK&#39;</code></p><p><span>执行</span><code>pod install</code><span> 即可。</span></p><p><span>如果没有安装cocoapods,请执行 </span><code>sudo gem install cocoapods</code><span>命令,安装cocoapods。</span></p><p><span>如果搜索不到,请执行下述命令清除搜索列表缓存 </span><code>rm ~/Library/Caches/CocoaPods/search_index.json</code><span>,之后再调用search命令搜索。</span></p><h3><a name="12-方法2手动导入sdk" class="md-header-anchor"></a><span>1.2 方法2:手动导入SDK</span></h3><p><span>下载iOS_SDK_Demo,将项目中的SDK(或外级目录下的include文件夹导入项目),选择</span><code>Copy items if needed</code><span>,Finish,导入即可。</span></p><p><span>SDK依赖的系统库如下</span></p><ul><li><span>Foundation.framework</span></li><li><span>UIKit.framework</span></li><li><span>OpenGLES.framework</span></li><li><span>CoreMotion.framework</span></li><li><span>CoreVideo.framework</span></li><li><span>AVFoundation.framework</span></li><li><span>Security.framework</span></li><li><span>ImageIO.framework</span></li><li><span>AudioToolbox.framework</span></li><li><span>MobileCoreServices.framework</span></li><li><span>CoreMedia.framework</span></li></ul><p><span>项目 - TARGETS - Build Settings所有Other Linker Flags,添加-lxml2。</span></p><p><span>项目 - TARGETS - General - Frameworks.Libraries,and Embedded Content - 找到HDBaseUtils.framework、CCVodSDK.framework,将默认Do Not Embed修改为Embed &amp; Sign。</span></p><p><span>如果使用了DWPlayerSkinView和VR相关的功能,需要添加CCVodSDK.framework中的DWResource.bundle,vrlibraw.bundle,否则资源文件不能正常显示。添加方法:选中工程名,在右键菜单中选择Add Files to “工程名”…,从CCVodSDK.framework文件中选择DWResource.bundle,vrlibraw.bundle文件,并勾选“Copy items if needed”复选框,单击“Add”按钮,将资源文件添加到工程中。</span></p><h2><a name="2sdk-demo项目结构" class="md-header-anchor"></a><span>2.SDK demo项目结构</span></h2><figure><table><thead><tr><th><span>名称</span></th><th style='text-align:center;' ><span>描述</span></th></tr></thead><tbody><tr><td><span>Demo</span></td><td style='text-align:center;' ><span>iOS_SDK_Demo源码</span></td></tr><tr><td><span>doc</span></td><td style='text-align:center;' ><span>iOS点播SDK开发指南及离线API</span></td></tr><tr><td><span>include</span></td><td style='text-align:center;' ><span>SDK开放的头文件及静态库,同demo中的SDK文件夹</span></td></tr></tbody></table></figure><p><span>以下是iOS_SDK_Demo中,主要的目录结构及说明:</span></p><blockquote><p><span>Demo</span></p></blockquote><blockquote><blockquote><p><span>DWAppDelegate.h/m </span></p></blockquote></blockquote><blockquote><blockquote><p><span>DWConfigurationManager.h/m (Demo app的一些全局配置设置)</span></p></blockquote></blockquote><blockquote><blockquote><p><span>SDK (iOS点播SDK)</span></p></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>CCVodSDK.h (SDK头文件)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWPlayInfo.h (负责获取音视频对象数据)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWVodVideoModel.h (音视频model)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWVodAdInfoModel.h (广告model)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWPlayerView.h (继承自UIView,负责媒体播放,此类并不带播放相关UI,播放控制需自己实现)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWPlayerSkinView.h (带播放控制的PlayerView)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWDownloadSessionManager.h (下载管理中心,音视频下载功能通过此类来实现)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWDownloadModel.h (下载model)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWBatchDownloadUtility.h (批量下载功能,可以通过videos,批量来获取视频的下载链接)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWUploader.h (视频上传器)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWVideoCompressController.h (媒体选择页面,可以设置一些媒体压缩格式)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>... (其他相关类,请详见demo)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><p><span>Classes (Demo app 项目的主要类)</span></p></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWMainViewController.h/m (首页)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWVodPlayViewController.h/m (在线视频播放页)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWVodPlayerSkinViewController.h/m (视频播放页,SDK中自带皮肤的播放控制页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWDownloadManagerViewController.h/m (下载管理页)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWLocalPlayViewController.h/m (本地视频播放页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWUploadViewController.h/m (上传管理页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWUploadInfoSetupViewController.h/m (上传设置页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWMemberViewController.h/m (app相关配置页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>DWNetworkMonitorViewController.h/m (网络检测页面)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>Base (demo app基类文件夹)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>DWNavigationViewController.h/m</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>DWBaseViewController.h/m</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>Model(demo app Model文件夹)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>DWVodModel (demo中,媒体对象model)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>DWTableChooseModel </span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>DWUploadModel</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>CustomDirectorFactory</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>View (demo app View文件夹,包含点播demo主要的功能。具体内部类比较繁多,这里就不一一列举了,详见demo)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Main </span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Player (视频播放相关的view)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>VideoMark (视频打点)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Question (视频问答)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>SubTitle (视频字幕)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Authorize (授权验证)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Gif(GIF录制)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Visitor(访客信息收集器)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Exercises(课堂练习)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Ad (广告)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Download (下载)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Upload (上传)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>ProjectionScreen(视频投屏)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Barrage(视频弹幕)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>Others (其余使用到的类)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><blockquote><p><span>... (额外的其他功能,这里就不一一列举了)</span></p></blockquote></blockquote></blockquote></blockquote><blockquote><blockquote><p><span>Plugins (工具类)</span></p></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>Tools (Demo中使用的一些通用方法)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>OCBarrage (视频弹幕控件)</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>SDWebImage</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>MJExtension</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>Masonry</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><blockquote><p><span>MBProgressHUD</span></p></blockquote></blockquote></blockquote><blockquote><blockquote><p><span>Images (图片资源)</span></p></blockquote></blockquote><h2><a name="3快速集成" class="md-header-anchor"></a><span>3.快速集成</span></h2><p><span>注:快速集成主要提供的是视频播放、下载、上传功能等核心功能的使用方式。</span></p><h3><a name="31-视频播放功能" class="md-header-anchor"></a><span>3.1 视频播放功能</span></h3><h4><a name="311-在合适的位置设置audiosession" class="md-header-anchor"></a><span>3.1.1 在合适的位置设置AudioSession </span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang="" style="break-inside: unset;"><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">{ </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //设置全局AVAudioSession</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; NSError *categoryError = nil;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; BOOL success = [[AVAudioSession sharedInstance] setCategory:AVAudioSessionCategoryPlayback error:&amp;categoryError];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; if (!success)</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; NSLog(@"Error setting audio session category: %@", categoryError);</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; }</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; NSError *activeError = nil;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; success = [[AVAudioSession sharedInstance] setActive:YES error:&amp;activeError];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; if (!success)</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; NSLog(@"Error setting audio session active: %@", activeError);</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; }</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> }</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 468px;"></div><div class="CodeMirror-gutters" style="display: none; height: 468px;"></div></div></div></pre><h4><a name="312-通过获得场景账号useridapikeyvideoid来获取dwvodvideomodel对象无获得场景账号点击注册httpsadminbokecccomloginbo" class="md-header-anchor"></a><span>3.1.2 通过获得场景账号UserID、APIKey、VideoId,来获取DWVodVideoModel对象。无获得场景账号?</span><a href='https://admin.bokecc.com/login.bo'><span>点击注册</span></a></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang="" style="break-inside: unset;"><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; DWPlayInfo * playInfo = [[DWPlayInfo alloc]initWithUserId:@"账号ID" andVideoId:@"视频ID" key:@"APIKey" hlsSupport:@"1"];</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.timeoutSeconds = 30;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.mediatype = @"1";</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.verificationCode = @"授权验证码,没有此功能不需要设置";</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.roleId = @"客户端用户id,选填";</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.finishBlock = ^(DWVodVideoModel *vodVideo) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //成功回调</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; NSLog(@"%@",vodVideo);</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; };</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.errorBlock = ^(NSError *error) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //失败回调 &nbsp; &nbsp; &nbsp; </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; };</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; [playInfo start];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 390px;"></div><div class="CodeMirror-gutters" style="display: none; height: 390px;"></div></div></div></pre><h4><a name="313-创建dwplayerview默认播放器dwplayerskinview带皮肤的播放器对象添加到视图中待获取到dwvodvideomodel对象后传入即可播放在线视频" class="md-header-anchor"></a><span>3.1.3 创建DWPlayerView(默认播放器)/DWPlayerSkinView(带皮肤的播放器)对象添加到视图中,待获取到DWVodVideoModel对象后传入,即可播放在线视频</span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang="" style="break-inside: unset;"><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //创建默认播放器对象</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; self.playerView = [[DWPlayerView alloc]init];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; [self addSubview:self.playerView];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //或者创建带皮肤的播放器对象</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; self.playerSkinView = [[DWPlayerSkinView alloc]initSkinView];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; [self addSubview: self.playerSkinView]; &nbsp; &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //等待DWPlayInfo获取到DWVodVideoModel对象</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.finishBlock = ^(DWVodVideoModel *vodVideo) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //成功回调</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //NSLog(@"%@",vodVideo);</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; [self.playerView playVodViedo:videoModel withCustomId:nil];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; [self.playerView play];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //或者</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //[self.playerSkinView playVodViedo:vodVideo];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; };</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; ...</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 520px;"></div><div class="CodeMirror-gutters" style="display: none; height: 520px;"></div></div></div></pre><h3><a name="32-下载功能" class="md-header-anchor"></a><span>3.2 下载功能</span></h3><h4><a name="321-通过获得场景账号useridapikeyvideoid来获取dwvodvideomodel对象" class="md-header-anchor"></a><span>3.2.1 通过获得场景账号UserID、APIKey、VideoId,来获取DWVodVideoModel对象</span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang=""><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation"><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> //获取方式与视频获取方式一样,只不过hlsSupport参数要传@"0" </span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; DWPlayInfo * playInfo = [[DWPlayInfo alloc]initWithUserId:@"账号ID" andVideoId:@"视频ID" key:@"APIKey" hlsSupport:@"0"];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> ...</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 130px;"></div><div class="CodeMirror-gutters" style="display: none; height: 130px;"></div></div></div></pre><h4><a name="322-获取dwdownloadsessionmanager单例对象创建dwdownloadmodel对象通过调用startwithdownloadmodel方法即可开始下载" class="md-header-anchor"></a><span>3.2.2 获取DWDownloadSessionManager单例对象,创建DWDownloadModel对象,通过调用startWithDownloadModel:方法即可开始下载</span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang="" style="break-inside: unset;"><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //等待DWPlayInfo获取到DWVodVideoModel对象</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; playInfo.finishBlock = ^(DWVodVideoModel *vodVideo) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //成功回调</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //得到需要下载的清晰度model,数据</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //这里根据自身业务逻辑进行调整,这里下载的第一个视频</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; DWVideoQualityModel * qualityModel = [videoModel.qualities firstObject];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; DWDownloadSessionManager * manager = [DWDownloadSessionManager manager];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //验证当前任务是否已经在下载队列中</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; if ([manager checkLocalResourceWithVideoId:videoModel.videoId WithQuality:qualityModel.quality]) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; return;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; }</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; //没有此任务,创建DWDownloadModel对象,开始下载 &nbsp; &nbsp; &nbsp; &nbsp; </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; DWDownloadModel * model = [DWDownloadSessionManager createDownloadModel:videoModel Quality:qualityModel.quality AndOthersInfo:nil];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; if (!model) {</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; //DownloadModel创建失败,请检查参数</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; return;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; }</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; [manager startWithDownloadModel:model]; &nbsp; &nbsp; &nbsp; &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; };</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 624px;"></div><div class="CodeMirror-gutters" style="display: none; height: 624px;"></div></div></div></pre><h3><a name="33-上传功能" class="md-header-anchor"></a><span>3.3 上传功能</span></h3><h4><a name="331-通过dwvideocompresscontroller选择要上传的视频" class="md-header-anchor"></a><span>3.3.1 通过DWVideoCompressController,选择要上传的视频</span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang=""><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation"><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; DWVideoCompressController *imagePicker = [[DWVideoCompressController alloc] initWithQuality: DWUIImagePickerControllerQualityTypeMedium andSourceType:DWUIImagePickerControllerSourceTypePhotoLibrary andMediaType:DWUIImagePickerControllerMediaTypeMovie];</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; imagePicker.delegate = self;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; [self presentViewController:imagePicker animated:NO completion:nil];</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 156px;"></div><div class="CodeMirror-gutters" style="display: none; height: 156px;"></div></div></div></pre><h4><a name="332-获取到本地视频路径通过dwuploadsessionmanager创建dwuploadmodel开始上传" class="md-header-anchor"></a><span>3.3.2 获取到本地视频路径,通过DWUploadSessionManager创建DWUploadModel,开始上传</span></h4><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm" lang=""><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //注意!获取到上传路径之后,请务必调用moveToLocalWithVideoPath:方法获取SDK所需的视频url,否则可能会出现上传失败,找不到视频文件等情况。</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; NSURL *videoURL = [info objectForKey:UIImagePickerControllerMediaURL];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //选中视频以后,请务必调用此方法,否则可能会出现上传失败,找不到视频文件等情况。</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; self.videoPath = [self.manager moveToLocalWithVideoPath:[videoURL path]];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //填写完视频信息以后,通过DWUploadSessionManager创建DWUploadModel。</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; DWUploadModel * uploadModel = [DWUploadSessionManager createUploadModelWithUserId:userId Apikey:apiKey VideoTitle:videoTitle VideoDescription:videoDescription VideoTag:videoTag VideoPath:self.videoPath CategoryId:nil NotifyURL:nil];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; //DWUploadModel创建成功以后,调用startWithUploadModel:方法,即可开始上传视频</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; [self.manager startWithUploadModel:uploadModel];</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 390px;"></div><div class="CodeMirror-gutters" style="display: none; height: 390px;"></div></div></div></pre></div>
</body> </body>
</html> </html>
\ No newline at end of file
...@@ -1837,6 +1837,6 @@ footer.ty-footer { ...@@ -1837,6 +1837,6 @@ footer.ty-footer {
</style> </style>
</head> </head>
<body class='typora-export' > <body class='typora-export' >
<div id='write' class = ''><h1><a name="更新日志" class="md-header-anchor"></a><span>更新日志 </span></h1><h2><a name="version-4141" class="md-header-anchor"></a><span>Version 4.14.1</span></h2><p><span>发布时间:2021-03-25</span></p><p><span>1.修复了DWPlayInfo可能没有正确的设置授权验证码的问题。</span></p><h2><a name="version-4140" class="md-header-anchor"></a><span>Version 4.14.0</span></h2><p><span>发布时间:2021-03-17</span></p><p><span>1.新增字幕自适应功能。</span></p><p><span>2.完善SDK编码规范。</span></p><h2><a name="version-4130" class="md-header-anchor"></a><span>Version 4.13.0</span></h2><p><span>发布时间:2021-01-19</span></p><p><span>1.新增自定义LOGO功能。</span></p><p><span>2.修复demo播放按钮显示异常的问题。</span></p><h2><a name="version-4120" class="md-header-anchor"></a><span>Version 4.12.0</span></h2><p><span>发布时间:2021-01-11</span></p><p><span>1.支持防拖拽功能。</span></p><p><span>2.锁屏逻辑优化。</span></p><p><span>3.修复某些设备下投屏异常的问题。</span></p><p><span>4.SDK下载模块优化,提高稳定性。</span></p><h2><a name="version-4111" class="md-header-anchor"></a><span>Version 4.11.1</span></h2><p><span>发布时间:2020-12-14</span></p><p><span>1.修复了下载方法传参异常导致的闪退问题。</span></p><p><span>2.解密模块优化,提高稳定性。</span></p><h2><a name="version-4110" class="md-header-anchor"></a><span>Version 4.11.0</span></h2><p><span>发布时间:2020-11-19</span></p><p><span>1.支持离线视频显示字幕。</span></p><p><span>2.demo竖屏模式下,支持手势拖拽。</span></p><p><span>3.demo播放页面进度条支持点击调整进度。</span></p><p><span>4.修复了demo中的bug。</span></p><h2><a name="version-4102" class="md-header-anchor"></a><span>Version 4.10.2</span></h2><p><span>发布时间:2020-11-06</span></p><p><span>1.支持iOS14,iPhone使用画中画功能。</span></p><p><span>2.优化demo中的方法。</span></p><h2><a name="version-4101" class="md-header-anchor"></a><span>Version 4.10.1</span></h2><p><span>发布时间:2020-10-27</span></p><p><span>1.修复在iOS14下,开启后台播放时进入后台导致播放暂停的问题。</span></p><h2><a name="version-4100" class="md-header-anchor"></a><span>Version 4.10.0</span></h2><p><span>发布时间:2020-10-20</span></p><p><span>1.课堂练习功能优化。</span></p><p><span>2.修复demo中进度条在iOS14上显示异常的问题。</span></p><h2><a name="version-491" class="md-header-anchor"></a><span>Version 4.9.1</span></h2><p><span>发布时间:2020-09-25</span></p><p><span>1.常见问题添加cocoapods集成编译报错的解决方案。</span></p><h2><a name="version-490" class="md-header-anchor"></a><span>Version 4.9.0</span></h2><p><span>发布时间:2020-09-24</span></p><p><span>1.解决SDK在Xcode12上运行编译报错的问题。</span></p><p><span>2.优化广告功能,支持片尾广告。</span></p><p><span>3.修复demo中的bug。</span></p><h2><a name="version-481" class="md-header-anchor"></a><span>Version 4.8.1</span></h2><p><span>发布时间:2020-08-24</span></p><p><span>1.新增动感视频功能 </span></p><h2><a name="version-480" class="md-header-anchor"></a><span>Version 4.8.0</span></h2><p><span>发布时间:2020-08-17</span></p><p><span>1.SDK类型由.a升级为.framework。</span></p><p><span>2.优化播放流程,主线路播放失败时自动切换备用线路。</span></p><p><span>3.完善SDK注释。</span></p><h2><a name="version-470" class="md-header-anchor"></a><span>Version 4.7.0</span></h2><p><span>发布时间:2020-07-14</span></p><p><span>1.优化SDK解密模块,提升稳定性。</span></p><p><span>2.新增平台统计功能。</span></p><p><span>3.调整SDK架构,解决与其他产品线的冲突。</span></p><h2><a name="version-461" class="md-header-anchor"></a><span>Version 4.6.1</span></h2><p><span>发布时间:2020-07-01</span></p><p><span>1.优化DWPlayerView工作流程。</span></p><p><span>2.demo中新增播放失败重试逻辑。</span></p><h2><a name="version-460" class="md-header-anchor"></a><span>Version 4.6.0</span></h2><p><span>发布时间:2020-06-19</span></p><p><span>1.新增弹幕功能。</span></p><p><span>2.修复手势拖拽在ipad上的兼容性问题。</span></p><h2><a name="version-452" class="md-header-anchor"></a><span>Version 4.5.2</span></h2><p><span>发布时间:2020-06-03</span></p><p><span>1.修复进度条显示异常的问题。</span></p><p><span>2.修复GIF录制时,loading可能不消失的问题。</span></p><p><span>3.优化SDK解密流程,提升稳定性。</span></p><p><span>4.优化SDK统计上报流程。</span></p><h2><a name="version-451" class="md-header-anchor"></a><span>Version 4.5.1</span></h2><p><span>发布时间:2020-05-20</span></p><p><span>1.修复小窗模式导致的播放异常的问题。</span></p><p><span>2.修复离线播放页面UI显示异常的问题。</span></p><h2><a name="version-450" class="md-header-anchor"></a><span>Version 4.5.0</span></h2><p><span>发布时间:2020-05-13</span></p><p><span>1.新增小窗播放功能。</span></p><p><span>2.支持加密,非加密视频截图。</span></p><p><span>3.修复了网络检测页面在iOS13上的兼容性问题。</span></p><h2><a name="version-443" class="md-header-anchor"></a><span>Version 4.4.3</span></h2><p><span>发布时间:2020-04-14</span></p><p><span>1.修复拖拽统计异常的问题。</span></p><p><span>2.修复下载链接超时时,可能会重新下载的问题。</span></p><h2><a name="version-442" class="md-header-anchor"></a><span>Version 4.4.2</span></h2><p><span>发布时间:2020-03-24</span></p><p><span>1.播放页面新增手势调节功能。</span></p><h2><a name="version-441" class="md-header-anchor"></a><span>Version 4.4.1</span></h2><p><span>发布时间:2020-03-17</span></p><p><span>1.跑马灯功能优化。</span></p><h2><a name="version-440" class="md-header-anchor"></a><span>Version 4.4.0</span></h2><p><span>发布时间:2020-03-13</span></p><p><span>1.新增音频统计功能。</span></p><p><span>2.新增跑马灯功能。</span></p><h2><a name="version-431" class="md-header-anchor"></a><span>Version 4.3.1</span></h2><p><span>发布时间:2020-03-02</span></p><p><span>1.DWPlayerView新增播放时长/暂停时长统计。</span></p><p><span>2.优化DWPlayInfo流程。</span></p><h2><a name="version-430" class="md-header-anchor"></a><span>Version 4.3.0</span></h2><p><span>发布时间:2020-02-21</span></p><p><span>1.支持视频后台播放功能。</span></p><p><span>2.支持iPad画中画功能。</span></p><p><span>3.修复了修改DWDownloadModel,othersInfo字段时,没有正确本地化的问题。</span></p><p><span>4.优化上传流程。</span></p><h2><a name="version-427" class="md-header-anchor"></a><span>Version 4.2.7</span></h2><p><span>发布时间:2020-01-02</span></p><p><span>更新内容:</span></p><p><span>1.优化了demo界面显示效果。</span></p><p><span>2.修复了下载时,导致任务异常失败的bug。</span></p><p><span>3.优化上传流程,同时解决了偶发导致程序闪退的bug。</span></p><p><span>4.优化数据统计相关逻辑。</span></p><h2><a name="version-425" class="md-header-anchor"></a><span>Version 4.2.5</span></h2><p><span>发布时间:2019-12-04</span></p><p><span>更新内容:</span></p><p><span>1.修复了视频文件上传时,SDK异常输出失败的bug。</span></p><p><span>2.优化下载流程,现在可以对等待中的下载任务进行暂停/继续下载操作了。</span></p><h2><a name="version-424" class="md-header-anchor"></a><span>Version 4.2.4</span></h2><p><span>发布时间:2019-11-14</span></p><p><span>更新内容:</span></p><p><span>1.demo页面逻辑优化。</span></p><p><span>2.SDK上传功能逻辑优化。</span></p><p><span>3.DWPlayInfo新增取消网络请求方法。</span></p><p><span>4.修复了4.2.3版本在低版本Xcode编译报错的问题。</span></p><h2><a name="version-423" class="md-header-anchor"></a><span>Version 4.2.3</span></h2><p><span>发布时间:2019-10-10</span></p><p><span>更新内容:</span></p><p><span>1.修复了iOS13下,播放本地视频可能会导致内存异常上涨的bug。</span></p><p><span>2.iOS13适配。</span></p><h2><a name="version-422" class="md-header-anchor"></a><span>Version 4.2.2</span></h2><p><span>发布时间:2019-08-27</span></p><p><span>更新内容:</span></p><p><span>1.DWPlayerView新增AVPlayerLayer属性。</span></p><p><span>2.修复了不引入DWSDK.h可能导致编译报错的bug。</span></p><h2><a name="version-421" class="md-header-anchor"></a><span>Version 4.2.1</span></h2><p><span>发布时间:2019-08-19</span></p><p><span>更新内容:</span></p><p><span>1.支持视频后台上传。</span></p><p><span>2.优化下载流程。</span></p><h2><a name="version-420" class="md-header-anchor"></a><span>Version 4.2.0</span></h2><p><span>发布时间:2019-08-12</span></p><p><span>更新内容:</span></p><p><span>1.新增视频防录屏功能</span></p><p><span>2.新增视频动态水印</span></p><p><span>3.优化离线视频播放流程</span></p><p><span>4.优化下载暂停流程</span></p><h2><a name="version-410" class="md-header-anchor"></a><span>Version 4.1.0</span></h2><p><span>发布时间:2019-07-30</span></p><p><span>更新内容:</span></p><p><span>1.新增视频投屏功能。</span></p><p><span>2.优化视频问答流程。</span></p><p><span>3.将resource.bundle修改为DWResource.bundle防止引入冲突。 </span></p><h2><a name="version-403" class="md-header-anchor"></a><span>Version 4.0.3</span></h2><p><span>发布时间:2019-07-09</span></p><p><span>更新内容:</span></p><p><span>1.修复了备用线路地址输出不正确的bug。</span></p><h2><a name="version-402" class="md-header-anchor"></a><span>Version 4.0.2</span></h2><p><span>发布时间:2019-07-03</span></p><p><span>更新内容:</span></p><p><span>1.修复了课堂练习显示有问题的bug。</span></p><h2><a name="version-401" class="md-header-anchor"></a><span>Version 4.0.1</span></h2><p><span>发布时间:2019-07-02</span></p><p><span>更新内容:</span></p><p><span>1.课堂练习功能。</span></p><p><span>2.支持m3u8格式,缓存时长控制。</span></p><p><span>3.修复了iPhone7及plus机型下,m3u8播放链接可能会返回有误的问题。</span></p><h2><a name="version-400" class="md-header-anchor"></a><span>Version 4.0.0</span></h2><p><span>发布时间:2019-06-18</span></p><p><span>更新内容:</span></p><p><span>1.demo全新升级。</span></p><p><span>2.加密与非加密版本的demo合并。</span></p><p><span>3.支持Cocoapods方式集成。</span></p><p><span>4.优化SDK使用方式。</span></p><h2><a name="version-345" class="md-header-anchor"></a><span>Version 3.4.5</span></h2><p><span>发布时间:2019-06-14</span></p><p><span>更新内容:</span></p><p><span>1.视频问答优化。</span></p><p><span>2.广告播放流程优化。</span></p><p><span>3.修复了低版本下,播放音频时可能会导致闪退的问题。</span></p><h2><a name="version-344" class="md-header-anchor"></a><span>Version 3.4.4</span></h2><p><span>发布时间:2019-05-17</span></p><p><span>更新内容:</span></p><p><span>1.新增访客信息收集器功能。 </span><br/><span> </span><br/><span>2.解决了在一些特殊情况下会发生crash的bug。</span></p><h2><a name="version-343" class="md-header-anchor"></a><span>Version 3.4.3</span></h2><p><span>发布时间:2019-04-19</span></p><p><span>更新内容:</span></p><p><span>1.修复了播放离线音视频可能会crash的bug。</span></p><h2><a name="version-341" class="md-header-anchor"></a><span>Version 3.4.1</span></h2><p><span>发布时间:2019-04-02</span></p><p><span>更新内容:</span></p><p><span>1.优化了播放音频时,可能出现的缓冲时间过长的问题。</span></p><h2><a name="version-340" class="md-header-anchor"></a><span>Version 3.4.0</span></h2><p><span>发布时间:2019-03-06</span></p><p><span>更新内容:</span></p><p><span>1.新增音频DRM加密功能。</span></p><h2><a name="version-336" class="md-header-anchor"></a><span>Version 3.3.6</span></h2><p><span>发布时间:2019-02-27</span></p><p><span>更新内容:</span></p><p><span>1.修复了对同一DWDrmServer对象多次调用start/stop,引起crash的bug。</span></p><h2><a name="version-335" class="md-header-anchor"></a><span>Version 3.3.5</span></h2><p><span>发布时间:2019-02-14</span></p><p><span>更新内容:</span></p><p><span>1.视频批量下载功能。</span></p><p><span>2.修复了Demo界面上的一些显示bug。</span></p><h2><a name="version-334" class="md-header-anchor"></a><span>Version 3.3.4</span></h2><p><span>发布时间:2019-01-25</span></p><p><span>更新内容:</span></p><p><span>1.新增字幕切换功能。</span></p><h2><a name="version-333" class="md-header-anchor"></a><span>Version 3.3.3</span></h2><p><span>发布时间:2019-01-09</span></p><p><span>更新内容:</span></p><p><span>1.修复了iOS11.3之后,当原URL失效时,无法使用新URL继续下载的BUG。</span></p><h2><a name="version-332" class="md-header-anchor"></a><span>Version 3.3.2</span></h2><p><span>发布时间:2018-12-26</span></p><p><span>更新内容:</span></p><p><span>1.完善SDK内部播放出错处理机制。</span></p><p><span>2.优化了demo流程,播放失败时自动切换备用线路。</span></p><p><span>3.修复了demo中的一些bug。</span></p><h2><a name="version-331" class="md-header-anchor"></a><span>Version 3.3.1</span></h2><p><span>发布时间:2018-12-12</span></p><p><span>更新内容:</span></p><p><span>1.GIF功能整合,m3u8视频格式可以正常生成GIF。</span></p><p><span>2.修复了Drm模块在弱网下可能引发的一些问题。</span></p><h2><a name="version-330" class="md-header-anchor"></a><span>Version 3.3.0</span></h2><p><span>发布时间:2018-11-22</span></p><p><span>更新内容:</span></p><p><span>1.视频问答新增单选多选类型。</span></p><p><span>2.新增网络检测功能。</span></p><p><span>3.原片实时播放流程处理。</span></p><p><span>4.修复了demo中的一些bug。</span></p><h2><a name="version-321" class="md-header-anchor"></a><span>Version 3.2.1</span></h2><p><span>发布时间:2018-10-26</span></p><p><span>更新内容:</span></p><p><span>1.SDK新增错误码。</span></p><p><span>2.修复了在iOS12下,导致程序crash的BUG。</span></p><h2><a name="version-320" class="md-header-anchor"></a><span>Version 3.2.0</span></h2><p><span>发布时间:2018-08-28</span></p><p><span>更新内容:</span></p><p><span>1.增加授权验证功能。</span></p><p><span>2.增加自定义超时时间功能。</span></p><h2><a name="version-318" class="md-header-anchor"></a><span>Version 3.1.8</span></h2><p><span>发布时间:2018-06-12</span></p><p><span>更新内容:</span></p><p><span>1.新增问答统计功能</span></p><h2><a name="version-317" class="md-header-anchor"></a><span>Version 3.1.7</span></h2><p><span>发布时间:2018-06-07</span></p><p><span>更新内容:</span></p><p><span>1.改善SDK帮助文档。</span></p><h2><a name="version-316" class="md-header-anchor"></a><span>Version 3.1.6</span></h2><p><span>发布时间:2018-05-22</span></p><p><span>更新内容:</span></p><p><span>1.增加字幕显示功能。</span></p><h2><a name="version-315" class="md-header-anchor"></a><span>Version 3.1.5</span></h2><p><span>发布时间:2018-05-15</span></p><p><span>更新内容:</span></p><p><span>1.新增问答图片显示功能。</span></p><h2><a name="version-314" class="md-header-anchor"></a><span>Version 3.1.4</span></h2><p><span>发布时间:2018-05-10</span></p><p><span>更新内容:</span></p><p><span>1.上传功能优化。</span></p></div> <div id='write' class = ''><h1><a name="更新日志" class="md-header-anchor"></a><span>更新日志 </span></h1><h2><a name="version-4142" class="md-header-anchor"></a><span>Version 4.14.2</span></h2><p><span>发布时间:2021-03-29</span></p><p><span>1.新增真机架构SDK。</span></p><h2><a name="version-4141" class="md-header-anchor"></a><span>Version 4.14.1</span></h2><p><span>发布时间:2021-03-25</span></p><p><span>1.修复了DWPlayInfo可能没有正确的设置授权验证码的问题。</span></p><h2><a name="version-4140" class="md-header-anchor"></a><span>Version 4.14.0</span></h2><p><span>发布时间:2021-03-17</span></p><p><span>1.新增字幕自适应功能。</span></p><p><span>2.完善SDK编码规范。</span></p><h2><a name="version-4130" class="md-header-anchor"></a><span>Version 4.13.0</span></h2><p><span>发布时间:2021-01-19</span></p><p><span>1.新增自定义LOGO功能。</span></p><p><span>2.修复demo播放按钮显示异常的问题。</span></p><h2><a name="version-4120" class="md-header-anchor"></a><span>Version 4.12.0</span></h2><p><span>发布时间:2021-01-11</span></p><p><span>1.支持防拖拽功能。</span></p><p><span>2.锁屏逻辑优化。</span></p><p><span>3.修复某些设备下投屏异常的问题。</span></p><p><span>4.SDK下载模块优化,提高稳定性。</span></p><h2><a name="version-4111" class="md-header-anchor"></a><span>Version 4.11.1</span></h2><p><span>发布时间:2020-12-14</span></p><p><span>1.修复了下载方法传参异常导致的闪退问题。</span></p><p><span>2.解密模块优化,提高稳定性。</span></p><h2><a name="version-4110" class="md-header-anchor"></a><span>Version 4.11.0</span></h2><p><span>发布时间:2020-11-19</span></p><p><span>1.支持离线视频显示字幕。</span></p><p><span>2.demo竖屏模式下,支持手势拖拽。</span></p><p><span>3.demo播放页面进度条支持点击调整进度。</span></p><p><span>4.修复了demo中的bug。</span></p><h2><a name="version-4102" class="md-header-anchor"></a><span>Version 4.10.2</span></h2><p><span>发布时间:2020-11-06</span></p><p><span>1.支持iOS14,iPhone使用画中画功能。</span></p><p><span>2.优化demo中的方法。</span></p><h2><a name="version-4101" class="md-header-anchor"></a><span>Version 4.10.1</span></h2><p><span>发布时间:2020-10-27</span></p><p><span>1.修复在iOS14下,开启后台播放时进入后台导致播放暂停的问题。</span></p><h2><a name="version-4100" class="md-header-anchor"></a><span>Version 4.10.0</span></h2><p><span>发布时间:2020-10-20</span></p><p><span>1.课堂练习功能优化。</span></p><p><span>2.修复demo中进度条在iOS14上显示异常的问题。</span></p><h2><a name="version-491" class="md-header-anchor"></a><span>Version 4.9.1</span></h2><p><span>发布时间:2020-09-25</span></p><p><span>1.常见问题添加cocoapods集成编译报错的解决方案。</span></p><h2><a name="version-490" class="md-header-anchor"></a><span>Version 4.9.0</span></h2><p><span>发布时间:2020-09-24</span></p><p><span>1.解决SDK在Xcode12上运行编译报错的问题。</span></p><p><span>2.优化广告功能,支持片尾广告。</span></p><p><span>3.修复demo中的bug。</span></p><h2><a name="version-481" class="md-header-anchor"></a><span>Version 4.8.1</span></h2><p><span>发布时间:2020-08-24</span></p><p><span>1.新增动感视频功能 </span></p><h2><a name="version-480" class="md-header-anchor"></a><span>Version 4.8.0</span></h2><p><span>发布时间:2020-08-17</span></p><p><span>1.SDK类型由.a升级为.framework。</span></p><p><span>2.优化播放流程,主线路播放失败时自动切换备用线路。</span></p><p><span>3.完善SDK注释。</span></p><h2><a name="version-470" class="md-header-anchor"></a><span>Version 4.7.0</span></h2><p><span>发布时间:2020-07-14</span></p><p><span>1.优化SDK解密模块,提升稳定性。</span></p><p><span>2.新增平台统计功能。</span></p><p><span>3.调整SDK架构,解决与其他产品线的冲突。</span></p><h2><a name="version-461" class="md-header-anchor"></a><span>Version 4.6.1</span></h2><p><span>发布时间:2020-07-01</span></p><p><span>1.优化DWPlayerView工作流程。</span></p><p><span>2.demo中新增播放失败重试逻辑。</span></p><h2><a name="version-460" class="md-header-anchor"></a><span>Version 4.6.0</span></h2><p><span>发布时间:2020-06-19</span></p><p><span>1.新增弹幕功能。</span></p><p><span>2.修复手势拖拽在ipad上的兼容性问题。</span></p><h2><a name="version-452" class="md-header-anchor"></a><span>Version 4.5.2</span></h2><p><span>发布时间:2020-06-03</span></p><p><span>1.修复进度条显示异常的问题。</span></p><p><span>2.修复GIF录制时,loading可能不消失的问题。</span></p><p><span>3.优化SDK解密流程,提升稳定性。</span></p><p><span>4.优化SDK统计上报流程。</span></p><h2><a name="version-451" class="md-header-anchor"></a><span>Version 4.5.1</span></h2><p><span>发布时间:2020-05-20</span></p><p><span>1.修复小窗模式导致的播放异常的问题。</span></p><p><span>2.修复离线播放页面UI显示异常的问题。</span></p><h2><a name="version-450" class="md-header-anchor"></a><span>Version 4.5.0</span></h2><p><span>发布时间:2020-05-13</span></p><p><span>1.新增小窗播放功能。</span></p><p><span>2.支持加密,非加密视频截图。</span></p><p><span>3.修复了网络检测页面在iOS13上的兼容性问题。</span></p><h2><a name="version-443" class="md-header-anchor"></a><span>Version 4.4.3</span></h2><p><span>发布时间:2020-04-14</span></p><p><span>1.修复拖拽统计异常的问题。</span></p><p><span>2.修复下载链接超时时,可能会重新下载的问题。</span></p><h2><a name="version-442" class="md-header-anchor"></a><span>Version 4.4.2</span></h2><p><span>发布时间:2020-03-24</span></p><p><span>1.播放页面新增手势调节功能。</span></p><h2><a name="version-441" class="md-header-anchor"></a><span>Version 4.4.1</span></h2><p><span>发布时间:2020-03-17</span></p><p><span>1.跑马灯功能优化。</span></p><h2><a name="version-440" class="md-header-anchor"></a><span>Version 4.4.0</span></h2><p><span>发布时间:2020-03-13</span></p><p><span>1.新增音频统计功能。</span></p><p><span>2.新增跑马灯功能。</span></p><h2><a name="version-431" class="md-header-anchor"></a><span>Version 4.3.1</span></h2><p><span>发布时间:2020-03-02</span></p><p><span>1.DWPlayerView新增播放时长/暂停时长统计。</span></p><p><span>2.优化DWPlayInfo流程。</span></p><h2><a name="version-430" class="md-header-anchor"></a><span>Version 4.3.0</span></h2><p><span>发布时间:2020-02-21</span></p><p><span>1.支持视频后台播放功能。</span></p><p><span>2.支持iPad画中画功能。</span></p><p><span>3.修复了修改DWDownloadModel,othersInfo字段时,没有正确本地化的问题。</span></p><p><span>4.优化上传流程。</span></p><h2><a name="version-427" class="md-header-anchor"></a><span>Version 4.2.7</span></h2><p><span>发布时间:2020-01-02</span></p><p><span>更新内容:</span></p><p><span>1.优化了demo界面显示效果。</span></p><p><span>2.修复了下载时,导致任务异常失败的bug。</span></p><p><span>3.优化上传流程,同时解决了偶发导致程序闪退的bug。</span></p><p><span>4.优化数据统计相关逻辑。</span></p><h2><a name="version-425" class="md-header-anchor"></a><span>Version 4.2.5</span></h2><p><span>发布时间:2019-12-04</span></p><p><span>更新内容:</span></p><p><span>1.修复了视频文件上传时,SDK异常输出失败的bug。</span></p><p><span>2.优化下载流程,现在可以对等待中的下载任务进行暂停/继续下载操作了。</span></p><h2><a name="version-424" class="md-header-anchor"></a><span>Version 4.2.4</span></h2><p><span>发布时间:2019-11-14</span></p><p><span>更新内容:</span></p><p><span>1.demo页面逻辑优化。</span></p><p><span>2.SDK上传功能逻辑优化。</span></p><p><span>3.DWPlayInfo新增取消网络请求方法。</span></p><p><span>4.修复了4.2.3版本在低版本Xcode编译报错的问题。</span></p><h2><a name="version-423" class="md-header-anchor"></a><span>Version 4.2.3</span></h2><p><span>发布时间:2019-10-10</span></p><p><span>更新内容:</span></p><p><span>1.修复了iOS13下,播放本地视频可能会导致内存异常上涨的bug。</span></p><p><span>2.iOS13适配。</span></p><h2><a name="version-422" class="md-header-anchor"></a><span>Version 4.2.2</span></h2><p><span>发布时间:2019-08-27</span></p><p><span>更新内容:</span></p><p><span>1.DWPlayerView新增AVPlayerLayer属性。</span></p><p><span>2.修复了不引入DWSDK.h可能导致编译报错的bug。</span></p><h2><a name="version-421" class="md-header-anchor"></a><span>Version 4.2.1</span></h2><p><span>发布时间:2019-08-19</span></p><p><span>更新内容:</span></p><p><span>1.支持视频后台上传。</span></p><p><span>2.优化下载流程。</span></p><h2><a name="version-420" class="md-header-anchor"></a><span>Version 4.2.0</span></h2><p><span>发布时间:2019-08-12</span></p><p><span>更新内容:</span></p><p><span>1.新增视频防录屏功能</span></p><p><span>2.新增视频动态水印</span></p><p><span>3.优化离线视频播放流程</span></p><p><span>4.优化下载暂停流程</span></p><h2><a name="version-410" class="md-header-anchor"></a><span>Version 4.1.0</span></h2><p><span>发布时间:2019-07-30</span></p><p><span>更新内容:</span></p><p><span>1.新增视频投屏功能。</span></p><p><span>2.优化视频问答流程。</span></p><p><span>3.将resource.bundle修改为DWResource.bundle防止引入冲突。 </span></p><h2><a name="version-403" class="md-header-anchor"></a><span>Version 4.0.3</span></h2><p><span>发布时间:2019-07-09</span></p><p><span>更新内容:</span></p><p><span>1.修复了备用线路地址输出不正确的bug。</span></p><h2><a name="version-402" class="md-header-anchor"></a><span>Version 4.0.2</span></h2><p><span>发布时间:2019-07-03</span></p><p><span>更新内容:</span></p><p><span>1.修复了课堂练习显示有问题的bug。</span></p><h2><a name="version-401" class="md-header-anchor"></a><span>Version 4.0.1</span></h2><p><span>发布时间:2019-07-02</span></p><p><span>更新内容:</span></p><p><span>1.课堂练习功能。</span></p><p><span>2.支持m3u8格式,缓存时长控制。</span></p><p><span>3.修复了iPhone7及plus机型下,m3u8播放链接可能会返回有误的问题。</span></p><h2><a name="version-400" class="md-header-anchor"></a><span>Version 4.0.0</span></h2><p><span>发布时间:2019-06-18</span></p><p><span>更新内容:</span></p><p><span>1.demo全新升级。</span></p><p><span>2.加密与非加密版本的demo合并。</span></p><p><span>3.支持Cocoapods方式集成。</span></p><p><span>4.优化SDK使用方式。</span></p><h2><a name="version-345" class="md-header-anchor"></a><span>Version 3.4.5</span></h2><p><span>发布时间:2019-06-14</span></p><p><span>更新内容:</span></p><p><span>1.视频问答优化。</span></p><p><span>2.广告播放流程优化。</span></p><p><span>3.修复了低版本下,播放音频时可能会导致闪退的问题。</span></p><h2><a name="version-344" class="md-header-anchor"></a><span>Version 3.4.4</span></h2><p><span>发布时间:2019-05-17</span></p><p><span>更新内容:</span></p><p><span>1.新增访客信息收集器功能。 </span><br/><span> </span><br/><span>2.解决了在一些特殊情况下会发生crash的bug。</span></p><h2><a name="version-343" class="md-header-anchor"></a><span>Version 3.4.3</span></h2><p><span>发布时间:2019-04-19</span></p><p><span>更新内容:</span></p><p><span>1.修复了播放离线音视频可能会crash的bug。</span></p><h2><a name="version-341" class="md-header-anchor"></a><span>Version 3.4.1</span></h2><p><span>发布时间:2019-04-02</span></p><p><span>更新内容:</span></p><p><span>1.优化了播放音频时,可能出现的缓冲时间过长的问题。</span></p><h2><a name="version-340" class="md-header-anchor"></a><span>Version 3.4.0</span></h2><p><span>发布时间:2019-03-06</span></p><p><span>更新内容:</span></p><p><span>1.新增音频DRM加密功能。</span></p><h2><a name="version-336" class="md-header-anchor"></a><span>Version 3.3.6</span></h2><p><span>发布时间:2019-02-27</span></p><p><span>更新内容:</span></p><p><span>1.修复了对同一DWDrmServer对象多次调用start/stop,引起crash的bug。</span></p><h2><a name="version-335" class="md-header-anchor"></a><span>Version 3.3.5</span></h2><p><span>发布时间:2019-02-14</span></p><p><span>更新内容:</span></p><p><span>1.视频批量下载功能。</span></p><p><span>2.修复了Demo界面上的一些显示bug。</span></p><h2><a name="version-334" class="md-header-anchor"></a><span>Version 3.3.4</span></h2><p><span>发布时间:2019-01-25</span></p><p><span>更新内容:</span></p><p><span>1.新增字幕切换功能。</span></p><h2><a name="version-333" class="md-header-anchor"></a><span>Version 3.3.3</span></h2><p><span>发布时间:2019-01-09</span></p><p><span>更新内容:</span></p><p><span>1.修复了iOS11.3之后,当原URL失效时,无法使用新URL继续下载的BUG。</span></p><h2><a name="version-332" class="md-header-anchor"></a><span>Version 3.3.2</span></h2><p><span>发布时间:2018-12-26</span></p><p><span>更新内容:</span></p><p><span>1.完善SDK内部播放出错处理机制。</span></p><p><span>2.优化了demo流程,播放失败时自动切换备用线路。</span></p><p><span>3.修复了demo中的一些bug。</span></p><h2><a name="version-331" class="md-header-anchor"></a><span>Version 3.3.1</span></h2><p><span>发布时间:2018-12-12</span></p><p><span>更新内容:</span></p><p><span>1.GIF功能整合,m3u8视频格式可以正常生成GIF。</span></p><p><span>2.修复了Drm模块在弱网下可能引发的一些问题。</span></p><h2><a name="version-330" class="md-header-anchor"></a><span>Version 3.3.0</span></h2><p><span>发布时间:2018-11-22</span></p><p><span>更新内容:</span></p><p><span>1.视频问答新增单选多选类型。</span></p><p><span>2.新增网络检测功能。</span></p><p><span>3.原片实时播放流程处理。</span></p><p><span>4.修复了demo中的一些bug。</span></p><h2><a name="version-321" class="md-header-anchor"></a><span>Version 3.2.1</span></h2><p><span>发布时间:2018-10-26</span></p><p><span>更新内容:</span></p><p><span>1.SDK新增错误码。</span></p><p><span>2.修复了在iOS12下,导致程序crash的BUG。</span></p><h2><a name="version-320" class="md-header-anchor"></a><span>Version 3.2.0</span></h2><p><span>发布时间:2018-08-28</span></p><p><span>更新内容:</span></p><p><span>1.增加授权验证功能。</span></p><p><span>2.增加自定义超时时间功能。</span></p><h2><a name="version-318" class="md-header-anchor"></a><span>Version 3.1.8</span></h2><p><span>发布时间:2018-06-12</span></p><p><span>更新内容:</span></p><p><span>1.新增问答统计功能</span></p><h2><a name="version-317" class="md-header-anchor"></a><span>Version 3.1.7</span></h2><p><span>发布时间:2018-06-07</span></p><p><span>更新内容:</span></p><p><span>1.改善SDK帮助文档。</span></p><h2><a name="version-316" class="md-header-anchor"></a><span>Version 3.1.6</span></h2><p><span>发布时间:2018-05-22</span></p><p><span>更新内容:</span></p><p><span>1.增加字幕显示功能。</span></p><h2><a name="version-315" class="md-header-anchor"></a><span>Version 3.1.5</span></h2><p><span>发布时间:2018-05-15</span></p><p><span>更新内容:</span></p><p><span>1.新增问答图片显示功能。</span></p><h2><a name="version-314" class="md-header-anchor"></a><span>Version 3.1.4</span></h2><p><span>发布时间:2018-05-10</span></p><p><span>更新内容:</span></p><p><span>1.上传功能优化。</span></p></div>
</body> </body>
</html> </html>
\ No newline at end of file
...@@ -1910,7 +1910,9 @@ footer.ty-footer { ...@@ -1910,7 +1910,9 @@ footer.ty-footer {
</style> </style>
</head> </head>
<body class='typora-export' > <body class='typora-export' >
<div id='write' class = ''><h1><a name="常见问题" class="md-header-anchor"></a><span>常见问题</span></h1><h2><a name="1dwplayinfo数据获取失败的问题" class="md-header-anchor"></a><span>1.DWPlayInfo数据获取失败的问题</span></h2><p><span>当遇到DWPlayInfo回调失败时,首先要排除userId、APIKEY是否有效,其次判断网络是否正常、是否已经连接、videoId是否是userId和APIKEY名下的视频。除此之外还可以通过HTTP通信日志排查问题。</span></p><h2><a name="2关于加密音视频的播放问题" class="md-header-anchor"></a><span>2.关于加密音视频的播放问题</span></h2><p><span>新版本中,对于原旧版本加密服务DWDrmServer的调用封装到了SDK内部,用户无需再对DWDrmServer服务进行操作,SDK会自动识别加密音视频进行播放。</span></p><h2><a name="3对于通过import-dwsdkh无法引入路径下的文件的问题" class="md-header-anchor"></a><span>3.对于通过#import &quot;DWSDK.h&quot;无法引入路径下的文件的问题</span></h2><p><span>找到TARGETS -&gt; Build Setting -&gt; Search Paths。添加</span><code>Header Search Path</code><span>,路径到SDK的文件夹下。若还无法找到,继续添加</span><code>User Header Search Path</code><span>即可。</span></p><h2><a name="4关于控制台频繁出现-nwconnectioncopyconnectedpath日志的问题" class="md-header-anchor"></a><span>4.关于控制台频繁出现&quot;[] nw_connection_copy_connected_path&quot;日志的问题</span></h2><p><span>找到Edit Scheme -&gt; Run -&gt; Arguments -&gt; Enviroment Variables,添加属性</span><code>OS_ACTIVITY_MODE</code><span>,设置为0即可。</span></p><h2><a name="5程序进入前台时下载任务回调可能不执行的问题" class="md-header-anchor"></a><span>5.程序进入前台时,下载任务回调可能不执行的问题</span></h2><p><span>我们发现,在iOS12的系统下,app进入前台时,有极小的概率会发生下载的回调不执行的问题。若想临时解决这个问题,只需要在appDelegate的applicationDidBecomeActive:方法中,将正在下载的任务暂停,然后延迟1秒以后在重新开始下载即可。最终还要等待苹果官方解决此问题。</span></p><h2><a name="6当集成423-sdk时若出现" class="md-header-anchor"></a><span>6.当集成4.2.3 SDK时,若出现 </span></h2><p><span>Undefined symbols for architecture x84_64:</span></p><p><span> &quot;__isPlatformVersionAtLeast&quot;,referenced from;</span></p><p><span> ...</span></p><p><span> ...</span></p><p><span> ...</span></p><p><span>ld:symbol(s) not found for architecture x84_64</span></p><p><span>clane: error: linker command failed with exit code 1 (use -v to see invocation)</span></p><p><span>编译错误时,请升级4.2.4及以上版本SDK或升级最新的Xcode重新编译即可。</span></p><h2><a name="7升级480及以后版本编译报错的问题" class="md-header-anchor"></a><span>7.升级4.8.0及以后版本编译报错的问题</span></h2><p><span>&#39;DWxxx.h&#39; file not found错误分为以下两种情况:</span></p><p><span>1.DWSDK.h文件,原DWSDK.h现更名为CCVodSDK.h,使用#import &lt;CCVodSDK/CCVodSDK.h&gt;方式引入头文件。</span></p><p><span>2.其他SDK文件报错,由于SDK库类型的变化,引入方式修改为#import &lt;CCVodSDK/DWxxx.h&gt;;或删除全部引入异常的头文件,在项目pch文件中,引入#import &lt;CCVodSDK/CCVodSDK.h&gt;即可。</span></p><h2><a name="8集成点播sdk打包上线报错的问题" class="md-header-anchor"></a><span>8.集成点播SDK打包上线报错的问题</span></h2><p><span>关于打包上线过程中,不支持 x86_64 和 i386 等情况。错误描述如下:</span></p><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang=""><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><span><span></span>x</span></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">The following issues occurred while distributing your application.</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">App Store Connect Operation Error</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> ERROR ITMS-90097:"Unsupported Architectures. The executable for xxx.framework contains unsupported architectures '[x86_64]."</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> ...</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> App Store Connect Operation Error</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> ERROR ITMS-90097:"Unsupported Architectures. The executable for xxx.framework contains unsupported architectures '[x86_64,i386]."</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 286px;"></div><div class="CodeMirror-gutters" style="display: none; height: 286px;"></div></div></div></pre><p><span>解决方案:Target --&gt; Build Phases --&gt; 点击&quot;+&quot;按钮,选择&quot;New Run Script Phase&quot;,在 Run Script 内添加以下脚本方法,重新编译打包即可。</span></p><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang="" style="break-inside: unset;"><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"># This script loops through the frameworks embedded in the application and &nbsp;</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"># removes unused architectures. &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">APP_PATH="${TARGET_BUILD_DIR}/${WRAPPER_NAME}"</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-invalidchar" title="\u200b" aria-label="\u200b" cm-text="​"></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">find "$APP_PATH" -name '*.framework' -type d | while read -r FRAMEWORK &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">do &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">FRAMEWORK_EXECUTABLE_NAME=$(defaults read "$FRAMEWORK/Info.plist" CFBundleExecutable) &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">FRAMEWORK_EXECUTABLE_PATH="$FRAMEWORK/$FRAMEWORK_EXECUTABLE_NAME" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">echo "Executable is $FRAMEWORK_EXECUTABLE_PATH" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">EXTRACTED_ARCHS=() &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">for ARCH in $ARCHS &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">do &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">echo "Extracting $ARCH from $FRAMEWORK_EXECUTABLE_NAME" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">lipo -extract "$ARCH" "$FRAMEWORK_EXECUTABLE_PATH" -o "$FRAMEWORK_EXECUTABLE_PATH-$ARCH" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">EXTRACTED_ARCHS+=("$FRAMEWORK_EXECUTABLE_PATH-$ARCH") &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">done &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-invalidchar" title="\u200b" aria-label="\u200b" cm-text="​"></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">echo "Merging extracted architectures: ${ARCHS}" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">lipo -o "$FRAMEWORK_EXECUTABLE_PATH-merged" -create "${EXTRACTED_ARCHS[@]}" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">rm "${EXTRACTED_ARCHS[@]}" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">echo "Replacing original executable with thinned version" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">rm "$FRAMEWORK_EXECUTABLE_PATH" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mv "$FRAMEWORK_EXECUTABLE_PATH-merged" "$FRAMEWORK_EXECUTABLE_PATH" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">done</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 780px;"></div><div class="CodeMirror-gutters" style="display: none; height: 780px;"></div></div></div></pre><h2><a name="9关于使用cocoapods更新490及以上sdk编译报错的问题" class="md-header-anchor"></a><span>9.关于使用Cocoapods更新4.9.0及以上SDK编译报错的问题</span></h2><p><span>由于Xcode12的兼容性问题,在使用Cocoapods集成4.9.0及以上版本的SDK时,会导致如下编译错误</span></p><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang=""><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">dyld: Library not loaded: @rpath/HDBaseUtils.framework/HDBaseUtils</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> Referenced from: /private/var/containers/Bundle/Application/83A9ECB5-758F-4B99-90AA-56D4B0D835DC/xxx.app/xxx</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> Reason: image not found</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">dyld: launch, loading dependent libraries</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">DYLD_LIBRARY_PATH=/usr/lib/system/introspection</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">DYLD_INSERT_LIBRARIES=/Developer/usr/lib/libBacktraceRecording.dylib:/Developer/usr/lib/libMainThreadChecker.dylib:/Developer/Library/PrivateFrameworks/GPUTools.framework/libglInterpose.dylib:/usr/lib/libMTLCapture.dylib:/Developer/Library/PrivateFrameworks/DTDDISupport.framework/libViewDebuggerSupport.dylib</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Message from debugger: Terminated due to signal 6</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 286px;"></div><div class="CodeMirror-gutters" style="display: none; height: 286px;"></div></div></div></pre><p><span>解决方案:</span> <div id='write' class = ''><h1><a name="常见问题" class="md-header-anchor"></a><span>常见问题</span></h1><h2><a name="1dwplayinfo数据获取失败的问题" class="md-header-anchor"></a><span>1.DWPlayInfo数据获取失败的问题</span></h2><p><span>当遇到DWPlayInfo回调失败时,首先要排除userId、APIKEY是否有效,其次判断网络是否正常、是否已经连接、videoId是否是userId和APIKEY名下的视频。除此之外还可以通过HTTP通信日志排查问题。</span></p><h2><a name="2关于加密音视频的播放问题" class="md-header-anchor"></a><span>2.关于加密音视频的播放问题</span></h2><p><span>新版本中,对于原旧版本加密服务DWDrmServer的调用封装到了SDK内部,用户无需再对DWDrmServer服务进行操作,SDK会自动识别加密音视频进行播放。</span></p><h2><a name="3对于通过import-dwsdkh无法引入路径下的文件的问题" class="md-header-anchor"></a><span>3.对于通过#import &quot;DWSDK.h&quot;无法引入路径下的文件的问题</span></h2><p><span>找到TARGETS -&gt; Build Setting -&gt; Search Paths。添加</span><code>Header Search Path</code><span>,路径到SDK的文件夹下。若还无法找到,继续添加</span><code>User Header Search Path</code><span>即可。</span></p><h2><a name="4关于控制台频繁出现-nwconnectioncopyconnectedpath日志的问题" class="md-header-anchor"></a><span>4.关于控制台频繁出现&quot;[] nw_connection_copy_connected_path&quot;日志的问题</span></h2><p><span>找到Edit Scheme -&gt; Run -&gt; Arguments -&gt; Enviroment Variables,添加属性</span><code>OS_ACTIVITY_MODE</code><span>,设置为0即可。</span></p><h2><a name="5程序进入前台时下载任务回调可能不执行的问题" class="md-header-anchor"></a><span>5.程序进入前台时,下载任务回调可能不执行的问题</span></h2><p><span>我们发现,在iOS12的系统下,app进入前台时,有极小的概率会发生下载的回调不执行的问题。若想临时解决这个问题,只需要在appDelegate的applicationDidBecomeActive:方法中,将正在下载的任务暂停,然后延迟1秒以后在重新开始下载即可。最终还要等待苹果官方解决此问题。</span></p><h2><a name="6当集成423-sdk时若出现" class="md-header-anchor"></a><span>6.当集成4.2.3 SDK时,若出现 </span></h2><p><span>Undefined symbols for architecture x84_64:</span></p><p><span> &quot;__isPlatformVersionAtLeast&quot;,referenced from;</span></p><p><span> ...</span></p><p><span> ...</span></p><p><span> ...</span></p><p><span>ld:symbol(s) not found for architecture x84_64</span></p><p><span>clane: error: linker command failed with exit code 1 (use -v to see invocation)</span></p><p><span>编译错误时,请升级4.2.4及以上版本SDK或升级最新的Xcode重新编译即可。</span></p><h2><a name="7升级480及以后版本编译报错的问题" class="md-header-anchor"></a><span>7.升级4.8.0及以后版本编译报错的问题</span></h2><p><span>&#39;DWxxx.h&#39; file not found错误分为以下两种情况:</span></p><p><span>1.DWSDK.h文件,原DWSDK.h现更名为CCVodSDK.h,使用#import &lt;CCVodSDK/CCVodSDK.h&gt;方式引入头文件。</span></p><p><span>2.其他SDK文件报错,由于SDK库类型的变化,引入方式修改为#import &lt;CCVodSDK/DWxxx.h&gt;;或删除全部引入异常的头文件,在项目pch文件中,引入#import &lt;CCVodSDK/CCVodSDK.h&gt;即可。</span></p><h2><a name="8集成点播sdk打包上线报错的问题" class="md-header-anchor"></a><span>8.集成点播SDK打包上线报错的问题</span></h2><p><span>关于打包上线过程中,不支持 x86_64 和 i386 等情况。错误描述如下:</span></p><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang=""><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><span><span></span>x</span></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">The following issues occurred while distributing your application.</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">App Store Connect Operation Error</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> ERROR ITMS-90097:"Unsupported Architectures. The executable for xxx.framework contains unsupported architectures '[x86_64]."</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> ...</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> App Store Connect Operation Error</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> ERROR ITMS-90097:"Unsupported Architectures. The executable for xxx.framework contains unsupported architectures '[x86_64,i386]."</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 286px;"></div><div class="CodeMirror-gutters" style="display: none; height: 286px;"></div></div></div></pre><p><span>第一种解决方案:Target --&gt; Build Phases --&gt; 点击&quot;+&quot;按钮,选择&quot;New Run Script Phase&quot;,在 Run Script 内添加以下脚本方法,重新编译打包即可。</span></p><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang="" style="break-inside: unset;"><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"># This script loops through the frameworks embedded in the application and &nbsp;</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"># removes unused architectures. &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">APP_PATH="${TARGET_BUILD_DIR}/${WRAPPER_NAME}"</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-invalidchar" title="\u200b" aria-label="\u200b" cm-text="​"></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">find "$APP_PATH" -name '*.framework' -type d | while read -r FRAMEWORK &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">do &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">FRAMEWORK_EXECUTABLE_NAME=$(defaults read "$FRAMEWORK/Info.plist" CFBundleExecutable) &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">FRAMEWORK_EXECUTABLE_PATH="$FRAMEWORK/$FRAMEWORK_EXECUTABLE_NAME" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">echo "Executable is $FRAMEWORK_EXECUTABLE_PATH" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">EXTRACTED_ARCHS=() &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">for ARCH in $ARCHS &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">do &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">echo "Extracting $ARCH from $FRAMEWORK_EXECUTABLE_NAME" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">lipo -extract "$ARCH" "$FRAMEWORK_EXECUTABLE_PATH" -o "$FRAMEWORK_EXECUTABLE_PATH-$ARCH" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">EXTRACTED_ARCHS+=("$FRAMEWORK_EXECUTABLE_PATH-$ARCH") &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">done &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-invalidchar" title="\u200b" aria-label="\u200b" cm-text="​"></span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">echo "Merging extracted architectures: ${ARCHS}" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">lipo -o "$FRAMEWORK_EXECUTABLE_PATH-merged" -create "${EXTRACTED_ARCHS[@]}" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">rm "${EXTRACTED_ARCHS[@]}" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">echo "Replacing original executable with thinned version" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">rm "$FRAMEWORK_EXECUTABLE_PATH" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mv "$FRAMEWORK_EXECUTABLE_PATH-merged" "$FRAMEWORK_EXECUTABLE_PATH" &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">done</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text=""></span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 780px;"></div><div class="CodeMirror-gutters" style="display: none; height: 780px;"></div></div></div></pre><p><span>第二种解决方案,点播SDK4.14.2以以上版本试用:</span>
<span>1.对于手动集成用户,将项目中使用的点播SDK替换为include_Release中的,重新编译打包。</span>
<span>2.对于cocoapods集成的用户,将Podfile中pod &#39;CCVodSDK&#39;替换为pod &#39;CCVodSDK_Release&#39;,重新执行pod install,编译打包即可。</span></p><h2><a name="9关于使用cocoapods更新490及以上sdk编译报错的问题" class="md-header-anchor"></a><span>9.关于使用Cocoapods更新4.9.0及以上SDK编译报错的问题</span></h2><p><span>由于Xcode12的兼容性问题,在使用Cocoapods集成4.9.0及以上版本的SDK时,会导致如下编译错误</span></p><pre spellcheck="false" class="md-fences md-end-block ty-contain-cm modeLoaded" lang=""><div class="CodeMirror cm-s-inner CodeMirror-wrap" lang=""><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 0px; left: 4px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">dyld: Library not loaded: @rpath/HDBaseUtils.framework/HDBaseUtils</span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> Referenced from: /private/var/containers/Bundle/Application/83A9ECB5-758F-4B99-90AA-56D4B0D835DC/xxx.app/xxx</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> Reason: image not found</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">dyld: launch, loading dependent libraries</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">DYLD_LIBRARY_PATH=/usr/lib/system/introspection</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">DYLD_INSERT_LIBRARIES=/Developer/usr/lib/libBacktraceRecording.dylib:/Developer/usr/lib/libMainThreadChecker.dylib:/Developer/Library/PrivateFrameworks/GPUTools.framework/libglInterpose.dylib:/usr/lib/libMTLCapture.dylib:/Developer/Library/PrivateFrameworks/DTDDISupport.framework/libViewDebuggerSupport.dylib</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Message from debugger: Terminated due to signal 6</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom-width: 0px; border-bottom-style: solid; border-bottom-color: transparent; top: 286px;"></div><div class="CodeMirror-gutters" style="display: none; height: 286px;"></div></div></div></pre><p><span>解决方案:</span>
<span>第一步:项目 - TARGETS - Build Phases - Link Binary With Libraries - Add Other - Add Files.. 添加Pods/HDBaseUtils/HDBaseUtils/HDBaseUtils.framework、Pods/CCVodSDK/include/CCVodSDK.framework。</span></p><p><span>第二步:项目 - TARGETS - General - Frameworks.Libraries,and Embedded Content - 找到HDBaseUtils.framework、CCVodSDK.framework,将默认Do Not Embed修改为Embed &amp; Sign,即可。</span></p><h2><a name="10关于xcode123编译报but-the-linked-and-embedded-framework-xxxframework-was-built-for-ios--ios的错误" class="md-header-anchor"></a><span>10.关于Xcode12.3编译报but the linked and embedded framework &#39;xxx.framework&#39; was built for iOS + iOS的错误</span></h2><p><span>有两种解决方案,如下:</span> <span>第一步:项目 - TARGETS - Build Phases - Link Binary With Libraries - Add Other - Add Files.. 添加Pods/HDBaseUtils/HDBaseUtils/HDBaseUtils.framework、Pods/CCVodSDK/include/CCVodSDK.framework。</span></p><p><span>第二步:项目 - TARGETS - General - Frameworks.Libraries,and Embedded Content - 找到HDBaseUtils.framework、CCVodSDK.framework,将默认Do Not Embed修改为Embed &amp; Sign,即可。</span></p><h2><a name="10关于xcode123编译报but-the-linked-and-embedded-framework-xxxframework-was-built-for-ios--ios的错误" class="md-header-anchor"></a><span>10.关于Xcode12.3编译报but the linked and embedded framework &#39;xxx.framework&#39; was built for iOS + iOS的错误</span></h2><p><span>有两种解决方案,如下:</span>
<span>第一种解决方案:项目 - Target-Build Settings - Validate Workspace 设置成YES。</span> <span>第一种解决方案:项目 - Target-Build Settings - Validate Workspace 设置成YES。</span>
<span>第二种解决方案:项目 - File - Workspace Settings... - Build System 修改为旧的Legacy Build System (Deprecatied)。</span></p><p><span>更多信息请参考</span><a href='https://doc.bokecc.com'><span> “获得场景视频帮助中心”</span></a><span>,如果在使用SDK过程中遇到其他问题请联系获得场景视频客服进行反馈。</span></p></div> <span>第二种解决方案:项目 - File - Workspace Settings... - Build System 修改为旧的Legacy Build System (Deprecatied)。</span></p><p><span>更多信息请参考</span><a href='https://doc.bokecc.com'><span> “获得场景视频帮助中心”</span></a><span>,如果在使用SDK过程中遇到其他问题请联系获得场景视频客服进行反馈。</span></p></div>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment