Fix colorspace in Viewer for Metal
Change-Id: Id8394acf854f1c069c5fde449ede225b2d81968b Reviewed-on: https://skia-review.googlesource.com/c/skia/+/288056 Auto-Submit: Jim Van Verth <jvanverth@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
This commit is contained in:
parent
613c92796e
commit
517af96936
@ -65,6 +65,8 @@ bool MetalWindowContext_mac::onInitializeContext() {
|
||||
fMetalLayer.autoresizingMask = kCALayerHeightSizable | kCALayerWidthSizable;
|
||||
fMetalLayer.contentsGravity = kCAGravityTopLeft;
|
||||
fMetalLayer.magnificationFilter = kCAFilterNearest;
|
||||
NSColorSpace* cs = fMainView.window.colorSpace;
|
||||
fMetalLayer.colorspace = cs.CGColorSpace;
|
||||
|
||||
fMainView.layer = fMetalLayer;
|
||||
fMainView.wantsLayer = YES;
|
||||
|
Loading…
Reference in New Issue
Block a user