Skip to content

CortanaAndSiri/video2chars

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Video to Chars

Build Status PYPI Version Codacy Badge Python 3.6+

Convert video to character art animation.

Strictly speaking, this project is an optimized version of the merger of two small projects. Because it is very interesting, I compared multiple pieces of code. It was changed under the code of the two guys in pronhgithub. The core code of the two guys was used to fix Some bugs, stitched and assembled: The screen processing is character animation core code using most of the code of rossning92 (ascii_art.py) (two bugs were fixed at the same time, original url Video and audio processing is most of the code of ryan4yin boss video2chars (parts deleted, original url This is a command line tool that can convert pictures and video files into character animations, using pillow + moviepy to achieve

中文说明

Usage

python video2chars.py [--help --fps INTEGER --t_start  INTEGER --t_end INTEGER --output TEXT] FILENAME

Usage: converter.py [OPTIONS] FILENAME

Options:
  --fps INTEGER      frames per second, default to 16
  --t_start INTEGER  the start time that the video needs to be converted(in
                     seconds)
  --t_end INTEGER    the end time that the video needs to be converted(in
                     seconds)
  --output TEXT      output to a file with this name, default to "output.mp4"
  --help             Show this message and exit.

Example
	python video2chars.py --fps 30  --t_start 0  --t_end 10 --output output.mp4  inputfile.mp4

The command shows that the specified video will be converted to an ascii art animation with 30 fps, and only convert the first 10 seconds. you'll see a file named output.mp4 in your current directory when completes, have fun ~

p.s. it's a bit slow, turn down the width and fps, to speed up the conversion.

Check video2chars --help for more information.

python video2ascii.py  FILENAME

Example
	 python video2ascii.py test.jpg

Convert a picture to a character picture

Code Reference

-[Screen processing (version rossning92)] The core code for the image processing is character animation. Most of the code (ascii_art.py) used by rossning92 is used (two bugs fixed at the same time, original url -[Audio and video processing (ryan4yin version)] Video and audio processing is most of the code of ryan4yin boss video2chars (parts deleted, original url

Demonstration

Python Url-bilibili

Related Projects

Releases

No releases published

Packages

No packages published

Languages