Bug 180262

Summary: [Gstreamer][MSE] Add string representation for GStreamerMediaSample
Product: WebKit Reporter: Alicia Boya García <aboya>
Component: MediaAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: calvaris, commit-queue, ews-watchlist, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch
none
Patch
none
Patch none

Description Alicia Boya García 2017-12-01 10:23:47 PST
GStreamerMediaSample::dump() represents the sample as an empty string, which is not helpful for debugging.

This method is supposed to write useful information about the sample like PTS, DTS, duration...
The set of properties to write is platform-dependent.
Comment 1 Alicia Boya García 2017-12-01 10:25:56 PST
Created attachment 328116 [details]
Patch
Comment 2 EWS Watchlist 2017-12-01 10:31:47 PST
Attachment 328116 [details] did not pass style-queue:


ERROR: Source/WebCore/platform/graphics/gstreamer/mse/GStreamerMediaSample.cpp:120:  Missing space after ,  [whitespace/comma] [3]
ERROR: Source/WebCore/platform/graphics/gstreamer/mse/GStreamerMediaSample.cpp:121:  Weird number of spaces at line-start.  Are you using a 4-space indent?  [whitespace/indent] [3]
Total errors found: 2 in 3 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Alicia Boya García 2017-12-01 12:31:25 PST
Created attachment 328131 [details]
Patch
Comment 4 Alicia Boya García 2017-12-01 16:06:41 PST
Created attachment 328175 [details]
Patch
Comment 5 Alicia Boya García 2017-12-01 16:09:58 PST
webkit-patch upload -g <hash> has uploaded the wrong patch...
Comment 6 Alicia Boya García 2017-12-01 16:10:47 PST
Created attachment 328177 [details]
Patch
Comment 7 Xabier Rodríguez Calvar 2017-12-05 00:24:46 PST
Comment on attachment 328177 [details]
Patch

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

Patch is not wrong, though I'd improve it.

> Source/WebCore/platform/graphics/gstreamer/mse/GStreamerMediaSample.cpp:120
> +    out.print("{PTS(", presentationTime(), "), DTS(", decodeTime(), "), duration(", duration(), "), flags(", (int)flags(),

Instead of (int), I'd use a C++ cast, though in this case I'd rather dump the flags instead of just casting them to an int.
Comment 8 Alicia Boya García 2018-02-12 12:04:10 PST
Created attachment 333613 [details]
Patch
Comment 9 WebKit Commit Bot 2018-02-13 04:11:38 PST
Comment on attachment 333613 [details]
Patch

Clearing flags on attachment: 333613

Committed r228418: <https://trac.webkit.org/changeset/228418>
Comment 10 WebKit Commit Bot 2018-02-13 04:11:39 PST
All reviewed patches have been landed.  Closing bug.
Comment 11 Radar WebKit Bug Importer 2018-02-13 04:12:27 PST
<rdar://problem/37493448>