RESOLVED FIXED 39206
[GStreamer] video painting support on mac port
https://bugs.webkit.org/show_bug.cgi?id=39206
Summary [GStreamer] video painting support on mac port
Philippe Normand
Reported 2010-05-17 01:36:27 PDT
an ImageGStreamerMac implementation is needed. It would take a GstBuffer as input and create a CG Image object with the buffer data.
Attachments
proposed patch (4.19 KB, patch)
2010-05-17 01:41 PDT, Philippe Normand
no flags
proposed patch (4.20 KB, patch)
2010-05-17 02:27 PDT, Philippe Normand
eric.carlson: review+
eric.carlson: commit-queue-
Philippe Normand
Comment 1 2010-05-17 01:41:43 PDT
Created attachment 56224 [details] proposed patch
WebKit Review Bot
Comment 2 2010-05-17 01:43:06 PDT
Attachment 56224 [details] did not pass style-queue: Failed to run "['WebKitTools/Scripts/check-webkit-style', '--no-squash']" exit_code: 1 WebCore/platform/graphics/gstreamer/ImageGStreamer.h:58: Tab found; better to use spaces [whitespace/tab] [1] Total errors found: 1 in 3 files If any of these errors are false positives, please file a bug against check-webkit-style.
Philippe Normand
Comment 3 2010-05-17 02:27:05 PDT
Created attachment 56227 [details] proposed patch
Eric Carlson
Comment 4 2010-05-20 09:45:21 PDT
Comment on attachment 56227 [details] proposed patch > + * > + * You should have received a copy of the GNU Library General Public License > + * aint with this library; see the file COPYING.LIB. If not, write to > This typo is back, "aint" should be "along" (see https://bugs.webkit.org/show_bug.cgi?id=36442). > + CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB(); > + CGImageRef frameImage = CGImageCreate(size.width(), size.height(), 8, 32, size.width()*4, colorSpace, > + kCGBitmapByteOrder32Little | kCGImageAlphaFirst, provider.get(), 0, false, kCGRenderingIntentDefault); > + m_image = BitmapImage::create(frameImage); > +} > You are leaking the CGColorSpaceRef. Since your frames are always in the same color space, you could use a static. r=me with these changes
Eric Carlson
Comment 5 2010-05-20 09:49:19 PDT
Actually, one more thing - I don't think "ImageGStreamerMac.mm" is the best name for this file because it is really about using CoreGraphics images. The alternate version is "ImageGStreamerCairo", so how about "ImageGStreamerCG" instead?
Philippe Normand
Comment 6 2010-05-20 09:55:29 PDT
(In reply to comment #5) > Actually, one more thing - I don't think "ImageGStreamerMac.mm" is the best name for this file because it is really about using CoreGraphics images. The alternate version is "ImageGStreamerCairo", so how about "ImageGStreamerCG" instead? Ok I will rename and apply the changes you suggested. Thanks!
Philippe Normand
Comment 7 2010-05-21 06:20:40 PDT
Note You need to log in before you can comment on or make changes to this bug.