-
Notifications
You must be signed in to change notification settings - Fork 92
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Video Orientation Incorrect #21
Comments
I found that you can manually rotate images with the ffmpeg command "-vf transpose=1" I'm trying to detect the orientation of the video within my uploader model to determine whether or not the video needs to be rotated. I tried the dynamic configuration you outlined in the documentation, but my method "encode" is not being called until after the video is transcoded. How can I fix this? This is what I have: process :encode def encode In my logs, I get: Running transcoding... Transcoding of /tmp/1390509835-32689-5471/VID_01-16-2014-17-34-35.mp4 to /tmp/1390509835-32689-5471/tmpfile.mp4 succeeded Started POST "/videos" for 127.0.0.1 at 2014-01-23 15:43:55 -0500 |
Would it be possible to use the before_transcode callback to do this? |
Didn't get a chance to update this with my fix! I ended up using the MiniExiftool gem to get the rotation of the video. Here's the full uploader: require 'carrierwave/processing/mime_types' class VideoPathUploader < CarrierWave::Uploader::Base process :encode def encode
end |
Awesome! Thank you. |
I am facing the issue with a portrait video.The thumbnail is rotating right. I am using the above code.Can you suggest me on that. when i am removing custom attribute working fine but image is a blur and stretch more. please tell me what type of custom attribut need to use. |
I have a video that is 1080 x 1920. When it gets uploaded via carrierwave-video, the video appears to be rotated 90 degrees counter-clockwise. How can I ensure that the video is not rotated? What types of methods can I use to detect the video's dimensions when the user uploads the file?
This is only an issue when uploading portrait videos.
The text was updated successfully, but these errors were encountered: