Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upPut back video metadata #13094
Put back video metadata #13094
Conversation
highfive
commented
Aug 28, 2016
|
Heads up! This PR modifies the following files:
|
|
Does this require additional libraries to be installed on users' system? |
|
No. That's the whole point and the great improvement. |
|
cc @splav This will impact the plans for using mp4parse. |
|
r? @Manishearth |
|
First: The current metadata structure seems to be suitable only for video content. Are there any plans to support audio content as well? May we should make it more general to support both? |
|
I can make it more general (by providing a higher crate maybe? The name is video-metadata after all). And as for mp4parse, as long as it doesn't need strange dependencies, it's fine for the moment from my point of view. |
|
@GuillaumeGomez I was talking about Servo's structure. But sure, this can be changed later. |
|
As for video-metadata - may be it's ok, but ogg can contain audio as well and checking it twice in two crated seems a bit strange. |
|
@splav: For the moment, the thing is to target video to get their size. But if there are pure crates to get audio metadata, I can update video-metadata to add them (I still wonder if I should rename it...). |
|
My |
|
@est31, @GuillaumeGomez my point that it should be one metadata wrapper crate for servo for both audio and video containers. The other option is to have one crate for audio and one for video leads to parsing ogg container twice: in both video and audio crates. It seems a bit strange for me. And IMO the crate rename is the thing that should be done the earlier the better, in case the crate will support both audio and video metadata parsing. |
|
I created the new crate (which handles both video and audio metadata) and updated this PR. |
| let dur = meta.audio.duration.unwrap_or(::std::time::Duration::new(0, 0)); | ||
| *elem.video.borrow_mut() = Some(VideoMedia { | ||
| format: format!("{:?}", meta.format), | ||
| duration: Duration::seconds(dur.as_secs() as i64) + |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
est31
Aug 29, 2016
Contributor
@splav dur is of type std::time::Duration, while the VideoMedia struct requires time::Duration from the time crate.
This comment has been minimized.
This comment has been minimized.
|
Think you could publish audio_video_metadata? Would be great to avoid yet another Git dependency. |
|
@nox: No, I have mixed origin for this crate (because mp4rust didn't merge my PR yet) so I can't publish it for the moment. |
Put back video metadata I updated the `video-metadata-rs` crate: now, no more ffmpeg, just pure rust. The webm format isn't checked yet. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/13094) <!-- Reviewable:end -->
|
@bors-servo: try retry |
Put back video metadata I updated the `video-metadata-rs` crate: now, no more ffmpeg, just pure rust. The webm format isn't checked yet. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/13094) <!-- Reviewable:end -->
|
|
|
Not only this PR introduces timeouts, but it doesn't seem to make any new test pass. |
|
Updated. |
|
The timeouts are fine, since the reflect the actual state of the world when it comes to audio elements. The current HTMLMediaElement code just lies about understanding audio metadata. |
|
@bors-servo r+ |
|
|
Put back video metadata I updated the `video-metadata-rs` crate: now, no more ffmpeg, just pure rust. The webm format isn't checked yet. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/13094) <!-- Reviewable:end -->
|
|
|
@bors-servo r+
|
|
|
|
|
@bors-servo retry |
Put back video metadata I updated the `video-metadata-rs` crate: now, no more ffmpeg, just pure rust. The webm format isn't checked yet. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/13094) <!-- Reviewable:end -->
|
|
GuillaumeGomez commentedAug 28, 2016
•
edited by larsbergstrom
I updated the
video-metadata-rscrate: now, no more ffmpeg, just pure rust. The webm format isn't checked yet.This change is