Milestone Release Notes

This page includes a list of high level updates for each milestone release.


Milestone 85

  • Added GrContext::oomed() which reports whether Skia has seen a GL_OUT_OF_MEMORY error from Open GL [ES] or VK_ERROR_OUT_OF_*_MEMORY from Vulkan. https://review.skia.org/298216

  • Add option on SkSurface::flush to pass in a GrBackendSurfaceMutableState which we will set the gpu backend surface to be at the end of the flush. https://review.skia.org/295567

  • Add GrContext function to set mutable state on a backend surface. Currently this is only used for setting vulkan VkImage layout and queue family. https://review.skia.org/293844

  • SkSurface factores that take GrBackendTexture or GrBackendRenderTarget now always call the release proc (if provided) on failure. SkSurface::replaceBackendTexture also calls the release proc on failure. https://review.skia.org/293762

  • SkSurface::asyncRescaleAndReadPixels and SkSurfaceasyncRescaleAndReadPixelsYUV420 now require explicit GrContext submit to guarantee finite time before callback is invoked. https://review.skia.org/292840

  • Add VkSharingMode field to GrVkImageInfo. https://review.skia.org/293559

  • Move SkBitmapRegionDecoder into client_utils/android.

  • SkCanvas.clear and SkCanvas.drawColor now accept SkColor4f in addition to SkColor.

  • Remove SkSurface::MakeFromBackendTextureAsRenderTarget. This factory existed to work around issues with GL_TEXTURE_RECTANGLE that existed in Chrome's command buffer. Those issues have since been resolved. Use SkSurface::MakeFromBackendTexutre or SkSurface::MakeFromBackendRenderTarget instead. https://review.skia.org/292719

  • Adds submittedProc callback to GrFlushInfo which will be called when the work from the flush call is submitted to the GPU. This is specifically useful for knowing when semahpores sent with the flush have been submitted and can be waiting on. https://review.skia.org/291078

  • GrContext submit is now required to be called in order to send GPU work to the actual GPU. The flush calls simply produces 3D API specific objects that are ready to be submitted (e.g. command buffers). For the GL backend, the flush will still send commands to the driver. However, clients should still assume the must call submit which is where any glFlush that is need for sync objects will be called. There, are flushAndSubmit() functions of GrContext, SkSurface, and SkImage that will act like the previous flush() functions. This will flush the work and immediately call submit. https://review.skia.org/289033

  • Remove deprecated version of flush calls on GrContext and SkSurface. https://review.skia.org/2290540

  • SkCanvas::drawVertices and drawPatch now support mapping an SkShader without explicit texture coordinates. If they're not supplied, the local positions (vertex position or patch cubic positions) will be directly used to sample the SkShader. https://review.skia.org/290130


Milestone 84

  • Add api on GrContext, updateBackendTexture that will upload new data to a GrBackendTexture. https://review.skia.org/288909

  • Add GrContext getter to SkSurface. https://review.skia.org/289479

  • Deprecate GrContext and SkSurface flush() call and replace ith with flushAndSubmit(). This only effects the default flush call that takes no parameters. https://review.skia.org/289478

  • GrContext::createBackendTexture functions that initialize the texture no longer guarantee that all the data has been uploaded and the gpu is done with the texture. Instead the client can assume the upload work has been submitted to the gpu and they must wait for that work to finish before deleting the texture. This can be done via their own synchronization or by passing in a finish proc into the create calls which will be called when it is safe to delete the texture (at least in terms of work done during the create). https://review.skia.org/286517

  • Remove unused SkMaskFilter helpers: compbine, compose Note: shadermaskfilter will likely be removed next (clipShader should serve)

  • Add back SkCanvas::kPreserveLCDText_SaveLayerFlag to indicate that saveLayer() will preserve LCD-text. All text in the layer must be drawn on opaque background to ensure correct rendering.

  • Add the new directory client_utils/ for code that is specific to a single client and should be considered separate from Skia proper. Move SkFrontBufferedStream into the subdir android/.

  • SkBitmap and SkPixmap‘s erase() methods now treat their color parameters consistently with the rest of Skia, with all SkColors and any untagged SkColor4fs interpreted as sRGB, not as a color in the bitmap’s color space. SkPixmap::erase(SkColor4f) now takes an SkColorSpace, so you can pass pixmap.colorSpace() if you want the old behavior.

  • SkCamera.h and SkMatrix44.h are DEPRECATED. Use SkM44 if you want to have 3d transformations.

  • Changed Dilate and Erode image filters to take SkScalar for radius instead of int. While the image filters themselves are defined in terms of discrete pixels, the radii provided by the user are mapped through the CTM so taking ints forced over discretization. After mapping through the CTM the radii are now rounded to pixels. https://review.skia.org/281731 https://review.skia.org/282636

  • Updated the contract of GrContext and SkSurface flush calls in regards to semaphores. Made it clear that the caller is responsible for deleting any initialized semaphores after the flush call regardless if we were able to submit them or not. Also, allows skia to only submit a subset of the requested semaphores if we failed to create some. https://review.skia.org/282265

  • SkCanvas::drawVertices will now always fill the triangles specified by the vertices. Previously, vertices with no colors and no (texture coordinates or shader) would be drawn in wireframe. https://review.skia.org/282043


Milestone 83

  • Remove localmatrix option from SkShaders::[Blend, Lerp]

  • Fill out Direct3D parameters for backend textures and backend rendertargets.

  • SkImage::makeTextureImage() takes an optional SkBudgeted param

  • Made non-GL builds of GPU backend more robust. https://review.skia.org/277456

  • MoltenVK support removed. Use Metal backend instead. https://review.skia.org/277612


Milestone 82

  • Removed drawBitmap and related functions from SkDevice; all public drawBitmap functions on SkCanvas automatically wrap the bitmap in an SkImage and call the equivalent drawImage function. Drawing mutable SkBitmaps will now incur a mandatory copy. Switch to using SkImage directly or mark the bitmap as immutable before drawing.

  • Removed “volatile” flag from SkVertices. All SkVertices objects are assumed to be volatile (the previous default behavior).

  • Removed exotic legacy bitmap functions from SkCanvas (drawBitmapLattic, drawBitmapNine); the exotic SkImage functions still exist.

  • Make it possible to selectively turn on/off individual encoders/decoders, using skia_use_(libpng/libjpeg_turbo/libwebp)(decode/encode).

  • Removed GrGpuResource, GrSurface, and GrTexture from public api. These were not meant to be public, and we now can move them into src. Also removed getTexture function from SkImage.h

  • Removed Bones from SkVertices

  • Added a field to GrContextOptions that controls whether GL errors are checked after GL calls that allocate textures, etc. It also controls checking for shader compile success, and program linking success.

  • Made SkDeferredDisplayList.h officially part of the public API (i.e., moved it to include/core). Also added a ProgramIterator to SkDeferredDisplayList which allows clients to pre-compile some of the shaders the DDL requires.

  • Added two new helper methods to SkSurfaceCharacterization: createBackendFormat and createFBO0. These make it easier for clients to create new surface characterizations that differ only a little from an existing surface characterization.

  • Removed SkTMax and SkTMin.

  • Removed SkTClamp and SkClampMax.

  • Removed SkScalarClampMax and SkScalarPin.

  • Removed SkMax32 and SkMin32.

  • Removed SkMaxScalar and SkMinScalar.

  • SkColorSetA now warns if the result is unused.

  • An SkImageInfo with a null SkColorSpace passed to SkCodec::getPixels() and related calls is treated as a request to do no color correction at decode time.

  • Add new APIs to add attributes to document structure node when creating a tagged PDF.

  • Remove CGFontRef parameter from SkCreateTypefaceFromCTFont. Use CTFontManagerCreateFontDescriptorFromData instead of CGFontCreateWithDataProvider to create CTFonts to avoid memory use issues.

  • Added SkCodec:: and SkAndroidCodec::getICCProfile for reporting the native ICC profile of an encoded image, even if it doesn't map to an SkColorSpace.

  • SkSurface::ReplaceBackendTexture takes ContentChangeMode as a parameter, which allow callers to specify whether retain a copy of the current content.

  • Enforce the existing documentation in SkCanvas::saveLayer that it ignores any mask filter on the restore SkPaint. The ‘coverage’ of a layer is ill-defined, and masking should be handled by pre-clipping or using the auxiliary clip mask image of the SaveLayerRec.

Milestone 81

  • Added support for GL_NV_fence extension.

  • Make SkImageInfo::validRowBytes require rowBytes to be pixel aligned. This makes SkBitmap match the behavior of raster SkSurfaces in rejecting non-aligned rowBytes.

  • Added an SkImage::MakeRasterFromCompressed entry point. Also updated SkImage::MakeFromCompressed to decompress the compressed image data if the GPU doesn‘t support the specified compression type (i.e., macOS Metal doesn’t support BC1_RGB8_UNORM so such compressed images will always be decompressed on that platform).

  • Added support for BC1 RGBA compressed textures

  • Added CachingHint to SkImage::makeRasterImage

  • Added SkAnimatedImage::getCurrentFrame()

  • Add support to create an SkSurface from an MTKView, with delayed acquisition of the MTLDrawable. Entry point: SkSurface::MakeFromMTKView

  • Removed SkIRect::EmptyIRect(). Use SkIRect::MakeEmpty() instead. https://review.skia.org/262382/

  • Moved SkRuntimeEffect to public API. This is the new (experimental) interface to custom SkSL shaders and color filters.

  • Added BC1 compressed format support. Metal and Vulkan seem to only support the BC formats on desktop machines.

  • Added compressed format support for backend texture creation API. This adds the following new entry points: GrContext::compressedBackendFormat GrContext::createCompressedBackendTexture The latter method comes in variants that allow color-initialized and compressed texture data initialized.

  • Added SkMatrix::MakeTrans(SkIVector) https://review.skia.org/259804


Milestone 80


Milestone 79


Milestone 78