Commit 6fd7003a authored by Gaëtan Renaudeau's avatar Gaëtan Renaudeau

prepare for .27 and do appropriate changes

there were a breaking in RN if you use AnimatedSurface
parent 539a73f6
**[Gitbook documentation](http://projectseptemberinc.gitbooks.io/gl-react/content/) / [Github](https://github.com/ProjectSeptemberInc/gl-react-native/) / [gl-react](https://github.com/ProjectSeptemberInc/gl-react/)** / [#gl-react on reactiflux](https://discordapp.com/channels/102860784329052160/106102146109325312)
# <img width="32" alt="icon" src="https://cloud.githubusercontent.com/assets/211411/9813786/eacfcc24-5888-11e5-8f9b-5a907a2cbb21.png"> gl-react-native ![](https://img.shields.io/badge/react--native-%200.36.x-05F561.svg) ![](https://img.shields.io/badge/gl--react-%202.2.x-05F561.svg)
# <img width="32" alt="icon" src="https://cloud.githubusercontent.com/assets/211411/9813786/eacfcc24-5888-11e5-8f9b-5a907a2cbb21.png"> gl-react-native ![](https://img.shields.io/badge/react--native-%200.37.x-05F561.svg) ![](https://img.shields.io/badge/gl--react-%202.2.x-05F561.svg)
OpenGL bindings for React Native to implement complex effects over images and components, in the descriptive VDOM paradigm.
......
Pod::Spec.new do |s|
s.name = "RNGL"
s.version = "2.36.0"
s.version = "2.37.0"
s.author = "Project September"
s.summary = "OpenGL bindings for React Native to implement complex effects over images and components"
s.homepage = "https://github.com/ProjectSeptemberInc/gl-react-native"
s.platform = :ios, "8.0"
s.source = { :git => "https://github.com/ProjectSeptemberInc/gl-react-native.git", :tag => "v2.36.0" }
s.source = { :git => "https://github.com/ProjectSeptemberInc/gl-react-native.git", :tag => "v2.37.0" }
s.source_files = "ios/*.{h,m}"
s.license = "MIT"
......
......@@ -67,14 +67,6 @@
<sourceFolder url="file://$MODULE_DIR$/src/main/jni" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/rs" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/shaders" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/assets" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/aidl" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/java" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/jni" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/rs" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/shaders" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/test/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/test/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/test/assets" type="java-test-resource" />
......@@ -83,6 +75,14 @@
<sourceFolder url="file://$MODULE_DIR$/src/test/jni" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/test/rs" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/test/shaders" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/assets" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/aidl" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/java" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/jni" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/rs" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/shaders" isTestSource="true" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/annotations" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/blame" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/bundles" />
......
......@@ -66,14 +66,6 @@
<sourceFolder url="file://$MODULE_DIR$/src/main/jni" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/rs" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/shaders" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/assets" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/aidl" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/java" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/jni" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/rs" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/shaders" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/test/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/test/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/test/assets" type="java-test-resource" />
......@@ -82,9 +74,16 @@
<sourceFolder url="file://$MODULE_DIR$/src/test/jni" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/test/rs" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/test/shaders" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/assets" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/aidl" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/java" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/jni" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/rs" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/shaders" isTestSource="true" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/assets" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/blame" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/builds" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/classes" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/dependency-cache" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.android.support/appcompat-v7/23.0.1/jars" />
......@@ -96,7 +95,7 @@
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.facebook.fresco/imagepipeline-base/0.11.0/jars" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.facebook.fresco/imagepipeline-okhttp3/0.11.0/jars" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.facebook.fresco/imagepipeline/0.11.0/jars" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.facebook.react/react-native/0.35.0-rc.0/jars" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.facebook.react/react-native/0.37.0/jars" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.facebook.soloader/soloader/0.1.0/jars" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/org.webkit/android-jsc/r174650/jars" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/incremental" />
......@@ -123,7 +122,6 @@
<orderEntry type="library" exported="" name="okio-1.9.0" level="project" />
<orderEntry type="library" exported="" name="imagepipeline-0.11.0" level="project" />
<orderEntry type="library" exported="" name="library-2.4.0" level="project" />
<orderEntry type="library" exported="" name="react-native-0.35.0-rc.0" level="project" />
<orderEntry type="library" exported="" name="imagepipeline-base-0.11.0" level="project" />
<orderEntry type="library" exported="" name="fresco-0.11.0" level="project" />
<orderEntry type="library" exported="" name="drawee-0.11.0" level="project" />
......@@ -132,6 +130,7 @@
<orderEntry type="library" exported="" name="jsr305-3.0.0" level="project" />
<orderEntry type="library" exported="" name="jackson-core-2.2.3" level="project" />
<orderEntry type="library" exported="" name="bolts-tasks-1.4.0" level="project" />
<orderEntry type="library" exported="" name="react-native-0.37.0" level="project" />
<orderEntry type="library" exported="" name="recyclerview-v7-23.0.1" level="project" />
<orderEntry type="library" exported="" name="okhttp-urlconnection-3.4.1" level="project" />
<orderEntry type="library" exported="" name="okhttp-ws-3.4.1" level="project" />
......@@ -143,7 +142,6 @@
<orderEntry type="library" exported="" name="appcompat-v7-23.0.1" level="project" />
<orderEntry type="library" exported="" name="fbcore-0.11.0" level="project" />
<orderEntry type="module" module-name="react-native-fs" exported="" />
<orderEntry type="module" module-name="RNMaterialKit" exported="" />
<orderEntry type="module" module-name="RNGL" exported="" />
<orderEntry type="library" exported="" name="okhttp-ws-2.5.0" level="project" />
<orderEntry type="library" exported="" name="okio-1.6.0" level="project" />
......
......@@ -124,7 +124,6 @@ dependencies {
compile "com.android.support:appcompat-v7:23.0.1"
compile "com.facebook.react:react-native:+" // From node_modules
compile project(":RNMaterialKit")
compile project(":RNGL")
compile project(":react-native-fs")
}
......@@ -3,7 +3,6 @@ package com.example;
import com.facebook.react.ReactActivity;
import com.facebook.react.ReactPackage;
import com.facebook.react.shell.MainReactPackage;
import com.github.xinthink.rnmk.ReactMaterialKitPackage;
import com.projectseptember.RNGL.RNGLPackage;
import com.rnfs.RNFSPackage;
......
......@@ -8,7 +8,6 @@ import com.facebook.react.ReactInstanceManager;
import com.facebook.react.ReactNativeHost;
import com.facebook.react.ReactPackage;
import com.facebook.react.shell.MainReactPackage;
import com.github.xinthink.rnmk.ReactMaterialKitPackage;
import com.projectseptember.RNGL.RNGLPackage;
import com.rnfs.RNFSPackage;
......@@ -28,8 +27,7 @@ public class MainApplication extends Application implements ReactApplication {
return Arrays.<ReactPackage>asList(
new MainReactPackage(),
new RNGLPackage(),
new RNFSPackage(),
new ReactMaterialKitPackage()
new RNFSPackage()
);
}
};
......
......@@ -5,7 +5,7 @@ buildscript {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.2.0'
classpath 'com.android.tools.build:gradle:2.2.2'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
......
......@@ -2,9 +2,6 @@ rootProject.name = 'example'
include ':app'
include ':RNMaterialKit'
project(':RNMaterialKit').projectDir = file('../node_modules/react-native-material-kit/android')
include ':RNGL'
project(':RNGL').projectDir = file('../../android')
......
......@@ -21,7 +21,6 @@
13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
146834051AC3E58100842450 /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; };
3469C4C71C723AD300AE6E0E /* libRCTMaterialKit.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3469C4C61C723AC400AE6E0E /* libRCTMaterialKit.a */; };
3469C4C81C723AD300AE6E0E /* libRNFS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3469C4C01C723ABC00AE6E0E /* libRNFS.a */; };
34BA81381CEDCC6100FCF175 /* libRNGL.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3469C4BA1C723AB400AE6E0E /* libRNGL.a */; };
832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 832341B51AAA6A8300B99B32 /* libRCTText.a */; };
......@@ -105,12 +104,54 @@
remoteGlobalIDString = F12AFB9B1ADAF8F800E0535D;
remoteInfo = RNFS;
};
3469C4C51C723AC400AE6E0E /* PBXContainerItemProxy */ = {
34B928D31DE06CDA00D205B0 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 3469C4C11C723AC400AE6E0E /* RCTMaterialKit.xcodeproj */;
containerPortal = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = 2D2A283A1D9B042B00D4039D;
remoteInfo = "RCTImage-tvOS";
};
34B928D71DE06CDA00D205B0 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = 8A1B8E771B22E4E300DB45C2;
remoteInfo = RCTMaterialKit;
remoteGlobalIDString = 2D2A28471D9B043800D4039D;
remoteInfo = "RCTLinking-tvOS";
};
34B928DB1DE06CDA00D205B0 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = 2D2A28541D9B044C00D4039D;
remoteInfo = "RCTNetwork-tvOS";
};
34B928DF1DE06CDA00D205B0 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = 2D2A28611D9B046600D4039D;
remoteInfo = "RCTSettings-tvOS";
};
34B928E31DE06CDA00D205B0 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = 2D2A287B1D9B048500D4039D;
remoteInfo = "RCTText-tvOS";
};
34B928E81DE06CDA00D205B0 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = 2D2A28881D9B049200D4039D;
remoteInfo = "RCTWebSocket-tvOS";
};
34B928EC1DE06CDA00D205B0 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = 2D2A28131D9B038B00D4039D;
remoteInfo = "React-tvOS";
};
78C398B81ACF4ADC00677621 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
......@@ -150,7 +191,6 @@
146833FF1AC3E56700842450 /* React.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = React.xcodeproj; path = "../node_modules/react-native/React/React.xcodeproj"; sourceTree = "<group>"; };
3469C4AB1C723AB400AE6E0E /* RNGL.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RNGL.xcodeproj; path = "../node_modules/gl-react-native/ios/RNGL.xcodeproj"; sourceTree = "<group>"; };
3469C4BB1C723ABC00AE6E0E /* RNFS.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RNFS.xcodeproj; path = "../node_modules/react-native-fs/RNFS.xcodeproj"; sourceTree = "<group>"; };
3469C4C11C723AC400AE6E0E /* RCTMaterialKit.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTMaterialKit.xcodeproj; path = "../node_modules/react-native-material-kit/iOS/RCTMaterialKit.xcodeproj"; sourceTree = "<group>"; };
78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTLinking.xcodeproj; path = "../node_modules/react-native/Libraries/LinkingIOS/RCTLinking.xcodeproj"; sourceTree = "<group>"; };
832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTText.xcodeproj; path = "../node_modules/react-native/Libraries/Text/RCTText.xcodeproj"; sourceTree = "<group>"; };
/* End PBXFileReference section */
......@@ -168,7 +208,6 @@
buildActionMask = 2147483647;
files = (
34BA81381CEDCC6100FCF175 /* libRNGL.a in Frameworks */,
3469C4C71C723AD300AE6E0E /* libRCTMaterialKit.a in Frameworks */,
3469C4C81C723AD300AE6E0E /* libRNFS.a in Frameworks */,
146834051AC3E58100842450 /* libReact.a in Frameworks */,
00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */,
......@@ -206,6 +245,7 @@
isa = PBXGroup;
children = (
00C302C01ABCB91800DB3ED1 /* libRCTImage.a */,
34B928D41DE06CDA00D205B0 /* libRCTImage-tvOS.a */,
);
name = Products;
sourceTree = "<group>";
......@@ -214,6 +254,7 @@
isa = PBXGroup;
children = (
00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */,
34B928DC1DE06CDA00D205B0 /* libRCTNetwork-tvOS.a */,
);
name = Products;
sourceTree = "<group>";
......@@ -247,6 +288,7 @@
isa = PBXGroup;
children = (
139105C11AF99BAD00B5F7CC /* libRCTSettings.a */,
34B928E01DE06CDA00D205B0 /* libRCTSettings-tvOS.a */,
);
name = Products;
sourceTree = "<group>";
......@@ -255,6 +297,7 @@
isa = PBXGroup;
children = (
139FDEF41B06529B00C62182 /* libRCTWebSocket.a */,
34B928E91DE06CDA00D205B0 /* libRCTWebSocket-tvOS.a */,
);
name = Products;
sourceTree = "<group>";
......@@ -277,6 +320,7 @@
isa = PBXGroup;
children = (
146834041AC3E56700842450 /* libReact.a */,
34B928ED1DE06CDA00D205B0 /* libReact-tvOS.a */,
);
name = Products;
sourceTree = "<group>";
......@@ -297,18 +341,11 @@
name = Products;
sourceTree = "<group>";
};
3469C4C21C723AC400AE6E0E /* Products */ = {
isa = PBXGroup;
children = (
3469C4C61C723AC400AE6E0E /* libRCTMaterialKit.a */,
);
name = Products;
sourceTree = "<group>";
};
78C398B11ACF4ADC00677621 /* Products */ = {
isa = PBXGroup;
children = (
78C398B91ACF4ADC00677621 /* libRCTLinking.a */,
34B928D81DE06CDA00D205B0 /* libRCTLinking-tvOS.a */,
);
name = Products;
sourceTree = "<group>";
......@@ -316,7 +353,6 @@
832341AE1AAA6A7D00B99B32 /* Libraries */ = {
isa = PBXGroup;
children = (
3469C4C11C723AC400AE6E0E /* RCTMaterialKit.xcodeproj */,
3469C4BB1C723ABC00AE6E0E /* RNFS.xcodeproj */,
3469C4AB1C723AB400AE6E0E /* RNGL.xcodeproj */,
146833FF1AC3E56700842450 /* React.xcodeproj */,
......@@ -337,6 +373,7 @@
isa = PBXGroup;
children = (
832341B51AAA6A8300B99B32 /* libRCTText.a */,
34B928E41DE06CDA00D205B0 /* libRCTText-tvOS.a */,
);
name = Products;
sourceTree = "<group>";
......@@ -444,10 +481,6 @@
ProductGroup = 78C398B11ACF4ADC00677621 /* Products */;
ProjectRef = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */;
},
{
ProductGroup = 3469C4C21C723AC400AE6E0E /* Products */;
ProjectRef = 3469C4C11C723AC400AE6E0E /* RCTMaterialKit.xcodeproj */;
},
{
ProductGroup = 00C302D41ABCB9D200DB3ED1 /* Products */;
ProjectRef = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */;
......@@ -560,11 +593,53 @@
remoteRef = 3469C4BF1C723ABC00AE6E0E /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
3469C4C61C723AC400AE6E0E /* libRCTMaterialKit.a */ = {
34B928D41DE06CDA00D205B0 /* libRCTImage-tvOS.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = "libRCTImage-tvOS.a";
remoteRef = 34B928D31DE06CDA00D205B0 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
34B928D81DE06CDA00D205B0 /* libRCTLinking-tvOS.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = "libRCTLinking-tvOS.a";
remoteRef = 34B928D71DE06CDA00D205B0 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
34B928DC1DE06CDA00D205B0 /* libRCTNetwork-tvOS.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = "libRCTNetwork-tvOS.a";
remoteRef = 34B928DB1DE06CDA00D205B0 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
34B928E01DE06CDA00D205B0 /* libRCTSettings-tvOS.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = "libRCTSettings-tvOS.a";
remoteRef = 34B928DF1DE06CDA00D205B0 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
34B928E41DE06CDA00D205B0 /* libRCTText-tvOS.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = "libRCTText-tvOS.a";
remoteRef = 34B928E31DE06CDA00D205B0 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
34B928E91DE06CDA00D205B0 /* libRCTWebSocket-tvOS.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = "libRCTWebSocket-tvOS.a";
remoteRef = 34B928E81DE06CDA00D205B0 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
34B928ED1DE06CDA00D205B0 /* libReact-tvOS.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = libRCTMaterialKit.a;
remoteRef = 3469C4C51C723AC400AE6E0E /* PBXContainerItemProxy */;
path = "libReact-tvOS.a";
remoteRef = 34B928EC1DE06CDA00D205B0 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
78C398B91ACF4ADC00677621 /* libRCTLinking.a */ = {
......
......@@ -7,14 +7,13 @@
},
"dependencies": {
"crypto": "0.0.3",
"gl-react": "2.2.6",
"gl-react": "2.2.8",
"gl-react-blur": "^1.3.0",
"gl-react-native": "file:..",
"glsl-transitions": "^2016.2.15",
"react": "15.3.2",
"react-native": "0.36.1",
"react-native": "0.37.0",
"react-native-fs": "1.5.1",
"react-native-material-kit": "PyYoshi/react-native-material-kit#rn-0.25.1",
"seedrandom": "gre/seedrandom#released"
}
}
......@@ -9,20 +9,28 @@ const styles = StyleSheet.create({
borderWidth: 1,
borderStyle: "solid",
width: 150,
padding: 10
height: 30,
alignItems: "center",
justifyContent: "center",
},
text: {
color: "#333"
color: "#333",
}
});
class Button extends Component {
render () {
const { children, width, ...rest } = this.props;
const { children, style, textStyle, ...rest } = this.props;
return (
<TouchableOpacity {...rest}>
<View style={[ {width}, styles.root ]}>
<Text style={styles.text}>{children}</Text>
<View style={[ style, styles.root ]}>
<Text
style={[
styles.text,
textStyle,
]}>
{children}
</Text>
</View>
</TouchableOpacity>
);
......
......@@ -77,6 +77,7 @@ class OneFingerResponse extends React.Component {
];
return <Surface
ref="surface"
style={{ backgroundColor: "#000" }}
{...this._panResponder.panHandlers}
width={width}
height={height}>
......
import React, {Component} from "react";
import {StyleSheet, Text, View, Image, TextInput, TouchableOpacity} from "react-native";
import {
StyleSheet,
Text,
View,
Image,
TextInput,
TouchableOpacity,
Slider,
Switch,
} from "react-native";
import { Surface } from "gl-react-native";
const {
mdl: {
Progress,
Slider,
Switch
},
MKButton,
} = require("react-native-material-kit");
import RNFS from "react-native-fs";
import HelloGL from "./HelloGL";
import Saturation from "./Saturation";
......@@ -40,18 +40,16 @@ class Demos extends Component {
return <View>
<View style={styles.nav}>
{React.Children.map(children, (demo, i) =>
<MKButton
<Text
style={{ flex: 1, padding: 10 }}
onPress={() => onChange(i)}>
<Text pointerEvents="none"
style={{
textStyle={{
textAlign: "center",
color: i!==value ? "#123" : "#69c",
fontWeight: "bold"
}}>
}}
onPress={() => onChange(i)}>
{""+(i+1)}
</Text>
</MKButton>)}
</Text>)}
</View>
<View style={styles.demos}>
{children[value]}
......@@ -61,9 +59,8 @@ class Demos extends Component {
}
class Simple extends Component {
constructor (props) {
super(props);
this.state = {
state = {
current: 0,
saturationFactor: 1,
hue: 0,
......@@ -76,19 +73,9 @@ class Simple extends Component {
captured: null,
captureConfig: null
};
this.onCapture1 = this.onCapture1.bind(this);
/*
// Crazy stress mode
const self = this;
setTimeout(function loop () {
setTimeout(loop, 100 * Math.random());
self.setState({ current: Math.floor(8 * Math.random()) });
}, 100);
*/
}
onCapture1 () {
onCapture1 = () => {
const captureConfig = {
quality: Math.round((Math.random() * 100))/100,
type: Math.random() < 0.5 ? "jpg": "png",
......@@ -100,7 +87,7 @@ class Simple extends Component {
this.refs.helloGL
.captureFrame(captureConfig)
.then(captured => this.setState({ captured, captureConfig }));
}
};
render () {
const {
......@@ -124,8 +111,10 @@ class Simple extends Component {
<Surface width={256} height={171} ref="helloGL">
<HelloGL />
</Surface>
<View style={{ paddingTop: 20, alignItems: "center", flexDirection: "row" }}>
<Button onPress={this.onCapture1}>captureFrame()</Button>
<View style={{ marginTop: 20, flexDirection: "row" }}>
<Button onPress={this.onCapture1}>
captureFrame()
</Button>
{captured &&
<Image source={{ uri: captured }}
style={{ marginLeft: 20, width: 51, height: 34 }}
......@@ -158,8 +147,8 @@ class Simple extends Component {
/>
</Surface>
<Slider
max={8}
onChange={saturationFactor => this.setState({ saturationFactor })}
maximumValue={8}
onValueChange ={saturationFactor => this.setState({ saturationFactor })}
/>
</Demo>
......@@ -174,8 +163,8 @@ class Simple extends Component {
</HueRotate>
</Surface>
<Slider
max={2 * Math.PI}
onChange={hue => this.setState({ hue })}
maximumValue={2 * Math.PI}
onValueChange={hue => this.setState({ hue })}
/>
<TextInput
style={{ height: 40, borderColor: "#aaa", borderWidth: 1 }}
......@@ -204,8 +193,8 @@ class Simple extends Component {
</View>
</View>
<Slider
max={1}
onChange={progress => this.setState({ progress })}
maximumValue={1}
onValueChange={progress => this.setState({ progress })}
/>
</Demo>
......@@ -230,8 +219,8 @@ class Simple extends Component {
</Blur>
</Surface>
<Slider
max={2}
onChange={factor => this.setState({ factor })} />
maximumValue={2}
onValueChange={factor => this.setState({ factor })} />
</Demo>
<Demo id={8} current={current} title="8. Blur+Hue over UI">
......@@ -246,16 +235,14 @@ class Simple extends Component {
<View key="blur" style={{ width: 256, height: 160, padding: 10, backgroundColor: "#f9f9f9" }}>
<Slider
style={{ height: 80 }}
max={1}
onChange={factor => this.setState({ factor })}
maximumValue={1}
onValueChange={factor => this.setState({ factor })}
/>
<View style={{ height: 60, flexDirection: "row", alignItems: "center" }}>
<Switch style={{flex:1}} checked={switch1} onCheckedChange={({checked:switch1}) => this.setState({ switch1 })} />
<Switch style={{flex:1}} checked={switch2} onCheckedChange={({checked:switch2}) => this.setState({ switch2 })} />
<Switch style={{flex:1}} checked={switch3} onCheckedChange={({checked:switch3}) => this.setState({ switch3 })} />
<Switch style={{flex:1}} value={switch1} onValueChange={(switch1) => this.setState({ switch1 })} />
<Switch style={{flex:1}} value={switch2} onValueChange={(switch2) => this.setState({ switch2 })} />
<Switch style={{flex:1}} value={switch3} onValueChange={(switch3) => this.setState({ switch3 })} />
</View>
<Progress progress={factor} style={{height: 10, marginTop: 8, flex:1}} />
</View>
</Blur>
</HueRotate>
......
import invariant from "invariant";
import React, {Component} from "react";
import {requireNativeComponent, findNodeHandle} from "react-native";
import {requireNativeComponent, findNodeHandle} from "react-native";
import defer from "promise-defer";
import captureFrame from "./GLCanvas.captureFrame";
......@@ -17,6 +17,10 @@ const GLCanvasNative = requireNativeComponent("GLCanvas", GLCanvas, {
class GLCanvas extends Component {
viewConfig = {
uiViewClassName: "GLCanvas"
};
componentWillMount () {
this._pendingCaptureFrame = {};
}
......
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