Revision: 226
Author:
connec...@gmail.com
Date: Sat Jul 13 21:41:18 2013
Log: let's not delete and recreate the FBO every frame…if we can avoid
it
http://code.google.com/p/syphon-implementations/source/detail?r=226
Modified:
/trunk/Syphon
Implementations/Unity3D/Unity3D-3_5/SyphonUnityExample/Assets/SyphonServerAndClient.unity
/trunk/Syphon
Implementations/Unity3D/Unity3D-3_5/SyphonUnityPlugin/ServerWatcherUtility.mm
/trunk/Syphon
Implementations/Unity3D/Unity3D-3_5/SyphonUnityPlugin/SyphonClientUnity.m
=======================================
--- /trunk/Syphon
Implementations/Unity3D/Unity3D-3_5/SyphonUnityExample/Assets/SyphonServerAndClient.unity
Sat Jul 13 17:26:24 2013
+++ /trunk/Syphon
Implementations/Unity3D/Unity3D-3_5/SyphonUnityExample/Assets/SyphonServerAndClient.unity
Sat Jul 13 21:41:18 2013
Binary file, no diff available.
=======================================
--- /trunk/Syphon
Implementations/Unity3D/Unity3D-3_5/SyphonUnityPlugin/ServerWatcherUtility.mm
Sat Jul 13 21:08:24 2013
+++ /trunk/Syphon
Implementations/Unity3D/Unity3D-3_5/SyphonUnityPlugin/ServerWatcherUtility.mm
Sat Jul 13 21:41:18 2013
@@ -165,7 +165,7 @@
const char* param2 = [[[notification object]
objectForKey:SyphonServerDescriptionNameKey] UTF8String];
const char* param1 = [[[notification object]
objectForKey:SyphonServerDescriptionAppNameKey] UTF8String];
const char* param3 = [[[notification object]
objectForKey:SyphonServerDescriptionUUIDKey] UTF8String];
- NSLog(@"announceing server! %s %s %s", param2, param1, param3);
+ //NSLog(@"announceing server! %s %s %s", param2, param1, param3);
int serverPtr = 0;
NSArray* serversArray = [[SyphonServerDirectory sharedDirectory]
servers];
=======================================
--- /trunk/Syphon
Implementations/Unity3D/Unity3D-3_5/SyphonUnityPlugin/SyphonClientUnity.m
Sat Jul 13 21:08:24 2013
+++ /trunk/Syphon
Implementations/Unity3D/Unity3D-3_5/SyphonUnityPlugin/SyphonClientUnity.m
Sat Jul 13 21:41:18 2013
@@ -117,7 +117,7 @@
SyphonImage* image = [ptr->syphonClient
newFrameImageForContext:cachedContext];
if(!image){
- NSLog(@"nil image.");
+// NSLog(@"nil image.");
glBindFramebufferEXT(GL_DRAW_FRAMEBUFFER, previousDrawFBO);
glBindFramebufferEXT(GL_READ_FRAMEBUFFER, previousReadFBO);
glBindFramebufferEXT(GL_FRAMEBUFFER, previousFBO);
@@ -158,7 +158,7 @@
// GLint texcount = 0;
// glGetIntegerv(GL_TEXTURE_STACK_DEPTH, &texcount);
- NSLog(@"w/h: %i, %i", ptr->textureWidth, ptr->textureHeight
/*, texcount*/ );
+// NSLog(@"w/h: %i, %i", ptr->textureWidth, ptr->textureHeight
/*, texcount*/ );
// ptr->updateTextureSizeFlag = true;
handleTextureSizeChanged(ptr);
@@ -249,12 +249,12 @@
glPopClientAttrib();
glPopAttrib();
- if(syphonFBO){
-// NSLog(@"CACHING CONTEXT + DELETING FBO at RESOURCE ID: %i",
syphonFBO);
- glDeleteFramebuffersEXT(1, &syphonFBO);
- glGenFramebuffersEXT(1, &syphonFBO);
- syphonFBO = nil;
- }
+// if(syphonFBO){
+//// NSLog(@"CACHING CONTEXT + DELETING FBO at RESOURCE ID: %i",
syphonFBO);
+// glDeleteFramebuffersEXT(1, &syphonFBO);
+// glGenFramebuffersEXT(1, &syphonFBO);
+// syphonFBO = nil;
+// }
[image release];