Git Product home page Git Product logo

tetris-sound's Introduction

tetris-sound

Reads a NES Tetris video and adds only the Tetris sound effect.

usage

  • Select either detection by flashing pixel or by line count OCR (flashing is much faster)
  • Use the file dialog to select the video file, and press "Go to pixel selection..."
  • Depending on which method you chose, click on the flashing pixel or on the top-left and bottom-right corners of the line count number box

(this is just for illustration, the points ain't drawn on the screen yet)

  • If needed you can go forward on the video by pressing 'n', press 'q' when you are done (might have to press a few times for some reason)
  • This window will close and another one will appear playing the video and detecting tetrises, when it finishes, it will automatically create a file named "video_with_tetris_sound_effect.mp4" with a copy of the video and the tetris sounds.

Running

The windows executable should be available here (click on on the most recent green ticked link and scroll to the bottom of the page, download requires github login.

If you want to run it from the python file, install tesserocr, download the repository and inside the directory run:

python3 -m venv venv
source venv/bin/activate (on Windows run venv\Scripts\activate.bat)
pip install -r requirements.txt
python tetris_sound.py

Note: FFmpeg has to be on your path in either case as of now.

(I'm not very familiar with python (or openCV and OCR), so the code is a bit of a mess)

License

This project is under the GPLv2 or later.

The file eng.traineddata was added here for convenience, it is from this repository and is under the Apache-2.0 license.

tetris-sound's People

Contributors

brianch avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.