Skip to content

Commit

Permalink
Fix filtered screenshots being saved as 32-bit per channel
Browse files Browse the repository at this point in the history
  • Loading branch information
LIJI32 committed Apr 29, 2024
1 parent 19cf8d2 commit 7758713
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions Cocoa/Document.m
Original file line number Diff line number Diff line change
Expand Up @@ -2453,12 +2453,6 @@ - (NSImage *)takeScreenshot
NSImage *ret = nil;
if ([[NSUserDefaults standardUserDefaults] boolForKey:@"GBFilterScreenshots"]) {
ret = [_view renderToImage];
[ret lockFocus];
NSBitmapImageRep *bitmapRep = [[NSBitmapImageRep alloc] initWithFocusedViewRect:NSMakeRect(0, 0,
ret.size.width, ret.size.height)];
[ret unlockFocus];
ret = [[NSImage alloc] initWithSize:ret.size];
[ret addRepresentation:bitmapRep];
}
if (!ret) {
ret = [Document imageFromData:[NSData dataWithBytesNoCopy:_view.currentBuffer
Expand Down

0 comments on commit 7758713

Please sign in to comment.