Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

fixes to ofxiPhone to use ios for all libs. #ifdef for 4.3 SDK to mak…

…e backwards compatible. Closes #1179 Closes #1087 Closes #1086 Closes #1088
  • Loading branch information...
commit 023826e8465443847a6b03cdea68780317f05fb1 1 parent b44e877
@ofTheo ofTheo authored
View
2  addons/ofxiPhone/src/ES1Renderer.h
@@ -28,6 +28,8 @@
- (void) startRender;
- (void) finishRender;
+- (void)destroyFramebuffer;
+- (BOOL)createFramebuffer:(CAEAGLLayer *)layer;
- (BOOL)resizeFromLayer:(CAEAGLLayer *)layer;
- (id)initWithDepth:(bool)depth andAA:(bool)fsaa andFSAASamples:(int)samples andRetina:(bool)retina;
- (EAGLContext*) context;
View
2  addons/ofxiPhone/src/ofxiPhoneAppDelegate.h
@@ -48,11 +48,13 @@
-(void) receivedRotate:(NSNotification*)notification;
+#ifdef __IPHONE_4_3
-(BOOL) createExternalWindowWithPreferredMode;
-(BOOL) createExternalWindowWithScreenModeIndex:(NSInteger)screenModeIndex;
-(BOOL) destroyExternalWindow;
-(BOOL) displayOnScreenWithIndex:(NSInteger)screenIndex
andScreenModeIndex:(NSInteger)screenModeIndex;
+#endif
@end
View
9 addons/ofxiPhone/src/ofxiPhoneAppDelegate.mm
@@ -99,6 +99,8 @@ -(void) applicationDidFinishLaunching:(UIApplication *)application {
[self.window insertSubview:self.glViewController.view atIndex:0]; // make sure it is the bottom most view.
}
+ #ifdef __IPHONE_4_3
+
/**
* check if external display is connected.
* if so, create an external window for it.
@@ -108,6 +110,8 @@ -(void) applicationDidFinishLaunching:(UIApplication *)application {
[self createExternalWindowWithPreferredMode]; // create external window as soon as external screen is connected to prevent unwanted mirroring.
ofxiPhoneExternalDisplay::alertExternalDisplayConnected(); // alert any OF apps listening for a new external device.
}
+
+ #endif
}
@@ -158,6 +162,8 @@ - (BOOL)application:(UIApplication *)application handleOpenURL:(NSURL *)url {
return YES;
}
+#ifdef __IPHONE_4_3
+
/**
*
* Below are methods that manage the external display.
@@ -206,6 +212,7 @@ -(BOOL) createExternalWindowWithPreferredMode {
return YES;
}
+
//-------------------------------------------------------------------------------------------
-(BOOL) createExternalWindowWithScreenModeIndex:(NSInteger)screenModeIndex {
if([[UIScreen screens] count] == 1){
@@ -288,4 +295,6 @@ -(BOOL) displayOnScreenWithIndex:(NSInteger)screenIndex
return YES;
}
+#endif
+
@end
View
6 addons/ofxiPhone/src/ofxiPhoneExternalDisplay.h
@@ -9,6 +9,8 @@
#import "ofMain.h"
+#ifdef __IPHONE_4_3
+
struct ofxiPhoneExternalDisplayMode{
int width;
int height;
@@ -47,4 +49,6 @@ class ofxiPhoneExternalDisplay {
virtual void externalDisplayDisconnected(){}
virtual void externalDisplayChanged(){}
-};
+};
+
+#endif
View
4 addons/ofxiPhone/src/ofxiPhoneExternalDisplay.mm
@@ -8,6 +8,8 @@
#include "ofxiPhoneExternalDisplay.h"
#include "ofxiPhoneAppDelegate.h"
+#ifdef __IPHONE_4_3
+
//-----------------------------------------------------------------------------------------
static vector<ofxiPhoneExternalDisplay *> externalDisplayListeners;
@@ -180,3 +182,5 @@
}
}
}
+
+#endif
View
0  libs/glu/lib/iphone/glu-iphone.a → libs/glu/lib/ios/glu-ios.a
File renamed without changes
View
0  libs/glu/lib/iphone/glu.a → libs/glu/lib/ios/glu.a
File renamed without changes
View
2  libs/openFrameworksCompiled/project/ios/CoreOF.xcconfig
@@ -27,7 +27,7 @@ LIB_POCONET_IPHONE = "$(OF_PATH)/libs/poco/lib/ios/PocoNet.a"
LIB_POCOUTIL_IPHONE = "$(OF_PATH)/libs/poco/lib/ios/PocoUtil.a"
LIB_POCOXML_IPHONE = "$(OF_PATH)/libs/poco/lib/ios/PocoXML.a"
LIB_TESS_IPHONE = "$(OF_PATH)/libs/tess2/lib/ios/tess2.a"
-LIB_GLU_IPHONE = "$(OF_PATH)/libs/glu/lib/ios/glu-iphone.a"
+LIB_GLU_IPHONE = "$(OF_PATH)/libs/glu/lib/ios/glu-ios.a"
MISC_FLAGS = "-ObjC"
View
16 libs/openFrameworksCompiled/project/ios/iOS+OFLib.xcodeproj/project.pbxproj
@@ -203,7 +203,7 @@
772C251B146927A400DDAAE6 /* ofFmodSoundPlayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ofFmodSoundPlayer.h; sourceTree = "<group>"; };
BB16EBD10F2B2A9500518274 /* OpenGLES.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGLES.framework; path = System/Library/Frameworks/OpenGLES.framework; sourceTree = SDKROOT; };
BB16EBD80F2B2AB500518274 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; };
- BB24DED610DA7A3F00E9C588 /* libofxiPhone_iphonesimulator_Debug.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libofxiPhone_iphonesimulator_Debug.a; sourceTree = BUILT_PRODUCTS_DIR; };
+ BB24DED610DA7A3F00E9C588 /* libofxiPhone_iphoneos_Debug.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libofxiPhone_iphoneos_Debug.a; sourceTree = BUILT_PRODUCTS_DIR; };
BB24E01D10DA7C6100E9C588 /* changelog.txt */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = changelog.txt; sourceTree = "<group>"; };
BB24E01E10DA7C6100E9C588 /* install.xml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = install.xml; sourceTree = "<group>"; };
BB24E01F10DA7C6100E9C588 /* LICENSE.txt */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = LICENSE.txt; sourceTree = "<group>"; };
@@ -391,7 +391,7 @@
19C28FACFE9D520D11CA2CBB /* Products */ = {
isa = PBXGroup;
children = (
- BB24DED610DA7A3F00E9C588 /* libofxiPhone_iphonesimulator_Debug.a */,
+ BB24DED610DA7A3F00E9C588 /* libofxiPhone_iphoneos_Debug.a */,
);
name = Products;
sourceTree = "<group>";
@@ -881,7 +881,7 @@
);
name = "iPhone+OF Static Library";
productName = "Static Library";
- productReference = BB24DED610DA7A3F00E9C588 /* libofxiPhone_iphonesimulator_Debug.a */;
+ productReference = BB24DED610DA7A3F00E9C588 /* libofxiPhone_iphoneos_Debug.a */;
productType = "com.apple.product-type.library.static";
};
/* End PBXNativeTarget section */
@@ -1010,6 +1010,7 @@
);
PREBINDING = NO;
PRODUCT_NAME = "ofxiPhone_${PLATFORM_NAME}_Debug";
+ SDKROOT = iphoneos;
SKIP_INSTALL = YES;
};
name = Debug;
@@ -1034,6 +1035,7 @@
);
PREBINDING = NO;
PRODUCT_NAME = "ofxiPhone_${PLATFORM_NAME}_Release";
+ SDKROOT = iphoneos;
SKIP_INSTALL = YES;
ZERO_LINK = NO;
};
@@ -1044,8 +1046,12 @@
baseConfigurationReference = E41D3E9113B38BE900A75A5D /* Debug.xcconfig */;
buildSettings = {
ARCHS = "$(ARCHS_STANDARD_32_BIT)";
+ CONFIGURATION_BUILD_DIR = "$(SRCROOT)/../../lib/ios/";
+ CONFIGURATION_TEMP_DIR = "$(SRCROOT)/../../lib/ios/build/debug/";
GCC_WARN_CHECK_SWITCH_STATEMENTS = NO;
+ OBJROOT = "$(SRCROOT)/../../lib/ios/build/debug";
SDKROOT = iphoneos;
+ SYMROOT = "$(SRCROOT)/../../lib/ios/";
WARNING_CFLAGS = (
"-Wno-non-virtual-dtor",
"-Wno-overloaded-virtual",
@@ -1058,8 +1064,12 @@
baseConfigurationReference = E41D3E9213B38BE900A75A5D /* Release.xcconfig */;
buildSettings = {
ARCHS = "$(ARCHS_STANDARD_32_BIT)";
+ CONFIGURATION_BUILD_DIR = "$(SRCROOT)/../../lib/ios/";
+ CONFIGURATION_TEMP_DIR = "$(SRCROOT)/../../lib/ios/build/release/";
GCC_WARN_CHECK_SWITCH_STATEMENTS = NO;
+ OBJROOT = "$(SRCROOT)/../../lib/ios/build/release";
SDKROOT = iphoneos;
+ SYMROOT = "$(SRCROOT)/../../lib/ios/";
WARNING_CFLAGS = (
"-Wno-non-virtual-dtor",
"-Wno-overloaded-virtual",
View
8 scripts/ios/template/emptyExample.xcodeproj/project.pbxproj
@@ -113,7 +113,7 @@
<key>isa</key>
<string>PBXNativeTarget</string>
<key>name</key>
- <string>iPhoneEmptyExample</string>
+ <string>emptyExample</string>
<key>productName</key>
<string>iPhone</string>
<key>productReference</key>
@@ -130,7 +130,7 @@
<key>isa</key>
<string>PBXFileReference</string>
<key>path</key>
- <string>iPhoneEmptyExample.app</string>
+ <string>emptyExample.app</string>
<key>sourceTree</key>
<string>BUILT_PRODUCTS_DIR</string>
</dict>
@@ -823,9 +823,9 @@
<key>lastKnownFileType</key>
<string>wrapper.pb-project</string>
<key>name</key>
- <string>iPhone+OF Lib.xcodeproj</string>
+ <string>iOS+OFLib.xcodeproj</string>
<key>path</key>
- <string>../../../libs/openFrameworksCompiled/project/ios/iPhone+OF Lib.xcodeproj</string>
+ <string>../../../libs/openFrameworksCompiled/project/ios/iOS+OFLib.xcodeproj</string>
<key>sourceTree</key>
<string>SOURCE_ROOT</string>
</dict>
Please sign in to comment.
Something went wrong with that request. Please try again.