Skip to content

A college project in Python using OpenCV, a simple app that takes two images - one with green areas, the other a background image, and outputs an image with the green areas replaced with the background image.

License

Notifications You must be signed in to change notification settings

ElenaChes/Python-Chroma-key-App

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

Chroma key App

A college project in Python using OpenCV.
Description: a simple app that takes two images - one with green areas, the other a background image, and outputs an image with the green areas replaced with the background image.

Content


Dependencies

  1. Python 3.7.0

The app could work with different versions, but this is the one that was tested.

Installation

  1. Create a new directory, for example chromakey, and place app.py inside of it.
  2. Open the directory in your Terminal:
cd chromakey
  1. Create a virtual environment:
python -m venv opencv-env
  1. Activate the environment :
.\opencv-env\Scripts\activate
  1. Install needed packages:
pip install opencv-contrib-python matplotlib

Usage

  1. Run the app using the following syntax:
python app.py img_filename bk_filename ofilename

While:

  • img_filename - path to an image with a 'green screen'.
  • bk_filename - path to the background.
  • ofilename - path to save the edited image, if none is provided it'll be displayed instead.

About

A college project in Python using OpenCV, a simple app that takes two images - one with green areas, the other a background image, and outputs an image with the green areas replaced with the background image.

Topics

Resources

License

Stars

Watchers

Forks

Languages