Fixing the camera 2

Print out array to see what happens.
Fixed list dude.
pull/1/head
Julius Riegel 7 years ago
parent a3afed06db
commit b8b439c460

@ -29,7 +29,7 @@
<file leaf-file-name="main.py" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/main.py">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="493">
<state relative-caret-position="304">
<caret line="41" column="28" lean-forward="true" selection-start-line="41" selection-start-column="28" selection-end-line="41" selection-end-column="28" />
<folding>
<element signature="e#0#19#0" expanded="true" />
@ -42,7 +42,7 @@
<entry file="file://$PROJECT_DIR$/lib/graphiclib.py">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="474">
<caret line="85" column="24" lean-forward="false" selection-start-line="85" selection-start-column="24" selection-end-line="85" selection-end-column="24" />
<caret line="86" column="90" lean-forward="false" selection-start-line="86" selection-start-column="90" selection-end-line="86" selection-end-column="90" />
<folding>
<element signature="e#0#28#0" expanded="true" />
</folding>
@ -483,7 +483,7 @@
</entry>
<entry file="file://$PROJECT_DIR$/main.py">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="493">
<state relative-caret-position="304">
<caret line="41" column="28" lean-forward="true" selection-start-line="41" selection-start-column="28" selection-end-line="41" selection-end-column="28" />
<folding>
<element signature="e#0#19#0" expanded="true" />
@ -494,7 +494,7 @@
<entry file="file://$PROJECT_DIR$/lib/graphiclib.py">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="474">
<caret line="85" column="24" lean-forward="false" selection-start-line="85" selection-start-column="24" selection-end-line="85" selection-end-column="24" />
<caret line="86" column="90" lean-forward="false" selection-start-line="86" selection-start-column="90" selection-end-line="86" selection-end-column="90" />
<folding>
<element signature="e#0#28#0" expanded="true" />
</folding>

@ -55,6 +55,7 @@ class List(pygame.sprite.Sprite):
def update(self, *args):
if self.updated:
height = 0
self.image.fill((0, 0, 0))
for key in self.dict.keys():
line = '{}: {}'.format(key, self.dict[key])
@ -83,4 +84,4 @@ class PiCamera(pygame.sprite.Sprite):
print('updating camera')
with picamera.array.PiRGBArray(self.camera, size=self.size) as output:
self.camera.capture(output, 'rgb', resize=self.size)
print(output)
print('Captured %dx%d image' % (output.array.shape[1], output.array.shape[0]))
Loading…
Cancel
Save