-
Notifications
You must be signed in to change notification settings - Fork 142
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
VideoChooserBlock #15
Comments
I'm torn on this idea. As we tried with an earlier version, the CMS is really not suited to compress or process videos as-is without making exec/system calls. I would also not want to encourage the CMS to be used for video management by calling out a "Videos" library similar to "Images" and "Documents". But I also realize that video backgrounds are not entirely uncommon and a bit clunky to implement as-is. Perhaps we offer the ability to upload a video background, limit the size to like 2MB by default to force the user to compress before uploading. But the video background would be managed directly as a file field in the block and not through a library style interface. Thoughts? |
Found this which might solve some of these problems: https://github.com/torchbox/wagtailmedia |
I would be interested in helping to add support around wagtailmedia. Is this still of interest to the project? This is really the only thing missing from being able to embed any html5 video: torchbox/wagtailmedia#65 And it is a simple problem to fix |
torchbox/wagtailmedia#65 was fixed by merged pr torchbox/wagtailmedia#67 so now there is an "official" way to output html5 audio/video sources. There is no longer a need to consider specialized logic around html5 audio/video element source ordering and creation here - it is handled by wagtailmedia and the project's media model. I would mention that wagtailmedia supports both audio and video, so perhaps use a more indicative block name. Or either provide two blocks - one for audio and one for video - but the overlap in features between audio and video probably only warrants one block which also simplifies the chooser. Consider https://github.com/videojs/video.js for the playback layer. It offers a sleek look which is customizable and works for audio or video elements plus also supports adaptive streaming (hls and dash) - https://github.com/videojs/http-streaming If you would like to assign the issue to me, I will complete it with an assurance that you will accept and merge a satisfactory PR |
Thanks for the info @thenewguy. It would be great to have your contribution if we can iron out the requirements first. Since you seem to know more about wagtailmedia, maybe you could answer a few questions before we decide what to do:
Having a media block as you describe which provides a native HTML5 video/audio tag would be a nice addition (similar to our document block which provides a button/download). I don't know if Thanks again for your willingness to undertake this feature! |
1a) Wagtailmedia leaves this up to the site implementation. The default case returns the url of the uploaded file and it's mimetype for rendering the html5 element. The default case assumes the uploaded media is pre-processed for direct ingestion. For example, an mp4 containing h264 baseline video and stereo audio using the aac-lc codec. The templating is very easy and supports all cases using something like:
giving you something like:
or
1b) To handle unprocessed video from arbitratry user uploads you just add your 'transcoder' app to installed apps and tell wagtail media to use the swappable media model from the transcoder. It should override the "sources" property to return the transcoded sources instead of the uploaded media. 2 ) Short answer: yes. There are a few ways to limit the upload size depending on the site needs. Can you share more details about the problem scenarios you are trying to overcome with this? |
Closing this issue as I think we will not be implementing video features directly in coderedcms. This would be a great opportunity for a 3rd party package as necessary, which could be hooked in via features described in #305 |
HeroBlock
would really benefit from having the ability to have full width background videos. For this we would need aVideoChooserBlock
that mimics the functionality ofImageChooserBlock
, but with video. This would probably require the implementation of our ownVideo
model to house/validate/compress the uploaded files.The text was updated successfully, but these errors were encountered: