Heading Here
Trying to add a webcam fee to a panel inside of my wxpython GUI. I have buttons on the left currently, and a black panel on the right.
I'm confused as to how to add a webcam feed to that panel?
here is the code being used to the camera feed, I'm using pygame for it.
pygame.camera.init()
screen = pygame.display.set_mode((640,340))
cam = pygame.camera.Camera("/dev/video0", (300,220))
cam.start()
while 1:
image = cam.get_image()
screen.blit(image,(200,100))
pygame.display.update()
for event in pygame.event.get():
if event.type == pygame.QUIT:
sys.exit()
the Gui panel i'm trying to add the feed to is like this.
self.panel = wx.Panel(self, -1, (150, 20), (110, 110), style=wx.SUNKEN_BORDER)
self.panel.SetBackgroundColour(self.colour)
right now the panel, is just being painted black.
do u guys know of any good tutorials of how to do this?