diff --git a/HaishinKit.xcodeproj/project.pbxproj b/HaishinKit.xcodeproj/project.pbxproj index fc3752469..31bc20c09 100644 --- a/HaishinKit.xcodeproj/project.pbxproj +++ b/HaishinKit.xcodeproj/project.pbxproj @@ -227,11 +227,8 @@ BCA3A5252BC4ED220083BBB1 /* RTMPTimestamp.swift in Sources */ = {isa = PBXBuildFile; fileRef = BCA3A5242BC4ED220083BBB1 /* RTMPTimestamp.swift */; }; BCA3A5272BC507880083BBB1 /* RTMPTimestampTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = BCA3A5262BC507880083BBB1 /* RTMPTimestampTests.swift */; }; BCA7C24F2A91AA0500882D85 /* IOStreamRecorderTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = BCA7C24E2A91AA0500882D85 /* IOStreamRecorderTests.swift */; }; - BCAD0C18263ED67F00ADFB80 /* SampleVideo_360x240_5mb@m4v.m3u8 in Resources */ = {isa = PBXBuildFile; fileRef = BCAD0C16263ED67F00ADFB80 /* SampleVideo_360x240_5mb@m4v.m3u8 */; }; - BCAD0C19263ED67F00ADFB80 /* SampleVideo_360x240_5mb@m4v in Resources */ = {isa = PBXBuildFile; fileRef = BCAD0C17263ED67F00ADFB80 /* SampleVideo_360x240_5mb@m4v */; }; BCB976DF26107B5600C9A649 /* TSField.swift in Sources */ = {isa = PBXBuildFile; fileRef = BCB976DE26107B5600C9A649 /* TSField.swift */; }; BCB9773F2621812800C9A649 /* AVCFormatStream.swift in Sources */ = {isa = PBXBuildFile; fileRef = BCB9773E2621812800C9A649 /* AVCFormatStream.swift */; }; - BCC1A7212648540800661156 /* RPReplay_Final1620580691.mp4 in Resources */ = {isa = PBXBuildFile; fileRef = BCC1A7202648540800661156 /* RPReplay_Final1620580691.mp4 */; }; BCC1A72B264FAC1800661156 /* ESSpecificData.swift in Sources */ = {isa = PBXBuildFile; fileRef = BCC1A72A264FAC1800661156 /* ESSpecificData.swift */; }; BCC4F4152AD6FC1100954EF5 /* IOTellyUnit.swift in Sources */ = {isa = PBXBuildFile; fileRef = BCC4F4142AD6FC1100954EF5 /* IOTellyUnit.swift */; }; BCC4F43D2ADB966800954EF5 /* NetStreamSwitcher.swift in Sources */ = {isa = PBXBuildFile; fileRef = BCE0E33B2AD369410082C16F /* NetStreamSwitcher.swift */; }; @@ -647,11 +644,8 @@ BCA3A5242BC4ED220083BBB1 /* RTMPTimestamp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RTMPTimestamp.swift; sourceTree = ""; }; BCA3A5262BC507880083BBB1 /* RTMPTimestampTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RTMPTimestampTests.swift; sourceTree = ""; }; BCA7C24E2A91AA0500882D85 /* IOStreamRecorderTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = IOStreamRecorderTests.swift; sourceTree = ""; }; - BCAD0C16263ED67F00ADFB80 /* SampleVideo_360x240_5mb@m4v.m3u8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = "SampleVideo_360x240_5mb@m4v.m3u8"; sourceTree = ""; }; - BCAD0C17263ED67F00ADFB80 /* SampleVideo_360x240_5mb@m4v */ = {isa = PBXFileReference; lastKnownFileType = folder; path = "SampleVideo_360x240_5mb@m4v"; sourceTree = ""; }; BCB976DE26107B5600C9A649 /* TSField.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSField.swift; sourceTree = ""; }; BCB9773E2621812800C9A649 /* AVCFormatStream.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AVCFormatStream.swift; sourceTree = ""; }; - BCC1A7202648540800661156 /* RPReplay_Final1620580691.mp4 */ = {isa = PBXFileReference; lastKnownFileType = file; path = RPReplay_Final1620580691.mp4; sourceTree = ""; }; BCC1A72A264FAC1800661156 /* ESSpecificData.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ESSpecificData.swift; sourceTree = ""; }; BCC4F4142AD6FC1100954EF5 /* IOTellyUnit.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = IOTellyUnit.swift; sourceTree = ""; }; BCC9E9082636FF7400948774 /* DataBufferTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DataBufferTests.swift; sourceTree = ""; }; @@ -871,13 +865,10 @@ 291C2AD11CE9FF3E006F042B /* Asset */ = { isa = PBXGroup; children = ( - BCC1A7202648540800661156 /* RPReplay_Final1620580691.mp4 */, 29B876D71CD70CE700FC07DA /* SampleVideo_360x240_5mb */, 294637A91EC8A79F008EEC71 /* SampleVideo_360x240_5mb.flv */, 29B876D81CD70CE700FC07DA /* SampleVideo_360x240_5mb.m3u8 */, 29B876D91CD70CE700FC07DA /* SampleVideo_360x240_5mb.mp4 */, - BCAD0C17263ED67F00ADFB80 /* SampleVideo_360x240_5mb@m4v */, - BCAD0C16263ED67F00ADFB80 /* SampleVideo_360x240_5mb@m4v.m3u8 */, BCFF640A29C0C44B004EFF2F /* SampleVideo_360x240_5mb_2ch.ts */, ); path = Asset; @@ -1592,14 +1583,11 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( - BCC1A7212648540800661156 /* RPReplay_Final1620580691.mp4 in Resources */, BCFF640B29C0C44B004EFF2F /* SampleVideo_360x240_5mb_2ch.ts in Resources */, - BCAD0C19263ED67F00ADFB80 /* SampleVideo_360x240_5mb@m4v in Resources */, 294637AA1EC8A79F008EEC71 /* SampleVideo_360x240_5mb.flv in Resources */, 29798E751CE614FE00F5CBD0 /* SampleVideo_360x240_5mb in Resources */, 29798E761CE614FE00F5CBD0 /* SampleVideo_360x240_5mb.m3u8 in Resources */, 29798E771CE614FE00F5CBD0 /* SampleVideo_360x240_5mb.mp4 in Resources */, - BCAD0C18263ED67F00ADFB80 /* SampleVideo_360x240_5mb@m4v.m3u8 in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; diff --git a/Tests/Asset/RPReplay_Final1620580691.mp4 b/Tests/Asset/RPReplay_Final1620580691.mp4 deleted file mode 100644 index 9816fc622..000000000 Binary files a/Tests/Asset/RPReplay_Final1620580691.mp4 and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v.m3u8 b/Tests/Asset/SampleVideo_360x240_5mb@m4v.m3u8 deleted file mode 100644 index 08fc759ab..000000000 --- a/Tests/Asset/SampleVideo_360x240_5mb@m4v.m3u8 +++ /dev/null @@ -1,30 +0,0 @@ -#EXTM3U -#EXT-X-VERSION:7 -#EXT-X-TARGETDURATION:6 -#EXT-X-MEDIA-SEQUENCE:0 -#EXT-X-PLAYLIST-TYPE:EVENT -#EXT-X-MAP:URI="SampleVideo_360x240_5mb@m4v/init.mp4" -#EXT-X-DISCONTINUITY -#EXTINF:6.000000, -SampleVideo_360x240_5mb@m4v/0.m4s -#EXTINF:6.000000, -SampleVideo_360x240_5mb@m4v/1.m4s -#EXTINF:6.000000, -SampleVideo_360x240_5mb@m4v/2.m4s -#EXTINF:6.000000, -SampleVideo_360x240_5mb@m4v/3.m4s -#EXTINF:6.000000, -SampleVideo_360x240_5mb@m4v/4.m4s -#EXTINF:6.000000, -SampleVideo_360x240_5mb@m4v/5.m4s -#EXTINF:6.000000, -SampleVideo_360x240_5mb@m4v/6.m4s -#EXTINF:6.000000, -SampleVideo_360x240_5mb@m4v/7.m4s -#EXTINF:6.000000, -SampleVideo_360x240_5mb@m4v/8.m4s -#EXTINF:6.000000, -SampleVideo_360x240_5mb@m4v/9.m4s -#EXTINF:4.866667, -SampleVideo_360x240_5mb@m4v/10.m4s -#EXT-X-ENDLIST diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/0.m4s b/Tests/Asset/SampleVideo_360x240_5mb@m4v/0.m4s deleted file mode 100644 index a8909ccdc..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/0.m4s and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/1.m4s b/Tests/Asset/SampleVideo_360x240_5mb@m4v/1.m4s deleted file mode 100644 index 470c18e38..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/1.m4s and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/10.m4s b/Tests/Asset/SampleVideo_360x240_5mb@m4v/10.m4s deleted file mode 100644 index 1aefb3fb6..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/10.m4s and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/2.m4s b/Tests/Asset/SampleVideo_360x240_5mb@m4v/2.m4s deleted file mode 100644 index c7934c427..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/2.m4s and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/3.m4s b/Tests/Asset/SampleVideo_360x240_5mb@m4v/3.m4s deleted file mode 100644 index 94225375e..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/3.m4s and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/4.m4s b/Tests/Asset/SampleVideo_360x240_5mb@m4v/4.m4s deleted file mode 100644 index 8d6dcff69..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/4.m4s and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/5.m4s b/Tests/Asset/SampleVideo_360x240_5mb@m4v/5.m4s deleted file mode 100644 index ad2b5bbcb..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/5.m4s and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/6.m4s b/Tests/Asset/SampleVideo_360x240_5mb@m4v/6.m4s deleted file mode 100644 index 4e79095c5..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/6.m4s and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/7.m4s b/Tests/Asset/SampleVideo_360x240_5mb@m4v/7.m4s deleted file mode 100644 index a4d9ca6c2..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/7.m4s and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/8.m4s b/Tests/Asset/SampleVideo_360x240_5mb@m4v/8.m4s deleted file mode 100644 index 35d32a3ad..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/8.m4s and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/9.m4s b/Tests/Asset/SampleVideo_360x240_5mb@m4v/9.m4s deleted file mode 100644 index 3e908b63d..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/9.m4s and /dev/null differ diff --git a/Tests/Asset/SampleVideo_360x240_5mb@m4v/init.mp4 b/Tests/Asset/SampleVideo_360x240_5mb@m4v/init.mp4 deleted file mode 100644 index 532bb2eec..000000000 Binary files a/Tests/Asset/SampleVideo_360x240_5mb@m4v/init.mp4 and /dev/null differ diff --git a/Tests/ISO/TSReaderTests.swift b/Tests/ISO/TSReaderTests.swift index 4c3ffa619..12a66ffc1 100644 --- a/Tests/ISO/TSReaderTests.swift +++ b/Tests/ISO/TSReaderTests.swift @@ -13,7 +13,7 @@ final class TSReaderTests: XCTestCase { do { let readerDelegate = TSReaderAudioCodec() let fileHandle = try FileHandle(forReadingFrom: url) - let reader = TSReader() + let reader = TSReader() reader.delegate = readerDelegate _ = reader.read(fileHandle.readDataToEndOfFile()) } catch { @@ -30,11 +30,11 @@ private final class TSReaderAudioCodec: TSReaderDelegate, AudioCodecDelegate { audioCodec.startRunning() } - func reader(_ reader: HaishinKit.TSReader, id: UInt16, didRead formatDescription: CMFormatDescription) { + func reader(_ reader: TSReader, id: UInt16, didRead formatDescription: CMFormatDescription) { audioCodec.inputFormat = AVAudioFormat(cmAudioFormatDescription: formatDescription) } - func reader(_ reader: HaishinKit.TSReader, id: UInt16, didRead sampleBuffer: CMSampleBuffer) { + func reader(_ reader: TSReader, id: UInt16, didRead sampleBuffer: CMSampleBuffer) { if sampleBuffer.formatDescription?.mediaType == .audio { audioCodec.append(sampleBuffer) }