我有这个 LUT png 并且在我的图像上应用这个 LUT 时没有给出正确的结果。是我的 LUT 格式不同还是我没有正确应用过滤器。
UIImage *lutimage = [UIImage imageNamed:@"lut.png"];
GPUImagePicture *lookupImageSource = [[GPUImagePicture alloc] initWithImage:lutimage];
GPUImagePicture *stillImageSource = [[GPUImagePicture alloc] initWithImage:imported_image];
GPUImageLookupFilter *lookupFilter = [[GPUImageLookupFilter alloc] init];
lookupFilter.intensity = 1.0;
[lookupFilter setInputRotation:kGPUImageRotateRight atIndex:1];
[stillImageSource addTarget:lookupFilter];
[lookupImageSource addTarget:lookupFilter];
[lookupFilter useNextFrameForImageCapture];
[stillImageSource processImage];
[lookupImageSource processImage];
imgview_main.image = [lookupFilter imageFromCurrentFramebuffer];
[[GPUImageContext sharedFramebufferCache] purgeAllUnassignedFramebuffers];