vp8 suitability for screencast...

159 views
Skip to first unread message

bryand...@gmail.com

unread,
Apr 14, 2011, 6:12:42 PM4/14/11
to webm-d...@webmproject.org
I want to record a screencast in a format that will play in the <video> tag.  

I haven't tried recording a screencast with libvpx yet, and I wonder how well it would do.  Any thoughts on this, or the best open source alternative?  

Flash screen video is an option, but I would prefer <video> over flash player.

Thanks for any ideas/thoughts.


mi...@multimedia.cx

unread,
Apr 14, 2011, 6:28:12 PM4/14/11
to webm-d...@webmproject.org
> I want to record a screencast in a format that will play in the <video>
> tag.

Perhaps H.264 with a YUV 4:4:4 colorspace, assuming that the browser
supports both H.264 video and the profile that will allow YUV 4:4:4.

> I haven't tried recording a screencast with libvpx yet, and I wonder how
> well it would do. Any thoughts on this, or the best open source
> alternative?

You could do a screencast in VP8 but you might not be satisfied with the
quality due to chroma subsampling (same problem with Theora and typical
H.264).

> Flash screen video is an option, but I would prefer <video> over flash
> player.

It seems like screencasting is another problem that HTML5/video doesn't
really address.

-Mike M.

bryand...@gmail.com

unread,
Apr 14, 2011, 7:04:51 PM4/14/11
to webm-d...@webmproject.org, mi...@multimedia.cx
Thanks for that suggestion / info, Mike.  

h.264 would not work since I will need to deploy the solution in a client download

Guess its FlashSV unless vp8 begins supporting 4:4:4.  



--
You received this message because you are subscribed to the Google Groups "WebM Discussion" group.
To post to this group, send email to webm-d...@webmproject.org.
To unsubscribe from this group, send email to webm-discuss...@webmproject.org.
For more options, visit this group at http://groups.google.com/a/webmproject.org/group/webm-discuss/?hl=en.


Monty Montgomery

unread,
Apr 14, 2011, 7:43:12 PM4/14/11
to webm-d...@webmproject.org, mi...@multimedia.cx
> You could do a screencast in VP8 but you might not be satisfied with the
> quality due to chroma subsampling (same problem with Theora and typical
> H.264).

Theora supports 4:4:4 video. You can use that and be happy.

Monty

Basil Mohamed Gohar

unread,
Apr 14, 2011, 7:48:08 PM4/14/11
to webm-d...@webmproject.org
RecordMyDesktop supports encoding to Theora in 4:4:4 as well.

Basil Mohamed Gohar

unread,
Apr 14, 2011, 7:49:42 PM4/14/11
to webm-d...@webmproject.org
On 04/14/2011 07:04 PM, bryand...@gmail.com wrote:
> Thanks for that suggestion / info, Mike.
>
> h.264 would not work since I will need to deploy the solution in a
> client download
>
> Guess its FlashSV unless vp8 begins supporting 4:4:4.
I have recorded a screencast using gstreamer in 4:2:0 video format and
aside from a slight softening of some higher contrast areas, I found the
video to be very acceptable. Text legibility was quite high. If I get
the opportunity, I might share some samples I've made or create one to
demonstrate that 4:2:0 shouldn't be a deciding factor.

Mike Melanson

unread,
Apr 14, 2011, 8:07:50 PM4/14/11
to webm-d...@webmproject.org

Thanks, I completely forgot about that. I just pulled down the 4:4:4
conformance sample from the Theora test suite.

Of course, in order to be useful in the context of the video tag, it needs
to be supported in browsers. Is it? An impromptu test indicates that
Firefox supports the 4:4:4 conformance sample while Google Chrome does
not.

--
-Mike Melanson

Tom Sparks

unread,
Apr 14, 2011, 8:24:39 PM4/14/11
to webm-d...@webmproject.org
--- On Fri, 15/4/11, Mike Melanson <mi...@multimedia.cx> wrote:

Have you thought about lossless vs lossy

flash screen video is lossless
H.264/Theora/WebM are lossy

H.264 dose have a lossless mode


tom_a_sparks
"It's a nerdy thing I like to do"

Mike Melanson

unread,
Apr 14, 2011, 8:33:22 PM4/14/11
to webm-d...@webmproject.org
> Have you thought about lossless vs lossy
>
> flash screen video is lossless
> H.264/Theora/WebM are lossy
>
> H.264 dose have a lossless mode

True, even though a Theora video might be 4:4:4 with very low
quantization, there is no warranty that it is losslessly encoded. However,
4:4:4 colorspace ideally mitigates some of the loss you would see with
screencast-type data.

H.264 does have a lossless mode. Whether that's supported by the target
browsers is yet another matter (similar to Firefox vs. Chrome in their
Theora/4:4:4 support).

--
-Mike Melanson

Gregory Maxwell

unread,
Apr 15, 2011, 12:38:00 AM4/15/11
to webm-d...@webmproject.org, Mike Melanson
On Thu, Apr 14, 2011 at 8:07 PM, Mike Melanson <mi...@multimedia.cx> wrote:
> Of course, in order to be useful in the context of the video tag, it needs
> to be supported in browsers. Is it? An impromptu test indicates that
> Firefox supports the 4:4:4 conformance sample while Google Chrome does
> not.

Chrome theora support can only barely be described as working. It falls
over with the slightest breeze. :(
E.g. Last time I checked, if the terver doesn't send
content-length? No video.

But we've gone way off topic now I fear.

4:4:4 is certainly a lot nicer for this sort of thing, and it's a
bit regrettable that webm doesn't have it. It's not obvious on all
signals, but some color combinations like red text on blue can look
pretty bad with 4:2:0.

I had some examples up, but I seemed to have lost them. But
basically for strong colors and small text 4:4:4 with fairly
non-trivial theora compression still looked better than lossless
4:2:0.

Mike Melanson

unread,
Apr 15, 2011, 1:40:17 AM4/15/11
to webm-d...@webmproject.org
On 04/14/2011 09:38 PM, Gregory Maxwell wrote:
> Chrome theora support can only barely be described as working. It falls
> over with the slightest breeze. :(

Are you dissing my Theora decoder?

http://multimedia.cx/eggs/optimizing-away-arrows/

:) It's all good.

> E.g. Last time I checked, if the terver doesn't send
> content-length? No video.

For the record, a 4:2:0 Theora video decoded in Chrome in my little
test; the 4:4:4 sample played blank.

> But we've gone way off topic now I fear.
>
> 4:4:4 is certainly a lot nicer for this sort of thing, and it's a
> bit regrettable that webm doesn't have it. It's not obvious on all
> signals, but some color combinations like red text on blue can look
> pretty bad with 4:2:0.
>
> I had some examples up, but I seemed to have lost them. But
> basically for strong colors and small text 4:4:4 with fairly
> non-trivial theora compression still looked better than lossless
> 4:2:0.

Just curious, what would be necessary to extend VP8 to cover 4:4:4?
Perhaps apply the Y coding method to each of the C planes (and upgrading
the bitstream format, of course)?

--
-Mike Melanson

Basil Mohamed Gohar

unread,
Apr 15, 2011, 3:23:08 AM4/15/11
to webm-d...@webmproject.org
Here a link to the screencast I was referring to:

http://media.basilgohar.com/samples/screencast/screencap-2010-12-18_11:47:08.webm

I originally captured it losslessly (straight to a y4m file, I think),
but I archived it as an FFV1. My encoding command line looked like this:

ffmpeg -i screencap-2010-12-18_11:47:08-ffv1.mkv -f yuv4mpegpipe -
2>/dev/null | vpxenc --output=screencap-2010-12-18_11:47:08.webm --best
--verbose --threads=4 --lag-in-frames=25 --end-usage=vbr
--target-bitrate=1000 --min-q=0 --max-q=63 --kf-max-dist=250
--auto-alt-ref=1 --tune=ssim -

Note that, because this is single pass, some of those options may not
actually have any effect.

The resulting file encoded to 423.3kbits/s with the above settings.

Basil Mohamed Gohar

unread,
Apr 15, 2011, 3:24:42 AM4/15/11
to webm-d...@webmproject.org
I forgot to mention that the point of this exercise was to demonstrate
that a lossy codec with 4:2:0 subsampled chroma can still be quite
suitable for screencasts. I believe this suitability factor will only
increase as the encoder matures and becomes more efficient.

bryand...@gmail.com

unread,
Apr 15, 2011, 1:11:00 PM4/15/11
to webm-d...@webmproject.org, Basil Mohamed Gohar
Thanks for posting that WebM screencast, Basil.  I agree with your assessment that subsampled chroma is not necessarily a problem for screencasts.   I'll have to try it out on some stock charts to see the effect with higher contrast content, but I am hopeful of the outcome.

Basil Mohamed Gohar

unread,
Apr 15, 2011, 4:55:22 PM4/15/11
to webm-d...@webmproject.org
On 04/15/2011 01:11 PM, bryand...@gmail.com wrote:
Thanks for posting that WebM screencast, Basil.  I agree with your assessment that subsampled chroma is not necessarily a problem for screencasts.   I'll have to try it out on some stock charts to see the effect with higher contrast content, but I am hopeful of the outcome.
Just as a note, I encoded that clip with the single-pass mode because that simulates what you would be doing if you were encoding straight to WebM in a real screencast.  However, if you have time to encode the video separately from capturing it, using two-pass mode + CQ mode would give you a better and more even quality video.  Right now, libvpx is much more optimized for two-pass mode than single pass mode.
Reply all
Reply to author
Forward
0 new messages