Changeset 261922 in webkit
- Timestamp:
- May 20, 2020 8:52:36 AM (4 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r261919 r261922 1 2020-05-20 Philippe Normand <pnormand@igalia.com> 2 3 [GStreamer] <img> tag needs to support video formats 4 https://bugs.webkit.org/show_bug.cgi?id=180370 5 6 Reviewed by Xabier Rodriguez-Calvar. 7 8 Update TestExpectations for tests using videos for the <img> tag. 9 10 * http/conf/flatpak-httpd.conf: 11 * platform/glib/TestExpectations: 12 * platform/gtk/TestExpectations: 13 * platform/wpe/TestExpectations: 14 1 15 2020-05-20 Alan Kinsley <zalan@apple.com> 2 16 -
trunk/LayoutTests/http/conf/flatpak-httpd.conf
r259341 r261922 52 52 UseCanonicalName On 53 53 HostnameLookups Off 54 55 TypesConfig /usr/conf/mime.types56 54 57 55 LogLevel warn -
trunk/LayoutTests/platform/glib/TestExpectations
r261902 r261922 74 74 # 2. EXPECTED FAILURES 75 75 #//////////////////////////////////////////////////////////////////////////////////////// 76 77 webkit.org/b/211995 fast/images/animated-image-mp4.html [ Failure ] 76 78 77 79 #//////////////////////////////////////////////////////////////////////////////////////// -
trunk/LayoutTests/platform/gtk/TestExpectations
r261902 r261922 1069 1069 webkit.org/b/175419 imported/w3c/web-platform-tests/fetch/api/abort/serviceworker-intercepted.https.html [ Failure Pass ] 1070 1070 1071 # Loading MP4 as an image is not supported by GTK1072 webkit.org/b/180370 fast/images/animated-image-mp4.html [ Skip ]1073 webkit.org/b/180370 http/tests/images/image-supports-video.html [ Skip ]1074 webkit.org/b/180370 fast/images/animated-image-mp4-crash.html [ Skip ]1075 1076 1071 # GTK ought to support async clipboard 1077 1072 webkit.org/b/211979 editing/async-clipboard/clipboard-change-data-while-writing.html [ Failure ] -
trunk/LayoutTests/platform/wpe/TestExpectations
r261913 r261922 369 369 370 370 Bug(WPE) fast/hidpi/pdf-image-scaled.html [ Skip ] 371 372 # Loading MP4 as an image is not supported373 webkit.org/b/180370 fast/images/animated-image-mp4.html [ Skip ]374 webkit.org/b/180370 fast/images/animated-image-mp4-crash.html [ Skip ]375 webkit.org/b/180370 http/tests/images/image-supports-video.html [ Skip ]376 371 377 372 # Only Mac has implemented DictionaryLookup -
trunk/Source/WebCore/ChangeLog
r261921 r261922 1 2020-05-20 Philippe Normand <pnormand@igalia.com> 2 3 [GStreamer] <img> tag needs to support video formats 4 https://bugs.webkit.org/show_bug.cgi?id=180370 5 6 Reviewed by Xabier Rodriguez-Calvar. 7 8 GStreamer implementation of the ImageDecoder. It currently doesn't support zero-copy 9 rendering though due to the the NativeImagePtr requirement. 10 11 * platform/GStreamer.cmake: 12 * platform/MIMETypeRegistry.cpp: 13 (WebCore::MIMETypeRegistry::isSupportedImageVideoOrSVGMIMEType): 14 * platform/graphics/ImageDecoder.cpp: 15 (WebCore::ImageDecoder::create): 16 (WebCore::ImageDecoder::supportsMediaType): 17 * platform/graphics/gstreamer/ImageDecoderGStreamer.cpp: Added. 18 (WebCore::toSample): 19 (WebCore::ImageDecoderGStreamer::create): 20 (WebCore::ImageDecoderGStreamer::ImageDecoderGStreamer): 21 (WebCore::ImageDecoderGStreamer::supportsContainerType): 22 (WebCore::ImageDecoderGStreamer::canDecodeType): 23 (WebCore::ImageDecoderGStreamer::encodedDataStatus const): 24 (WebCore::ImageDecoderGStreamer::size const): 25 (WebCore::ImageDecoderGStreamer::repetitionCount const): 26 (WebCore::ImageDecoderGStreamer::uti const): 27 (WebCore::ImageDecoderGStreamer::frameOrientationAtIndex const): 28 (WebCore::ImageDecoderGStreamer::frameDurationAtIndex const): 29 (WebCore::ImageDecoderGStreamer::frameHasAlphaAtIndex const): 30 (WebCore::ImageDecoderGStreamer::frameBytesAtIndex const): 31 (WebCore::ImageDecoderGStreamer::createFrameImageAtIndex): 32 (WebCore::ImageDecoderGStreamer::setData): 33 (WebCore::ImageDecoderGStreamer::clearFrameBufferCache): 34 (WebCore::ImageDecoderGStreamer::sampleAtIndex const): 35 (WebCore::ImageDecoderGStreamer::InnerDecoder::decodebinPadAddedCallback): 36 (WebCore::ImageDecoderGStreamer::InnerDecoder::connectDecoderPad): 37 (WebCore::ImageDecoderGStreamer::handleSample): 38 (WebCore::ImageDecoderGStreamer::InnerDecoder::handleMessage): 39 (WebCore::ImageDecoderGStreamer::InnerDecoder::preparePipeline): 40 (WebCore::ImageDecoderGStreamer::InnerDecoder::run): 41 (WebCore::ImageDecoderGStreamer::InnerDecoder::encodedDataStatus const): 42 (WebCore::ImageDecoderGStreamer::pushEncodedData): 43 * platform/graphics/gstreamer/ImageDecoderGStreamer.h: Added. 44 * platform/graphics/gstreamer/ImageGStreamer.h: 45 (WebCore::ImageGStreamer::createImage): 46 (WebCore::ImageGStreamer::image): 47 (WebCore::ImageGStreamer::setCropRect): 48 (WebCore::ImageGStreamer::rect): 49 (WebCore::ImageGStreamer::hasAlpha const): 50 * platform/graphics/gstreamer/ImageGStreamerCairo.cpp: 51 (WebCore::ImageGStreamer::ImageGStreamer): 52 * platform/graphics/gstreamer/MediaSampleGStreamer.h: 53 1 54 2020-05-20 Andy Estes <aestes@apple.com> 2 55 -
trunk/Source/WebCore/platform/GStreamer.cmake
r260987 r261922 14 14 platform/graphics/gstreamer/GStreamerRegistryScanner.cpp 15 15 platform/graphics/gstreamer/GStreamerVideoFrameHolder.cpp 16 platform/graphics/gstreamer/ImageDecoderGStreamer.cpp 16 17 platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp 17 18 platform/graphics/gstreamer/MediaEngineConfigurationFactoryGStreamer.cpp -
trunk/Source/WebCore/platform/MIMETypeRegistry.cpp
r261479 r261922 59 59 #endif 60 60 61 #if USE(GSTREAMER) 62 #include "ImageDecoderGStreamer.h" 63 #endif 64 61 65 namespace WebCore { 62 66 … … 434 438 #if HAVE(AVASSETREADER) 435 439 if (ImageDecoderAVFObjC::supportsContainerType(mimeType)) 440 return true; 441 #endif 442 443 #if USE(GSTREAMER) 444 if (ImageDecoderGStreamer::supportsContainerType(mimeType)) 436 445 return true; 437 446 #endif -
trunk/Source/WebCore/platform/graphics/ImageDecoder.cpp
r232136 r261922 39 39 #endif 40 40 41 #if USE(GSTREAMER) 42 #include "ImageDecoderGStreamer.h" 43 #endif 44 41 45 namespace WebCore { 42 46 … … 48 52 if (!ImageDecoderCG::canDecodeType(mimeType) && ImageDecoderAVFObjC::canDecodeType(mimeType)) 49 53 return ImageDecoderAVFObjC::create(data, mimeType, alphaOption, gammaAndColorProfileOption); 54 #endif 55 56 #if USE(GSTREAMER) 57 if (ImageDecoderGStreamer::canDecodeType(mimeType)) 58 return ImageDecoderGStreamer::create(data, mimeType, alphaOption, gammaAndColorProfileOption); 50 59 #endif 51 60 … … 77 86 #endif 78 87 88 #if USE(GSTREAMER) 89 if (ImageDecoderGStreamer::supportsMediaType(type)) 90 return true; 91 #endif 92 79 93 return false; 80 94 } -
trunk/Source/WebCore/platform/graphics/gstreamer/ImageGStreamer.h
r235171 r261922 18 18 */ 19 19 20 #ifndef ImageGStreamer_h 21 #define ImageGStreamer_h 20 #pragma once 22 21 23 22 #if ENABLE(VIDEO) && USE(GSTREAMER) … … 38 37 39 38 class ImageGStreamer : public RefCounted<ImageGStreamer> { 40 41 42 43 44 45 39 public: 40 static RefPtr<ImageGStreamer> createImage(GstSample* sample) 41 { 42 auto image = adoptRef(new ImageGStreamer(sample)); 43 if (!image->m_image) 44 return nullptr; 46 45 47 48 49 46 return image; 47 } 48 ~ImageGStreamer(); 50 49 51 52 53 54 55 50 BitmapImage& image() 51 { 52 ASSERT(m_image); 53 return *m_image.get(); 54 } 56 55 57 58 59 60 61 62 63 64 56 void setCropRect(FloatRect rect) { m_cropRect = rect; } 57 FloatRect rect() 58 { 59 ASSERT(m_image); 60 if (!m_cropRect.isEmpty()) 61 return FloatRect(m_cropRect); 62 return FloatRect(0, 0, m_image->size().width(), m_image->size().height()); 63 } 65 64 66 private: 67 ImageGStreamer(GstSample*); 68 RefPtr<BitmapImage> m_image; 69 FloatRect m_cropRect; 65 bool hasAlpha() const { return m_hasAlpha; } 66 67 private: 68 ImageGStreamer(GstSample*); 69 RefPtr<BitmapImage> m_image; 70 FloatRect m_cropRect; 70 71 #if USE(CAIRO) 71 72 72 GstVideoFrame m_videoFrame; 73 bool m_frameMapped { false }; 73 74 #endif 74 }; 75 bool m_hasAlpha { false }; 76 }; 77 75 78 } 76 77 #endif // USE(GSTREAMER) 78 #endif 79 #endif // ENABLE(VIDEO) && USE(GSTREAMER) -
trunk/Source/WebCore/platform/graphics/gstreamer/ImageGStreamerCairo.cpp
r248464 r261922 42 42 // Right now the TextureMapper only supports chromas with one plane 43 43 ASSERT(GST_VIDEO_INFO_N_PLANES(&videoInfo) == 1); 44 45 m_hasAlpha = GST_VIDEO_INFO_HAS_ALPHA(&videoInfo); 44 46 45 47 GstBuffer* buffer = gst_sample_get_buffer(sample); -
trunk/Source/WebCore/platform/graphics/gstreamer/MediaSampleGStreamer.h
r258844 r261922 30 30 namespace WebCore { 31 31 32 class MediaSampleGStreamer final: public MediaSample {32 class MediaSampleGStreamer : public MediaSample { 33 33 public: 34 34 static Ref<MediaSampleGStreamer> create(GRefPtr<GstSample>&& sample, const FloatSize& presentationSize, const AtomString& trackId) … … 56 56 void dump(PrintStream&) const override; 57 57 58 protected: 59 MediaSampleGStreamer(GRefPtr<GstSample>&&, const FloatSize& presentationSize, const AtomString& trackId); 60 virtual ~MediaSampleGStreamer() = default; 61 58 62 private: 59 MediaSampleGStreamer(GRefPtr<GstSample>&&, const FloatSize& presentationSize, const AtomString& trackId);60 63 MediaSampleGStreamer(const FloatSize& presentationSize, const AtomString& trackId); 61 virtual ~MediaSampleGStreamer() = default;62 64 63 65 MediaTime m_pts;
Note: See TracChangeset
for help on using the changeset viewer.