Prepare 1.5.0 build34 film and mixer delivery; verify 349 native and 184 reference cases

这个提交包含在:
mac 于 2026-11-02 13:54:05 +08:00 提交
1 父节点 f575c01893
当前提交 eeeee102cd
14 个文件已更改
+3600 -361

没有与搜索条件相匹配的文件

+1 -1
查看文件
@@ -37,7 +37,7 @@
}
if(DYFilmGrainActive(u.film)){
id<MTLTexture>noise=texture(2);if(!noise)return fail(error,@"无法分配颗粒缓冲区");
id<MTLComputeCommandEncoder>ce=[commands computeCommandEncoder];[ce setComputePipelineState:entry[@"dyFilmNoise"]];[ce setTexture:noise atIndex:0];[ce setBytes:&u.filmFrameKey length:4 atIndex:0];[ce dispatchThreads:MTLSizeMake(noise.width,noise.height,1) threadsPerThreadgroup:MTLSizeMake(16,16,1)];[ce endEncoding];
id<MTLComputeCommandEncoder>ce=[commands computeCommandEncoder];[ce setComputePipelineState:entry[@"dyFilmNoise"]];[ce setTexture:noise atIndex:0];[ce setBytes:&u.filmFrameKey length:4 atIndex:0];unsigned bottom=source.imageOrigin==kFxImageOrigin_BOTTOM_LEFT;[ce setBytes:&bottom length:4 atIndex:1];[ce dispatchThreads:MTLSizeMake(noise.width,noise.height,1) threadsPerThreadgroup:MTLSizeMake(16,16,1)];[ce endEncoding];
if(u.film.grainSize>1){id<MTLTexture>smooth=texture(3);if(!smooth)return fail(error,@"无法分配颗粒扩散缓冲区");
// Reference radius=2. Recover the same sigma search without frame state.
double sigma=1,step=1;for(int iteration=0;iteration<20000;iteration++){double density=exp(-4/(sigma*sigma))/(sigma*sigma*6.283185307179586);if(.02/5<density){if(step<=.02)break;sigma-=step;step*=.1;}sigma+=step;if(sigma>1000){sigma=1;break;}}