-
Notifications
You must be signed in to change notification settings - Fork 45
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
Change thumbnail Content type video/mp4 to image/png #6
Comments
Thanx for the question. I’ll try to help you asap. |
Please check if the official doc help on this https://github.com/carrierwaveuploader/carrierwave#setting-the-content-type |
I have the same problem. My image files have a content-type of video/quicktime on amazon s3. I've added require 'carrierwave/processing/mime_types' and process :set_content_type but it did not fix the problem. Did anyone figure out how to solve it? |
I’ll try to, thank you. 2013/10/23 ttseng [email protected]
Yours truly, Pavel. |
were you able to resolve the issue? |
Not yet. This week perhaps... 2013/10/28 ttseng [email protected]
Yours truly, Pavel. |
+1 |
I solved this issue by overriding the process set_content_type as follows: require 'carrierwave/processing/mime_types' class VideoPathUploader < CarrierWave::Uploader::Base version :thumb do def set_content_type_png(*args) end I had to do this for all file types (I was using the carrierwave-video gem to convert video file types, so I had to define processes for each file type I created). It's a bit hacky, but it worked for me. |
Thanks. I’ll probably use some of it. 2013/11/18 ttseng [email protected]
Yours truly, Pavel. |
I am still facing the same issue. After using the above code I am getting the below error:
Any help would be appreciated. Thanks |
@ttseng would you please help clarifying @rakesh050791 ’s Q? I hope I’ll fix it in the library asap. |
Hello smith, As we need the thumbnail for the video uploaded in our rails application. we are using this library for the same, but we are unable to reach at our goal. we are using carrierwave for video uploading. but by using the code mentioned in the library for thumbnail, we are not getting the exact thumbnail for the same video. I am attaching my video uploader screen , please see. Quick reply would be appreciated. |
Do you mean you see a thumbnail of a different video or what? |
Does your version of ffmpeg/ffmpegthumbnailer support the format you use (3gp)? |
I have tried with mp 4 also and i've installed ffmpegthumbnailer today itself. Could you please update me how can i check this ? |
Just be sure it supports all the needed formats. Also, it’d be a great help if you try CLI-run of ffmpegthumbnailer on the sample file of the offending format and show me the CLI output. Thanks in advance! |
Just run into the same issue and @ttseng fix worked for me, are you planning to fix this anytime soon or accepting PRs for this? |
@rakesh050791 @00dav00 thnx for the report ❤️ . Will decide ASAP. |
HI argent-smith , Actually i am facing with video thumbnail issue. my issue) when i uploading a video , the thumbnail image is stretching.FOr youtube videos ,it's fine but if it's system videos,the thumbnails is stretching. I am using carrier wave gaem.Following is the my code base. ` include CarrierWave::Video # for your video processing version :medium, if: :image? do version :thumb, if: :video? do
end CAn you please suggest me on this? Thank you un advance |
The Mime Types feature was removed from carrierwave. As of now it seems impossible to set the mime type correctly using this gem, resulting in thumbnails not displaying from on iOS. EDIT: False alarm! You don't need to include the mime type carrierwave stuff. Just set the content type in a |
Thnx for notice. I'll see what could be done with this. |
Helped me #15 (comment) |
HI,
When i upload a mp4 video, video and video thumbnail both content types are storing as video/mp4. how can i set vide content type to video/mp4 and thumbnail content type image/png.
Uploder.rb:
The text was updated successfully, but these errors were encountered: