perf: defer unused GPU work and streamline preview rendering
这个提交包含在:
1 父节点
c9e4d3f330
当前提交
ccc34734e3
18 个文件已更改
+362
-115
没有与搜索条件相匹配的文件
@@ -52,7 +52,7 @@
|
||||
id<MTLBuffer>buffer=[self maskBuffer:face?@{}:@{@"primary":masks} tile:src device:device header:&header];_faceEntries=skinEntries;
|
||||
MTLTextureDescriptor *desc=[MTLTextureDescriptor texture2DDescriptorWithPixelFormat:MTLPixelFormatRGBA32Float width:input.width height:input.height mipmapped:NO];desc.storageMode=MTLStorageModePrivate;desc.usage=MTLTextureUsageShaderRead|MTLTextureUsageShaderWrite;
|
||||
id<MTLTexture>output=[[device newTextureWithDescriptor:desc]autorelease];
|
||||
id<MTLComputePipelineState>pipeline=[self managedKernel:@"dyLocalMosaic" entry:entry error:error];
|
||||
id<MTLComputePipelineState>pipeline=[self computePipeline:@"dyLocalMosaic" entry:entry error:error];
|
||||
if(!input||!buffer||!output||!pipeline){fail(error,@"局部马赛克缓冲区不可用。");return nil;}
|
||||
// Size is in 1080-line reference pixels, stable under proxy/viewer scaling.
|
||||
uint32_t block=(uint32_t)MAX(2,round([settings[@"size"]doubleValue]*input.height/1080.));
|
||||
|
||||
在新工单中引用
屏蔽一个用户