Skip to content

Instantly share code, notes, and snippets.

@mrgfisher
mrgfisher / Python Webcam Dance Game
Created November 6, 2019 19:17 — forked from michvaldes001/Python Webcam Dance Game
This is a game I wrote in Python. It uses Pygame and OpenCV libraries for video capture and rendering. The objective of the game is to dance in front of the camera and fill the dance meter on the left. You must also stop the "lameness" meter on the right from accumulating. A final score is calculated according to how well you perform. See game i…
#!/usr/bin/env python
#Example of program in action can be found here http://www.youtube.com/watch?v=burYkYiI8vg
import sys, pygame, random, pygame.mixer, cv2
from PIL import Image
import PIL.ImageOps
#Setup
import time,imutils
import cv2
from PIL import Image
import numpy as np
from twilio.rest import Client
import tkinter
from threading import Thread
cap = cv2.VideoCapture(0)
cap.set(3,640) # set Width