https://github.com/accessd/carrierwave-ffmpeg
Simple Streamio FFmpeg wrapper for CarrierWave uploader
https://github.com/accessd/carrierwave-ffmpeg
Last synced: 2 months ago
JSON representation
Simple Streamio FFmpeg wrapper for CarrierWave uploader
- Host: GitHub
- URL: https://github.com/accessd/carrierwave-ffmpeg
- Owner: accessd
- License: mit
- Created: 2017-11-28T15:21:30.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-11-28T15:22:52.000Z (over 7 years ago)
- Last Synced: 2025-02-01T03:33:25.786Z (3 months ago)
- Language: Ruby
- Homepage:
- Size: 3.91 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# CarrierWave::FFmpeg
Simple Streamio FFmpeg wrapper for CarrierWave uploader
## Installation
Add this line to your application's Gemfile:
gem 'carrierwave-ffmpeg'
And then execute:
$ bundle
Or install it yourself as:
$ gem install carrierwave-ffmpeg
## Usage
Include wrapper into your CarrierWave uploader class
```ruby
class VideoUploader < CarrierWave::Uploader::Base
include CarrierWave::FFmpeg
end
```Example:
To take screenshot from video:
```ruby
class VideoUploader < CarrierWave::Uploader::Base
include CarrierWave::FFmpeg>version :thumb do
process encode: [:jpg, seek: 5]
end
end
```Default seek is 10% from video duration. Also you can pass `frame_num` option to
take screenshot for specific frame.## Contributing
1. Fork it
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create new Pull Request