-
Notifications
You must be signed in to change notification settings - Fork 38
mattg: edits to allow rpicam_file example to work on hard coded value… #82
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
mattg: edits to allow rpicam_file example to work on hard coded value… #82
Conversation
…s, and draw image to a canvas
examples/rpicam_file.py
Outdated
import tkinter | ||
from tkinter import * | ||
|
||
def getRGBHex(value, color): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
function for setting hex value for the value received from raw file
examples/rpicam_file.py
Outdated
# example of passing a filter over the rawframe before it is saved. This will simply print the dimensions of the raw image. | ||
def print_dimensions(rawFrame): | ||
print(rawFrame.shape) | ||
height, width = rawFrame.shape | ||
for x in range(0, 1700): # width |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
draw the raw image to canvas
return rawFrame | ||
|
||
# pass camera reference into the converter. | ||
r = RPICAM2DNG(camera) | ||
r.options(path="", compress=True) | ||
r.options(path="C:/Users/matth/code/PiDNG/raw-test-full-sensor", compress=False) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
set working dir
r.filter = print_dimensions | ||
r.convert(data, filename="output") | ||
r.convert(data, filename="./full-sensor-test") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
set output dng file name, dng file extension gets added by default
@@ -0,0 +1,18 @@ | |||
import subprocess |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ignore this file for now
…ighbor, and separate canvas code into different script
mattg: edits to allow rpicam_file example to work on hard coded values, and draw image to a canvas