Skip to main content

Convert and inspect video for Chromecast playback

Project description

# cast_convert

Convert audio, video and container to Chromecast supported types. Will only convert if necessary.

## Requirements
Requires a copy of ffmpeg with ffprobe along with libmp3lame and libx264 encoders.

### Debian
`sudo apt-get install ffmpeg lame libmp3lame0 x264`

### Mac OS X
`brew install ffmpeg lame x264`

### Windows
`Good Luck(tm)`

## Installation
- Ensure you have installed all requirements.
- `pip3 install cast_convert`

## Usage

### General
```
alex@mbp12,1:~$ cast_convert --help
Usage: cast_convert [OPTIONS] COMMAND [ARGS]...

Convert and inspect video for Chromecast compatibility

Options:
--help Show this message and exit.

Commands:
convert Convert video to Chromecast compatible...
get_cmd Generate ffmpeg conversion command
inspect Inspect video for transcoding options

```

### Inspection
```
alex@mbp12,1:~$ cast_convert inspect Vids/Zoolander\ 2001\ \(1080p\ x265\ 10bit\ Joy\).mkv
Transcode video to {'container': '', 'audio': '', 'video': 'h264'}

```

### Conversion
```
alex@mbp12,1:~$ cast_convert convert --help
Usage: cast_convert convert [OPTIONS] FILENAME

Convert video to Chromecast compatible encodings and container

Options:
-t, --threads INTEGER Count of threads for ffmpeg to use. Default: 4
--help Show this message and exit.
```

### Print ffmpeg call
The conversion command calls ffmpeg to transcode video. The `get_cmd` command will print the ffmpeg call.
```
alex@mbp12,1:~$ cast_convert get_cmd Vids/Zoolander\ 2001\ \(1080p\ x265\ 10bit\ Joy\).mkv
ffmpeg -fflags +genpts -i "Vids/Zoolander 2001 (1080p x265 10bit Joy).mkv" -c:v libx264 -preset ultrafast -crf 21 -c:a copy -threads 4 "Vids/Zoolander 2001 (1080p x265 10bit Joy)_transcode.mp4"

```

## License
See `LICENSE`

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cast_convert-0.1.4.6.tar.gz (16.7 kB view details)

Uploaded Source

File details

Details for the file cast_convert-0.1.4.6.tar.gz.

File metadata

File hashes

Hashes for cast_convert-0.1.4.6.tar.gz
Algorithm Hash digest
SHA256 6f35db7ddc822adbfdffbadc08ff06121c26e7b7926a55f839c5d72d0bb18ea0
MD5 7c872aafc392a42cd2820172cd2271c1
BLAKE2b-256 89be5ad19c3810cdc609080cbb8014edf8484f2b025a01d123c46e7228068a08

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page