Skip to content

Commit

Permalink
changes to edsdk example, rename of mean to median in some places
Browse files Browse the repository at this point in the history
  • Loading branch information
elliotwoods committed Sep 9, 2013
1 parent 8601cfe commit 6c4d57a
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 7 deletions.
6 changes: 3 additions & 3 deletions Example-DSLR/Example-DSLR.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@
E45BE9770E8CC7DD009D7055 /* CoreServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreServices.framework; path = /System/Library/Frameworks/CoreServices.framework; sourceTree = "<absolute>"; };
E45BE9790E8CC7DD009D7055 /* OpenGL.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGL.framework; path = /System/Library/Frameworks/OpenGL.framework; sourceTree = "<absolute>"; };
E45BE97A0E8CC7DD009D7055 /* QuickTime.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuickTime.framework; path = /System/Library/Frameworks/QuickTime.framework; sourceTree = "<absolute>"; };
E4B69B5B0A3A1756003C02F2 /* canon-to-graycodeDebug.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "canon-to-graycodeDebug.app"; sourceTree = BUILT_PRODUCTS_DIR; };
E4B69B5B0A3A1756003C02F2 /* Example-DSLRDebug.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Example-DSLRDebug.app"; sourceTree = BUILT_PRODUCTS_DIR; };
E4B69E1D0A3A1BDC003C02F2 /* main.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = main.cpp; path = src/main.cpp; sourceTree = SOURCE_ROOT; };
E4B69E1E0A3A1BDC003C02F2 /* testApp.cpp */ = {isa = PBXFileReference; explicitFileType = sourcecode.cpp.cpp; fileEncoding = 30; name = testApp.cpp; path = src/testApp.cpp; sourceTree = SOURCE_ROOT; };
E4B69E1F0A3A1BDC003C02F2 /* testApp.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = testApp.h; path = src/testApp.h; sourceTree = SOURCE_ROOT; };
Expand Down Expand Up @@ -317,7 +317,7 @@
E4EEC9E9138DF44700A80321 /* openFrameworks */,
BB4B014C10F69532006C3DED /* addons */,
E45BE5980E8CC70C009D7055 /* frameworks */,
E4B69B5B0A3A1756003C02F2 /* canon-to-graycodeDebug.app */,
E4B69B5B0A3A1756003C02F2 /* Example-DSLRDebug.app */,
);
sourceTree = "<group>";
};
Expand Down Expand Up @@ -362,7 +362,7 @@
);
name = "Example-DSLR";
productName = myOFApp;
productReference = E4B69B5B0A3A1756003C02F2 /* canon-to-graycodeDebug.app */;
productReference = E4B69B5B0A3A1756003C02F2 /* Example-DSLRDebug.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
Expand Down
2 changes: 2 additions & 0 deletions Example-DSLR/src/testApp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,14 @@ void testApp::draw() {
void testApp::keyPressed(int key) {
if(key == ' ') {
if (!this->isScanning) {
//start scanning
payload.init(ofGetWidth(), ofGetHeight());
encoder.init(payload);
decoder.init(payload);
this->doSend = true;
this->isScanning = true;
} else {
//stop scanning
this->isScanning = false;
}
}
Expand Down
4 changes: 2 additions & 2 deletions Example_DecodeFromFiles/src/testApp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

//--------------------------------------------------------------
void testApp::setup(){
payload.init(1024, 768);
payload.init(1920, 1080);
decoder.init(payload);

string path = ofSystemLoadDialog("Select folder of images", true, ofToDataPath("")).getPath();
Expand Down Expand Up @@ -35,7 +35,7 @@ void testApp::update(){
void testApp::draw(){
switch (state) {
case StateViewCamera:
decoder.draw(0, 0);
decoder.draw(0, 0, ofGetWidth(), ofGetHeight());
break;
case StateViewProjector:
decoder.getCameraInProjector().draw(0, 0);
Expand Down
4 changes: 2 additions & 2 deletions src/ofxGraycode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -227,10 +227,10 @@ namespace ofxGraycode {
cameraInProjector.saveImage(filename + "-cameraInProjector.png");

if (data.getMedian().isAllocated())
ofImage(data.getMedian()).saveImage(filename + "-mean.png");
ofImage(data.getMedian()).saveImage(filename + "-median.png");

if (data.getMedianInverse().isAllocated())
ofImage(data.getMedianInverse()).saveImage(filename + "-meanInverse.png");
ofImage(data.getMedianInverse()).saveImage(filename + "-medianInverse.png");
}
//
////
Expand Down

0 comments on commit 6c4d57a

Please sign in to comment.