blob: b9c448c5c2bfe330139d6ee7f8a2b1a636772a8b [file] [log] [blame]
Skia Graphics Release Notes
This file includes a list of high level updates for each milestone release.
Milestone 104
* SkRuntimeEffect takes and returns a const SkData.
* SkRasterHandleAllocator::MakeCanvas now takes optional SkSurfaceProps.
* SkImage::MakeFromPicture and SkImageGenerator::MakeFromPicture now take an optional
SkSurfaceProps to use when rasterizing the picture.
* * *
Milestone 103
* SkSamplingOptions now includes anisotropic filtering. Implemented on GPU only.
* SkBitmap::clear and SkBitmap::clearColor take in SkColor4fs
* * *
Milestone 102
* Add glGetFloatv and glSamplerParameterf to GrGLInterface.
* GrGLCreateNativeInterface is removed. Use GrGLMakeNativeInterface.
* GrContextOptions::fSharpenMipmappedTextures is removed. MIP LOD is now always
biased on the GPU backend. The CPU backend implementation is modified to match
this behavior.
* Passing SkCanvas::kStrict_SrcRectConstraint disables mipmapping. The old behavior differed
between GPU and CPU. CPU always computed a new set of mipmap based on the subset. GPU restricted
the sampling coordinates to the subset in the base level but upper level pixels that map to
pixels outside the subset in the base level were still used. To get the previous CPU behavior
use SkImage::makeSubset() to make a subset image and draw that. The previous GPU behavior is
similar, though not exactly, equivalent to making a mipmapped image shader from the original
image and applying that to a rectangle.
* Fully disable experimental support for HW tessellation shaders.
GrContextOptions::fEnableExperimentalHardwareTessellation is ignored and behaves as if it is
false. The optimized path renderer no longer requires hardware tessellation at all, and
is automatically enabled when drawing to an SkSurface created with MSAA, or when
GrContextOptions::fInternalMultisampleCount is set to a non-zero value.
* * *
Milestone 101
* Add maxSurfaceSampleCountForColorType(SkColorType ct) in GrContextThreadSafeProxy
* Enums SkAlphaType and SkColorType are broken out into their own header files in include/core/
* * *
Milestone 100
* Skia now requires C++17 and the corresponding standard library (or newer).
* Skia on iOS now requires iOS 11 to build; earlier versions of iOS do not support C++17.
* The skstd::string_view and skstd::optional Skia classes have been replaced with the C++17 native
std::string_view and std::optional.
* Added SkSurface::resolveMSAA api to force Skia to resolve MSAA draws. Useful for when
Skia wraps a client's texture as the resolve target.
* All of the `makeShader` functions associated with `SkRuntimeEffect` no longer take an
`isOpaque` parameter. These functions will now make a best effort to determine if your
shader always produces opaque output, and optimize accordingly. If you definitely want your
shader to produce opaque output, do so in the shader's SkSL code. This can be done by adjusting
any `return` statement in your shader with a swizzle: `return color.rgb1;`.
* SkRSXform is now exported to DLL/.so files.
* * *
Milestone 99
* Added two new intrinsic functions to SkSL for use in runtime effects:
vec3 toLinearSrgb(vec3 color)
vec3 fromLinearSrgb(vec3 color)
These convert RGB color values between the working color space (the color space of the
destination surface) and a known, fixed color space. `toLinearSrgb` converts a color to the
sRGB color gamut, with a linear transfer function. `fromLinearSrgb` converts a color from that
same color space. These are helpful for effects that need to work in a specific color space, or
want to apply effects (like lighting) that work best in a linear color space.
Note that if the destination surface has no color space (color space is `nullptr`), these
intrinsics will do no conversion, and return the input color unchanged.
* Added a new variant of SkImageFilters::RuntimeShader that supports multiple child nodes.
* Add the ability to specify palette overrides in SkFontArguments. Implemented
for the FreeType-backed SkFontMgrs.
* * *
Milestone 98
* The following functions and methods are not defined in SkSurface when SK_SUPPORT_GPU is 0:
MakeFromBackendTexture, MakeFromBackendRenderTarget, MakeRenderTarget,
getBackendTexture, getBackendRenderTarget, replaceBackendTexture. flush() with parameters
was removed as well. These were all no-ops anyway when just the CPU backend was compiled in
(noting that flush() and flushAndSubmit() are still no-ops on the CPU backend).
* GrBackendSemaphore only includes methods that match the GPU backend that Skia was compiled for.
For example, initVulkan and vkSemaphore are not defined unless the Vulkan backend is compiled
into Skia.
* Surfaces and images are now limited to just under 2GB of total size. Previously, larger images
could be created, but the CPU backend would fail to index them correctly.
* SkCanvas::drawVertices and SkCanvas::drawPatch variants that did not take SkBlendMode are
* SkImageFilters::RuntimeShader is a new public API that enables adding RuntimeShaderEffects into
image filter graph.
* SkImage::makeRawShader is a new public API that creates "raw" image shaders. makeRawShader
functions like SkImage::makeShader, but for images that contain non-color data. This includes
images encoding things like normals, material properties (eg roughness), heightmaps, or any
other purely mathematical data that happens to be stored in an image. These types of images are
useful with some programmable shaders (ie SkRuntimeEffect).
Raw image shaders work like regular image shaders (including filtering and tiling), with a few
major differences:
- No color space transformation is ever applied (the color space of the image is ignored).
- Images with an alpha type of kUnpremul are not automatically premultiplied.
- Bicubic filtering is not supported. If SkSamplingOptions::useCubic is true, these factories
will return nullptr.
* Removed SkCanvas::markCTM and SkCanvas::findMarkedCTM. These were created to be used with other
features that have since been deleted, so they served no purpose.
* Added limited JPEGXL support.
* * *
Milestone 97
* Added basic support for vulkan DRM modifiers. All of these are treated as read only textures
internally (versus querying specific modifier support). Clients can either pass a flag to Vulkan
GrBackendFormat to say it uses modifiers or pass the VK_IMAGE_TILING_DRM_FORMAT_MODIFIER_EXT
to a GrBackendTexture via the GrVkImageInfo struct.
* The following functions and methods are not defined in SkImage when SK_SUPPORT_GPU is 0:
MakeTextureFromCompressed, MakeFromTexture, MakeFromCompressedTexture,
MakeCrossContextFromPixmap, MakeFromAdoptedTexture, MakeFromYUVATextures,
MakeFromYUVAPixmaps, MakePromiseTexture, MakePromiseYUVATexture, MakeBackendTextureFromSkImage,
flush, flushAndSubmit, getBackendTexture, makeTextureImage.
These were all no-ops anyway when just the CPU backend was compiled in.
* * *
Milestone 96
* SkRuntimeEffect no longer clamps the RGB values of an effect's output to the range 0..A.
This makes it easier to use a hierarchy of SkSL shaders where intermediate values do not
represent colors but are, for example, non-color inputs to a lighting model.
* * *
Milestone 95
* Minimum supported iOS raised from 8 to 11. Skia may build back to iOS 9 but versions older
than 11 are not tested. Community contributions to support versions 9 and 10 of iOS may be
considered, but they may not be complex as they cannot be tested.
* * *
Milestone 94
* Metal backend has been changed to track command buffer resources manually
rather than using retained resources.
* Added virtual onResetClip() to SkCanvas for Android Framework, to emulate the soon-to-be-removed
expanding clip ops guarded by SK_SUPPORT_DEPRECATED_CLIPOPS.
* Removed SK_SUPPORT_DEPRECATED_CLIPOPS build flag. Clips can only be intersect and difference.
* There is a new syntax for invoking (sampling) child effects in SkSL. Previously, children
(shaders, colorFilters, blenders) were invoked using different overloads of `sample`. That
syntax is deprecated (but still supported). Now, the child behaves like an object, with a method
name `eval`. The arguments to these `eval` methods are the same as the arguments in the old
`sample` intrinsics. For example:
// Old syntax:
sample(shader, xy)
sample(colorFilter, color)
sample(blender, srcColor, dstColor)
// New syntax:
blender.eval(srcColor, dstColor)
* * *
Milestone 93
* Removed SkPaint::getHash
* Removed SkShaders::Lerp. It was unused (and easy to replicate with SkRuntimeEffect).
* The default value of GrContextOptions::fReduceOpsTaskSplitting is now enabled.
* Removed SkMatrix44
* * *
Milestone 92
* Hides SkPathEffect::computeFastBounds() from public API; external subclasses of SkPathEffect
must implement onComputeFastBounds() but can return false to signal it's not computable.
* Add SkM44::RectToRect constructor (SkM44's equivalent to SkMatrix::RectToRect)
* Metal support has been removed for versions of iOS older than 10.0 and MacOS older than 10.14.
* Removed custom attributes from SkVertices and the corresponding `varying` feature from
* Dropped support for mixed samples. Mixed samples is no longer relevant for Ganesh. DMSAA and the
new Ganesh architecture both rely on full MSAA, and any platform where mixed samples is
supported will ultimately not use the old architecture.
* SkRuntimeEffect::Make has been removed. It is replaced by MakeForShader and MakeForColorFilter.
These functions do stricter error checking on the SkSL, to ensure it is valid for a particular
stage of the Skia pipeline.
* * *
Milestone 91
* The SkSL DSL API has been moved into public headers, although it is still under active
development and isn't quite ready for prime time yet.
* Skia's GPU backend no longer supports NVPR. Our more recent path renderers are more
performant and are not limited to nVidia hardware.
* SkRuntimeEffect now supports uniforms of type int, int2, int3, and int4. Per the OpenGL ES
Shading Language Version 1.00 specification, there are few guarantees about the representation
or range of integral types, and operations that assume integral representation (eg, bitwise),
are not supported.
* SkRuntimeEffect requires that 'shader' variables be declared as 'uniform'. The deprecated
syntax of 'in shader' is no longer supported.
* * *
Milestone 90
* Renamed use of sk_cf_obj in external Metal types to sk_cfp.
* GrDirectContext::ComputeImageSize() is removed. Use SkImage::textureSize() instead.
* Remove SkImageFilter::MakeMatrixFilter as it was unused and replaced with
* Refactored particle system to use a single code string containing both Effect and Particle code.
Uniform APIs are now shared for all program entry points, and no longer prefixed with 'Effect'
or 'Particle'. For example, instead of `SkParticleEffect::effectUniformInfo` and
`SkParticleEffect::particleUniformInfo`, there is just `SkParticleEffect::uniformInfo`.
* Remove SkImageFilter::CropRect from the public API as it's no longer usable. All factories
work with 'SkRect', 'SkIRect', or nullable pointers to 'Sk[I]Rect'.
* Remove deprecated SkImageFilter factory functions and supporting types. All default-provided
SkImageFilters are now only constructed via 'include/effects/SkImageFilters.h'
* Added SkRuntimeEffect::makeImage() to capture the output of an SkRuntimeEffect in an SkImage.
* Updated SkRuntimeEffect::Make() to take an Options struct. It also now returns a Results struct
instead of a tuple.
* Changed SkRuntimeEffect::Varying to have lower-case member names, with no 'f' prefix.
* Changed SkRuntimeEffect::Uniform to have lower-case member names, with no 'f' prefix.
* Deprecate (and ignore) SkAndroidCodec::ExifOrientation
* Fix several minor issues in lighting image filters:
- The spotlight falloff exponent is no longer clamped to [1, 128]. SVG 1.1 requires the specular
lighting effect's exponent (shininess) to be clamped; not the spotlight's falloff. Any such
parameter clamping is the client's responisibility, which makes Skia's lighting effect easily
adaptable to SVG 1.1 (clamp exponent) or SVG 2 (no clamp).
- Fix spotlight incorrectly scaling light within the cone angle.
- Move saturation of RGBA to after multiplying lighting intensity with the lighting color, which
improves rendering when diffuse and specular constants are greater than 1.
* SkDeferredDisplayListRecorder::makePromiseTexture has moved to SkImage::MakePromiseTexture.
New code should use the new entry point – migration CLs will be coming soon.
Milestone 89
* Removed SkYUVAIndex and SkYUVASizeInfo. These were no longer used in any
public APIs.
* Numerous changes to SkRuntimeEffect, aligning the capabilities and restrictions with
The OpenGL ES Shading Language 1.00 (aka, the shading language of OpenGL ES2 and WebGL 1.0).
All built-in functions from sections 8.1 through 8.6 implemented & tested on all backends.
Removed types and features that require newer versions of GLSL: [Non-square matrices] [uint, short, ushort, byte, ubyte] [while and do-while loops] [Bitwise operators and integer remainder]
* Add SkShadowUtils::GetLocalBounds. Generates bounding box for shadows
relative to path.
* Removed SkPerlinNoiseShader::MakeImprovedNoise.
* Removed deprecated version of MakeFromYUVATextures. Use the version
that takes GrYUVABackendTextures instead.
* SkAnimatedImage: Always respect exif orientation
Replace SkPixmapPriv::ShouldSwapWidthHeight with
* Add kDirectionalLight_ShadowFlag support. If enabled, light position represents
a vector pointing towards the light, and light radius is blur radius at elevation 1.
* Support GL_LUMINANCE8_ALPHA8 textures. These can be used with GrBackendTexture APIs
on GrDirectContext and as planes of YUVA images via GrYUVABackendTextures.
* Removed previously deprecated SkImage::MakeFromYUVATexturesCopyToExternal.
* Add versions of GrDirectContext::createBackendTexture and updateBackendTexture
that take a GrSurfaceOrigin. The previous versions are deprecated.
* Remove support for deprecated kDontClipToLayer_SaveLayerFlag in SkCanvas::SaveLayerRec
* Expose more info in SkCodec::FrameInfo
* Added dither control to the SkImageFilters::Shader factory.
* Add MTLBinaryArchive parameter to GrMtlBackendContext. This allows
Skia to cache PipelineStates in the given archive for faster
shader compiles on future runs. The client must handle loading and
saving of the archive.
* Deprecated enum SkYUVAInfo::PlanarConfig has been removed.
* Deprecated SkImage factories have been removed from
* The following YUV image factories have been removed:
Replacement pattern outlined below.
1) Make image using MakeFromYUVATextures
2) Make a SkSurface around result texture using SkSurface::MakeFromBackendTexture
3) surface->getCanvas()->drawImage(image, 0, 0);
4) surface->flushAndSubmit()
5) Optional: SkImage::MakeFromBackendTexture() to use as SkImage.
* Added a new interface for GrDirectContext creation in Metal, using
a new struct called GrMtlBackendContext. The previous interface taking
a MTLDevice and MTLCommandQueue is deprecated.
* SkCanvas::flush has been deprecated.
* * *
Milestone 88
* SkYUVAInfo now has separate enums for division of channels among planes and
the subsampling. The previous combined enum, PlanarConfig, is deprecated.
* Simplified SkDeferredDisplayListRecorder promise image API. Removed "release"
callback and renamed "done" callback to "release". The new "release" proc can
be null. Added a new SkYUVAInfo-based factory for YUVA promise texture images
and deprecated the old SkYUVAIndex-based one.
* Limit the types and intrinsics supported in SkRuntimeEffect to GLSL ES 1.00
* Add AVIF support to SkHeifCodec.
* Add support for creating SkSurfaceCharacterizations directly for use by a
* Removed SkSurfaceProps::kLegacyFontHost_InitType, SkFontLCDConfig, and related code.
The default pixel geometry for SkSurfaceProps is now kUnknown instead of kRGB_H.
The removal was guarded by the SK_LEGACY_SURFACE_PROPS build flag which was later removed.
* Legacy 8-bit YUV interface removed from SkImageGenerator. Use more flexible SkYUVAPixmaps-
based interface instead.
* New variant of SkImage::MakeFromYUVATextures. Takes a new type GrYUVATextures
which wraps an SkYUVAInfo and compatible set of GrBackendTextures. The provides
a more complete and structured specification of the planar configuration. Previous
version is deprecated.
Already deprecated MakeFromYUVATexturesCopyToExternal added to replace other deprecated
APIs. It's not recommended that clients use this and instead use the pattern described
in the API comment.
* Add field to GrContextOptions to disable mipmap support even if the backend
supports it.
* SkTPin() removed from public API.
* Add new SkImageFilters::Blend factory function, in place of the now deprecated
SkImageFilters::Xfermode factory function. Behavior is identical, but name better matches
conventions in SkShader and SkColorFilter.
* SkImageFilters::Foo() factory functions now accept SkIRect, SkRect, and optional SkIRect* or
SkRect*, instead of previously just the optional SkIRect*. Internally, the crop rects are stored
as floats to allow for fractional crops to be defined in the local coordinate system (before
transformation by the canvas matrix).
* Add new SkImageFilters::Shader factory and deprecate SkImageFilters::Paint factory. All
supported/valid Paint() filters can be represented more cleanly as a Shader image filter.
* GrContext has been replaced by two separate classes: GrDirectContext which is
the traditional notion of GrContext, and GrRecordingContext which is a context
that is recording an SkDeferredDisplayList and therefore has reduced functionality.
Unless you are using SkDeferredDisplayList, migrate directly to GrDirectContext in
all cases.
* CPU sync bool added to SkSurface::flushAndSubmit() and GrContext::flushAndSubmit()
* Removed legacy variant of SkImage::MakeFromYUVAPixmaps. Use the version that
takes SkYUVAPixmaps instead. It has a more structured description of the
planar configuration.
* Some SkImage YUV image factories have been removed. Replacement patterns
outlined below.
1) Make SkImage from YUVA planes using SkImage::MakeFromYUVATextures
2) Use Skia to allocate a surface using SkSurface::MakeRenderTarget
3) surface->getCanvas()->drawImage(image, 0, 0);
4) surface->makeImageSnapShot() produces RGBA image.
1) Make image using MakeFromYUVATextures
2) Make a SkSurface around result texture using SkSurface::MakeFromBackendTexture
3) surface->getCanvas()->drawImage(image, 0, 0);
4) surface->flushAndSubmit()
5) Optional: SkImage::MakeFromBackendTexture() to use as SkImage.
Same as SkImage::MakeFromYUVATexturesCopy
* GrBackendRenderTargets which are created with a stencilBits param, now require
the stencilBits to be 0, 8, or 16.
* * *
Milestone 87
* GrVkImageInfo now has a field for sample count. GrBackendRenderTarget constructor
that took both a GrVkImageInfo and separate sample count is deprecated. Use the
version without sample count instead. Similarly, GrD3DTextureResourceInfo now
has a sample count field and GrBackendRenderTarget no longer takes a separate
sample count for Direct3D. The sample count for GrBackendRenderTarget is now
directly queried from MtlTexture rather than passed separately. The version that
takes a separate sample count is deprecated and the parameter is ignored.
* Added deprecation warning for Metal support on MacOS 10.13, iOS 8.3, and older.
* GrVkImageInfo now has a field for sample count. GrBackendRenderTarget constructor
that took both a GrVkImageInfo and separate sample count is deprecated. Use the
version without sample count instead.
* Update SkClipOp::kMax_EnumValue to include only intersect and difference when
* Add support for external allocator for Direct3D 12 backend.
Defines base classes for an allocation associated with a backend texture and a
a memory allocator to create such allocations.
Adds memory allocator to backend context.
* Add new optional parameter to GrContext::setBackend[Texture/RenderTarget]State which can
be used to return the previous GrBackendSurfaceMutableState before the requested change.
* New optimized clip stack for GPU backends. Enabled by default but old behavior based on
SkClipStack can be restored by defining SK_DISABLE_NEW_GR_CLIP_STACK when building. It is not
compatible with SK_SUPPORT_DEPRECATED_CLIPOPS and we are targeting the removal of support for
the deprecated, expanding clip ops.
* GPU backends now properly honor the SkFilterQuality when calling drawAtlas.
* The signature of 'main' used with SkRuntimeEffect SkSL has changed. There is no longer an
'inout half4 color' parameter, effects must return their color instead.
Valid signatures are now 'half4 main()' or 'half4 main(float2 coord)'.
* New YUVA planar specifications for SkCodec, SkImageGenerator, SkImage::MakeFromYUVAPixmaps.
Chroma subsampling is specified in more structured way. SkCodec and SkImageGenerator
don't assume 3 planes with 8bit planar values. Old APIs are deprecated.
* Added VkImageUsageFlags to GrVkImageInfo struct.
* * *
Milestone 86
* Remove support for 'in' variables from SkRuntimeEffect. API now exclusively refers to inputs
as 'uniforms'.
* Add SkImageGeneratorNDK and SkEncodeImageWithNDK for using Android's NDK APIs to decode and
* SkImage:remove DecodeToRaster, DecodeToTexture
* Add GrContext api to update compressed backend textures.
* Rename GrMipMapped to GrMipmapped for consistency with new APIs.
Also rename GrBackendTexture::hasMipMaps() to GrBackendTexture::hasMipmaps()
* Add option for clients to own semaphores after wait calls.
* Remove obsolete GrFlushFlags.
* Adds default flush() calls to SkSurface, SkImage, and GrContext. These calls do
a basic flush without a submit. If you haven't updated Skia in a couple releases
and still have flush() calls in your code that you expect to do a flush and
submit, you should update all those to the previously added flushAndSubmit() calls
* Enable BackendSemaphores for the Direct3D backend.
* Added SkImage:asyncRescaleAndReadPixels and SkImage::asyncRescaleAndReadPixelsYUV420
* Ganesh is moving towards replacing GrContext with the GrDirectContext/GrRecordingContext
pair. GrDirectContexts have _direct_ access to the GPU and are very similar to the old
GrContext. GrRecordingContexts are less powerful contexts that lack GPU access but provided
context-like utilities during DDL recording. SkSurfaces and SkCanvas will now only return
GrRecordingContexts. Clients requiring context features that need GPU access can then
check (via GrRecordingContext::asDirectContext) if the available recording context is actually
a direct context.
* Replace #defined values in SkString with equivalent constexprs.
* * *
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.
* 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.
* Add GrContext function to set mutable state on a backend surface. Currently this
is only used for setting vulkan VkImage layout and queue family.
* 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.
* SkSurface::asyncRescaleAndReadPixels and SkSurfaceasyncRescaleAndReadPixelsYUV420
now require explicit GrContext submit to guarantee finite time before callback
is invoked.
* Add VkSharingMode field to GrVkImageInfo.
* 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.
* 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.
* 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
* Remove deprecated version of flush calls on GrContext and SkSurface.
* 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.
* * *
Milestone 84
* Add api on GrContext, updateBackendTexture that will upload new data to a
* Add GrContext getter to SkSurface.
* Deprecate GrContext and SkSurface flush() call and replace ith with flushAndSubmit().
This only effects the default flush call that takes no parameters.
* 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).
* 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.
* 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.
* 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.
* * *
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.
* MoltenVK support removed. Use Metal backend instead.
* * *
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
* 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.
* 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:
The latter method comes in variants that allow color-initialized and
compressed texture data initialized.
* Added SkMatrix::MakeTrans(SkIVector)
* * *
Milestone 80
* For Vulkan backend, we now require that the VkDevice, Queue, and Instance outlive
either the destruction or abandoning of the GrContext. Additionally, all
GrBackendTextures created via GrContext::createBackendTexture calls must be deleted
before destroying or abandoning the GrContext.
* Removed SkSize& SkSize::operator=(const SkISize&)
* SkISize width() and height() now constexpr
* Added SkMatrix::MakeTrans(SkVector) and SkRect::makeOffset(SkVector).
* Added SkImageInfo::MakeA8(SkISize) and added optional color space parameter to
* Added dimensions() and getFrameCount() to SkAnimatedImage
* Removed SkMatrix44 version of toXYZD50 from SkColorSpace. Switched to skcms types in
transferFn, invTrasnferFn, and gamutTransformTo functions.
* Removed rotation and YUV support from SkColorMatrix
* Added kBT2020_SkYUVColorSpace. This is BT.2020's YCbCr conversion (non-constant-luminance).
* Remove old async read pixels APIs
* Expose SkBlendModeCoeff and SkBlendMode_AsCoeff for Porter-Duff blend modes.
* * *
Milestone 79
* SkTextBlob::Iter to discover the glyph indices and typefaces in each run
* Added support for PQ and HLG transfer functions to SkColorSpace.
* Added new api on GrContext ComputeImageSize. This replaces the hold static helper
* New versions of SkSurface async-rescale-and read APIs that allow client to extend
the lifetime of the result data. Old versions are deprecated.
* Add SkColorInfo. It's dimensionless SkImageInfo.
* Added SkPixmap-based createBackendTexture method to GrContext. This allows clients to create
backend resources (initialized with texture data) that Skia/Ganesh doesn't know about/track.
* Add explicit src and dst colorspace parameters to SkColorFilter::filterColor4f()
* Remove Vulkan/Metal float32 RGBA texture support
* Add SkSurface::MakeFromCAMetalLayer
* Added kAlpha_F16_SkColorType, kRG_F16_SkColorType and kRGBA_16161616_SkColorType.
This is intended to help support HDR YUV uses case (e.g., P010 and P016). As such,
the addition is focused on allowing creation of SkPixmaps and SkImages and not
SkSurfaces (i.e., who wants to render to render to these?)
* Start to move nested SkPath types (e.g. Direction, Verb) up to root level in SkPathTypes.h
* Remove isRectContour and ksNestedFillRects from public
* Added kRG_88_SkColorType. This is intended to help support YUV uses case (e.g., NV12).
As such, the addition is focused on allowing creation of SkPixmaps and SkImages and not
SkSurfaces (i.e., who wants to render to RG?)
* Make the size of program/pipeline caches configurable via
* Added kAlpha_16_SkColorType and kRG_1616_SkColorType. This is intended to help support HDR YUV
uses case (e.g., P010 and P016). As such, the addition is focused on allowing creation of
SkPixmaps and SkImages and not SkSurfaces (i.e., who wants to render to render to these?)
* Add GrContext::precompileShader to allow up-front compilation of previously-cached shaders.
* * *
Milestone 78
* SkDrawLooper is no longer supported in SkPaint or SkCanvas.
* SkPath::Iter::next() now ignores its consumDegenerates bools. Those will so
go away entirely
* SkImage: new factories: DecodeToRaster, DecodeToTexture
* SkImageFilter API refactor started:
- Provide new factory API in include/effects/SkImageFilters
- Consolidated enum types to use SkTileMode and SkColorChannel
- Hide filter implementation classes
- Hide previously public functions on SkImageFilter that were intended for
internal use only
* SkColorFilters::HSLAMatrix - new matrix color filter operating in HSLA
* Modify GrBackendFormat getters to not return internal pointers. Use an enum
class for GL formats.
* Expose GrContext::dump() when SK_ENABLE_DUMP_GPU is defined.
* Vulkan backend now supports YCbCr sampler for I420 Vulkan images that are
not backed by external images.
* Add SkCodec::SelectionPolicy for distinguishing between decoding a still
image or an image sequence for a container format that has both (e.g. HEIF).
* SkImage::makeTextureImage and SkImage::MakeCrossContextFromPixmap no longer
take an SkColorSpace parameter. It was unused.
* SkImage::reinterpretColorSpace - to reinterpret image contents in a new
color space.
* Removed SkImage::MakeCrossContextFromEncoded.
* Add Metal support for GrFence, GrSemaphore, and GrBackendSemaphore
* SkMallocPixelRef: remove MakeDirect and MakeWithProc from API.
* Remove 4-parameter variant of SkRect::join() and intersect(), and
noemptycheck variants of intersect().
* Remove unused sk_sp comparison operators.
* Add SkColor4f variant to experimental_DrawEdgeAAQuad for SkiaRenderer.
* Deprecated maxCount resource cache limit for Ganesh.
This hasn't been relevant for a long time.
* Changed GrContextOptions' fDisallowGLSLBinaryCaching to fShaderCacheStrategy,
and allow caching SkSL.
* Use GL_QCOM_TILED_RENDERING to explicitly discard stencil
* Added RELEASE_NOTES.txt file
* Implemented internal support for OpenGL tessellation.