[Webkit-unassigned] [Bug 181990] [EME][GStreamer] Add support for the encrypted Caps in GStreamerUtilities

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Feb 9 01:59:17 PST 2018


Xabier Rodríguez Calvar <calvaris at igalia.com> changed:

           What    |Removed                     |Added
 Attachment #333381|review?, commit-queue?      |review+, commit-queue-
              Flags|                            |

--- Comment #15 from Xabier Rodríguez Calvar <calvaris at igalia.com> ---
Comment on attachment 333381
  --> https://bugs.webkit.org/attachment.cgi?id=333381

View in context: https://bugs.webkit.org/attachment.cgi?id=333381&action=review

> Source/WebCore/platform/graphics/gstreamer/GStreamerUtilities.cpp:63
> +        GST_ERROR("Failed to get the video size and format, they are not a video caps");

ERROR -> WARNING. caps is always plural so "these are not video caps".

> Source/WebCore/platform/graphics/gstreamer/GStreamerUtilities.cpp:75
> +            pixelAspectRatioNumerator = pixelAspectRatioDenominator = 1;

This goes against coding style, one instruction at a line.

> Source/WebCore/platform/graphics/gstreamer/GStreamerUtilities.cpp:99
> +        GST_WARNING("Failed to get the video resolution, they are not a video caps");

these are not video caps

> Source/WebCore/platform/graphics/gstreamer/GStreamerUtilities.cpp:100
> +        return std::optional<FloatSize>();

You need to return std::nullopt here, otherwise asking for has_value will answer always yes.

> Source/WebCore/platform/graphics/gstreamer/GStreamerUtilities.cpp:123
> +    return std::optional<FloatSize>(FloatSize(width, height * (static_cast<float>(pixelAspectRatioNumerator) / static_cast<float>(pixelAspectRatioDenominator))));

You can use std::make_optional

You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20180209/c0989e46/attachment-0001.html>

More information about the webkit-unassigned mailing list