This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | |||
script-hdr-gopro [2018/04/08 10:35] teq |
script-hdr-gopro [2018/04/10 13:57] (current) teq |
||
---|---|---|---|
Line 10: | Line 10: | ||
<code javascript> | <code javascript> | ||
- | //** | + | /** |
- | * HDR capturing example (GoPro Hero 4, 5, 6, and Fusion). | + | * 9 picture HDR capturing example (GoPro Hero 4, 5, 6, and Fusion). |
* Author: Camera Controller | * Author: Camera Controller | ||
* Web: http://www.tequnique.com/cameracontroller | * Web: http://www.tequnique.com/cameracontroller | ||
Line 31: | Line 31: | ||
} | } | ||
} | } | ||
+ | |||
+ | // Information | ||
+ | logMessage("This example captures 9 differently exposed pictures in photo mode with GoPro Hero 4, 5, 6, and Fusion cameras."); | ||
// Use the currently connected camera: | // Use the currently connected camera: | ||
Line 57: | Line 60: | ||
} | } | ||
- | // Capture three images with different exposures | + | for (var i=0; i<9; i++) { |
- | captureImage(cameraName, "/setting/26/8"); // 1 | + | logMessage("Capturing image " + (i+1)); |
- | waitForCameraRecordingState(cameraName, 1000, "recording"); | + | captureImage(cameraName, "/setting/26/" + i); // 1 |
- | waitForCameraRecordingState(cameraName, 0, "idle"); | + | waitForCameraRecordingState(cameraName, 1000, "recording"); |
- | waitMilliseconds(1000); // give the camera some time for capturing. | + | waitForCameraRecordingState(cameraName, 0, "idle"); |
- | + | waitMilliseconds(1000); // give the camera some time for capturing. | |
- | captureImage(cameraName, "/setting/26/4"); // 2 | + | } |
- | waitForCameraRecordingState(cameraName, 1000, "recording"); | + | |
- | waitForCameraRecordingState(cameraName, 0, "idle"); | + | |
- | waitMilliseconds(1000); // give the camera some time for capturing. | + | |
- | + | ||
- | captureImage(cameraName, "/setting/26/0"); // 3 | + | |
- | waitForCameraRecordingState(cameraName, 1000, "recording"); | + | |
- | waitForCameraRecordingState(cameraName, 0, "idle"); | + | |
- | waitMilliseconds(1000); // give the camera some time for capturing. | + | |
logMessage("Done"); | logMessage("Done"); |