shithub: openh264

Download patch

ref: 7e57d5205e67316300c7b3303c3082610cf3f59e
parent: 68ebf0540277e311898793d7d2c1a453f43db8b3
author: Licai Guo <[email protected]>
date: Fri Feb 21 09:43:09 EST 2014

Add decoder ios demo

--- a/codec/build/iOS/common/common/common-Prefix.pch
+++ b/codec/build/iOS/common/common/common-Prefix.pch
@@ -1,8 +1,34 @@
-//
-//  Prefix header
-//
-//  The contents of this file are implicitly included at the beginning of every source file.
-//
+/*!
+ * \copy
+ *     Copyright (c)  2013, Cisco Systems
+ *     All rights reserved.
+ *
+ *     Redistribution and use in source and binary forms, with or without
+ *     modification, are permitted provided that the following conditions
+ *     are met:
+ *
+ *        * Redistributions of source code must retain the above copyright
+ *          notice, this list of conditions and the following disclaimer.
+ *
+ *        * Redistributions in binary form must reproduce the above copyright
+ *          notice, this list of conditions and the following disclaimer in
+ *          the documentation and/or other materials provided with the
+ *          distribution.
+ *
+ *     THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ *     "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ *     LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ *     FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ *     COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ *     INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ *     BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ *     LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ *     CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ *     LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+ *     ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ *     POSSIBILITY OF SUCH DAMAGE.
+ *
+ */
 
 #ifdef __OBJC__
     #import <Foundation/Foundation.h>
--- a/codec/build/iOS/common/commonTests/commonTests.m
+++ b/codec/build/iOS/common/commonTests/commonTests.m
@@ -1,10 +1,34 @@
-//
-//  commonTests.m
-//  commonTests
-//
-//  Created by guangx on 14-2-21.
-//  Copyright (c) 2014年 video. All rights reserved.
-//
+/*!
+ * \copy
+ *     Copyright (c)  2013, Cisco Systems
+ *     All rights reserved.
+ *
+ *     Redistribution and use in source and binary forms, with or without
+ *     modification, are permitted provided that the following conditions
+ *     are met:
+ *
+ *        * Redistributions of source code must retain the above copyright
+ *          notice, this list of conditions and the following disclaimer.
+ *
+ *        * Redistributions in binary form must reproduce the above copyright
+ *          notice, this list of conditions and the following disclaimer in
+ *          the documentation and/or other materials provided with the
+ *          distribution.
+ *
+ *     THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ *     "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ *     LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ *     FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ *     COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ *     INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ *     BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ *     LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ *     CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ *     LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+ *     ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ *     POSSIBILITY OF SUCH DAMAGE.
+ *
+ */
 
 #import <XCTest/XCTest.h>
 
--- a/codec/build/iOS/dec/demo/demo.xcodeproj/project.pbxproj
+++ b/codec/build/iOS/dec/demo/demo.xcodeproj/project.pbxproj
@@ -7,6 +7,8 @@
 	objects = {
 
 /* Begin PBXBuildFile section */
+		4CE444F918B72AA40017DF25 /* libcommon.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 4CE444F618B72A900017DF25 /* libcommon.a */; };
+		4CE4450318B72AE40017DF25 /* libwelsdec.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 4CE4450018B72AD70017DF25 /* libwelsdec.a */; };
 		F0E6634A1810EFA5000C888E /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F0E663491810EFA5000C888E /* UIKit.framework */; };
 		F0E6634C1810EFA5000C888E /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F0E6634B1810EFA5000C888E /* Foundation.framework */; };
 		F0E6634E1810EFA5000C888E /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F0E6634D1810EFA5000C888E /* CoreGraphics.framework */; };
@@ -22,21 +24,43 @@
 		F0E6637A1810EFF7000C888E /* d3d9_utils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F0E663761810EFF7000C888E /* d3d9_utils.cpp */; };
 		F0E6637B1810EFF7000C888E /* h264dec.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F0E663771810EFF7000C888E /* h264dec.cpp */; };
 		F0E6637D1810EFF7000C888E /* read_config.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F0E663791810EFF7000C888E /* read_config.cpp */; };
-		F0E663841810F01D000C888E /* libwelsdec.a in Frameworks */ = {isa = PBXBuildFile; fileRef = F0E663831810F012000C888E /* libwelsdec.a */; };
 		F0E663B5181117B9000C888E /* DEMOViewControllerShowResource.m in Sources */ = {isa = PBXBuildFile; fileRef = F0E663B4181117B9000C888E /* DEMOViewControllerShowResource.m */; };
 /* End PBXBuildFile section */
 
 /* Begin PBXContainerItemProxy section */
-		F0E663821810F012000C888E /* PBXContainerItemProxy */ = {
+		4CE444F518B72A900017DF25 /* PBXContainerItemProxy */ = {
 			isa = PBXContainerItemProxy;
-			containerPortal = F0E6637E1810F012000C888E /* h264svcdec.xcodeproj */;
+			containerPortal = 4CE444F018B72A8F0017DF25 /* common.xcodeproj */;
 			proxyType = 2;
-			remoteGlobalIDString = D2AAC07E0554694100DB518D;
-			remoteInfo = h264svcdec;
+			remoteGlobalIDString = 4CE443D518B722CD0017DF25;
+			remoteInfo = common;
 		};
+		4CE444F718B72A900017DF25 /* PBXContainerItemProxy */ = {
+			isa = PBXContainerItemProxy;
+			containerPortal = 4CE444F018B72A8F0017DF25 /* common.xcodeproj */;
+			proxyType = 2;
+			remoteGlobalIDString = 4CE443E518B722CD0017DF25;
+			remoteInfo = commonTests;
+		};
+		4CE444FF18B72AD70017DF25 /* PBXContainerItemProxy */ = {
+			isa = PBXContainerItemProxy;
+			containerPortal = 4CE444FA18B72AD70017DF25 /* welsdec.xcodeproj */;
+			proxyType = 2;
+			remoteGlobalIDString = 4CE4427918B6FC360017DF25;
+			remoteInfo = welsdec;
+		};
+		4CE4450118B72AD70017DF25 /* PBXContainerItemProxy */ = {
+			isa = PBXContainerItemProxy;
+			containerPortal = 4CE444FA18B72AD70017DF25 /* welsdec.xcodeproj */;
+			proxyType = 2;
+			remoteGlobalIDString = 4CE4428918B6FC360017DF25;
+			remoteInfo = welsdecTests;
+		};
 /* End PBXContainerItemProxy section */
 
 /* Begin PBXFileReference section */
+		4CE444F018B72A8F0017DF25 /* common.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = common.xcodeproj; path = ../../common/common.xcodeproj; sourceTree = "<group>"; };
+		4CE444FA18B72AD70017DF25 /* welsdec.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = welsdec.xcodeproj; path = ../welsdec/welsdec.xcodeproj; sourceTree = "<group>"; };
 		F0E663461810EFA5000C888E /* demo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = demo.app; sourceTree = BUILT_PRODUCTS_DIR; };
 		F0E663491810EFA5000C888E /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
 		F0E6634B1810EFA5000C888E /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
@@ -59,7 +83,6 @@
 		F0E663761810EFF7000C888E /* d3d9_utils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = d3d9_utils.cpp; sourceTree = "<group>"; };
 		F0E663771810EFF7000C888E /* h264dec.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = h264dec.cpp; sourceTree = "<group>"; };
 		F0E663791810EFF7000C888E /* read_config.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = read_config.cpp; sourceTree = "<group>"; };
-		F0E6637E1810F012000C888E /* h264svcdec.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = h264svcdec.xcodeproj; path = ../h264svcdec/h264svcdec.xcodeproj; sourceTree = "<group>"; };
 		F0E663B3181117B9000C888E /* DEMOViewControllerShowResource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DEMOViewControllerShowResource.h; sourceTree = "<group>"; };
 		F0E663B4181117B9000C888E /* DEMOViewControllerShowResource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DEMOViewControllerShowResource.m; sourceTree = "<group>"; };
 /* End PBXFileReference section */
@@ -69,7 +92,8 @@
 			isa = PBXFrameworksBuildPhase;
 			buildActionMask = 2147483647;
 			files = (
-				F0E663841810F01D000C888E /* libwelsdec.a in Frameworks */,
+				4CE4450318B72AE40017DF25 /* libwelsdec.a in Frameworks */,
+				4CE444F918B72AA40017DF25 /* libcommon.a in Frameworks */,
 				F0E6634A1810EFA5000C888E /* UIKit.framework in Frameworks */,
 				F0E6634C1810EFA5000C888E /* Foundation.framework in Frameworks */,
 				F0E6634E1810EFA5000C888E /* CoreGraphics.framework in Frameworks */,
@@ -79,6 +103,24 @@
 /* End PBXFrameworksBuildPhase section */
 
 /* Begin PBXGroup section */
+		4CE444F118B72A8F0017DF25 /* Products */ = {
+			isa = PBXGroup;
+			children = (
+				4CE444F618B72A900017DF25 /* libcommon.a */,
+				4CE444F818B72A900017DF25 /* commonTests.xctest */,
+			);
+			name = Products;
+			sourceTree = "<group>";
+		};
+		4CE444FB18B72AD70017DF25 /* Products */ = {
+			isa = PBXGroup;
+			children = (
+				4CE4450018B72AD70017DF25 /* libwelsdec.a */,
+				4CE4450218B72AD70017DF25 /* welsdecTests.xctest */,
+			);
+			name = Products;
+			sourceTree = "<group>";
+		};
 		F0E6633D1810EFA5000C888E = {
 			isa = PBXGroup;
 			children = (
@@ -99,7 +141,8 @@
 		F0E663481810EFA5000C888E /* Frameworks */ = {
 			isa = PBXGroup;
 			children = (
-				F0E6637E1810F012000C888E /* h264svcdec.xcodeproj */,
+				4CE444FA18B72AD70017DF25 /* welsdec.xcodeproj */,
+				4CE444F018B72A8F0017DF25 /* common.xcodeproj */,
 				F0E663491810EFA5000C888E /* UIKit.framework */,
 				F0E6634B1810EFA5000C888E /* Foundation.framework */,
 				F0E6634D1810EFA5000C888E /* CoreGraphics.framework */,
@@ -167,14 +210,6 @@
 			path = src;
 			sourceTree = "<group>";
 		};
-		F0E6637F1810F012000C888E /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				F0E663831810F012000C888E /* libwelsdec.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
 /* End PBXGroup section */
 
 /* Begin PBXNativeTarget section */
@@ -217,9 +252,13 @@
 			projectDirPath = "";
 			projectReferences = (
 				{
-					ProductGroup = F0E6637F1810F012000C888E /* Products */;
-					ProjectRef = F0E6637E1810F012000C888E /* h264svcdec.xcodeproj */;
+					ProductGroup = 4CE444F118B72A8F0017DF25 /* Products */;
+					ProjectRef = 4CE444F018B72A8F0017DF25 /* common.xcodeproj */;
 				},
+				{
+					ProductGroup = 4CE444FB18B72AD70017DF25 /* Products */;
+					ProjectRef = 4CE444FA18B72AD70017DF25 /* welsdec.xcodeproj */;
+				},
 			);
 			projectRoot = "";
 			targets = (
@@ -229,13 +268,34 @@
 /* End PBXProject section */
 
 /* Begin PBXReferenceProxy section */
-		F0E663831810F012000C888E /* libwelsdec.a */ = {
+		4CE444F618B72A900017DF25 /* libcommon.a */ = {
 			isa = PBXReferenceProxy;
 			fileType = archive.ar;
+			path = libcommon.a;
+			remoteRef = 4CE444F518B72A900017DF25 /* PBXContainerItemProxy */;
+			sourceTree = BUILT_PRODUCTS_DIR;
+		};
+		4CE444F818B72A900017DF25 /* commonTests.xctest */ = {
+			isa = PBXReferenceProxy;
+			fileType = wrapper.cfbundle;
+			path = commonTests.xctest;
+			remoteRef = 4CE444F718B72A900017DF25 /* PBXContainerItemProxy */;
+			sourceTree = BUILT_PRODUCTS_DIR;
+		};
+		4CE4450018B72AD70017DF25 /* libwelsdec.a */ = {
+			isa = PBXReferenceProxy;
+			fileType = archive.ar;
 			path = libwelsdec.a;
-			remoteRef = F0E663821810F012000C888E /* PBXContainerItemProxy */;
+			remoteRef = 4CE444FF18B72AD70017DF25 /* PBXContainerItemProxy */;
 			sourceTree = BUILT_PRODUCTS_DIR;
 		};
+		4CE4450218B72AD70017DF25 /* welsdecTests.xctest */ = {
+			isa = PBXReferenceProxy;
+			fileType = wrapper.cfbundle;
+			path = welsdecTests.xctest;
+			remoteRef = 4CE4450118B72AD70017DF25 /* PBXContainerItemProxy */;
+			sourceTree = BUILT_PRODUCTS_DIR;
+		};
 /* End PBXReferenceProxy section */
 
 /* Begin PBXResourcesBuildPhase section */
@@ -360,6 +420,9 @@
 		F0E6636D1810EFA5000C888E /* Debug */ = {
 			isa = XCBuildConfiguration;
 			buildSettings = {
+				CLANG_CXX_LANGUAGE_STANDARD = "compiler-default";
+				CLANG_CXX_LIBRARY = "compiler-default";
+				CODE_SIGN_IDENTITY = "iPhone Developer";
 				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
 				GCC_C_LANGUAGE_STANDARD = "compiler-default";
 				GCC_PRECOMPILE_PREFIX_HEADER = YES;
@@ -381,6 +444,9 @@
 		F0E6636E1810EFA5000C888E /* Release */ = {
 			isa = XCBuildConfiguration;
 			buildSettings = {
+				CLANG_CXX_LANGUAGE_STANDARD = "compiler-default";
+				CLANG_CXX_LIBRARY = "compiler-default";
+				CODE_SIGN_IDENTITY = "iPhone Developer";
 				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
 				GCC_C_LANGUAGE_STANDARD = "compiler-default";
 				GCC_PRECOMPILE_PREFIX_HEADER = YES;
--- a/codec/build/iOS/dec/welsdec/welsdec/welsdec-Prefix.pch
+++ b/codec/build/iOS/dec/welsdec/welsdec/welsdec-Prefix.pch
@@ -1,8 +1,34 @@
-//
-//  Prefix header
-//
-//  The contents of this file are implicitly included at the beginning of every source file.
-//
+/*!
+ * \copy
+ *     Copyright (c)  2013, Cisco Systems
+ *     All rights reserved.
+ *
+ *     Redistribution and use in source and binary forms, with or without
+ *     modification, are permitted provided that the following conditions
+ *     are met:
+ *
+ *        * Redistributions of source code must retain the above copyright
+ *          notice, this list of conditions and the following disclaimer.
+ *
+ *        * Redistributions in binary form must reproduce the above copyright
+ *          notice, this list of conditions and the following disclaimer in
+ *          the documentation and/or other materials provided with the
+ *          distribution.
+ *
+ *     THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ *     "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ *     LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ *     FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ *     COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ *     INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ *     BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ *     LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ *     CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ *     LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+ *     ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ *     POSSIBILITY OF SUCH DAMAGE.
+ *
+ */
 
 #ifdef __OBJC__
     #import <Foundation/Foundation.h>
--- a/codec/build/iOS/dec/welsdec/welsdecTests/welsdecTests.m
+++ b/codec/build/iOS/dec/welsdec/welsdecTests/welsdecTests.m
@@ -1,10 +1,34 @@
-//
-//  welsdecTests.m
-//  welsdecTests
-//
-//  Created by guangx on 14-2-21.
-//  Copyright (c) 2014年 video. All rights reserved.
-//
+/*!
+ * \copy
+ *     Copyright (c)  2013, Cisco Systems
+ *     All rights reserved.
+ *
+ *     Redistribution and use in source and binary forms, with or without
+ *     modification, are permitted provided that the following conditions
+ *     are met:
+ *
+ *        * Redistributions of source code must retain the above copyright
+ *          notice, this list of conditions and the following disclaimer.
+ *
+ *        * Redistributions in binary form must reproduce the above copyright
+ *          notice, this list of conditions and the following disclaimer in
+ *          the documentation and/or other materials provided with the
+ *          distribution.
+ *
+ *     THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ *     "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ *     LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ *     FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ *     COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ *     INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ *     BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ *     LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ *     CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ *     LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+ *     ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ *     POSSIBILITY OF SUCH DAMAGE.
+ *
+ */
 
 #import <XCTest/XCTest.h>