cifilter

CIFilter Combination

混江龙づ霸主 提交于 2021-02-08 06:23:10
问题 I'm trying to achieve the same effect that appears when you enter the menu in the Read Dead Redemption (RDR) game: After browsing the CIFilter library I found that the filter I'm looking for is CIColorMonochrome . After applying the filter on a sample image I get the following result: This looks great, however not quite the same effect as in the RDR picture. I'm going to have a number over the image and it needs to be clearly visible. Therefore, I was wondering if the is a filter that will

CIFilter Combination

吃可爱长大的小学妹 提交于 2021-02-08 06:22:12
问题 I'm trying to achieve the same effect that appears when you enter the menu in the Read Dead Redemption (RDR) game: After browsing the CIFilter library I found that the filter I'm looking for is CIColorMonochrome . After applying the filter on a sample image I get the following result: This looks great, however not quite the same effect as in the RDR picture. I'm going to have a number over the image and it needs to be clearly visible. Therefore, I was wondering if the is a filter that will

iOS 10 breaks custom CIFilter

和自甴很熟 提交于 2021-02-07 08:29:16
问题 I have written a chromakey filter for making the backgrounds of MPEG movies transparent so that you can use a movie file for longer animations without the need for lengthy sequences of PNGs (as is commonly done for some types of iOS animations). I am using AVPlayer , AVVideoComposition , and a custom CIFilter to render the video over a background image. The background image can be changed dynamically by the user interacting with the app. This used to work just fine until iOS 10 came out and

iOS 10 breaks custom CIFilter

↘锁芯ラ 提交于 2021-02-07 08:28:36
问题 I have written a chromakey filter for making the backgrounds of MPEG movies transparent so that you can use a movie file for longer animations without the need for lengthy sequences of PNGs (as is commonly done for some types of iOS animations). I am using AVPlayer , AVVideoComposition , and a custom CIFilter to render the video over a background image. The background image can be changed dynamically by the user interacting with the app. This used to work just fine until iOS 10 came out and

iOS 10 breaks custom CIFilter

拟墨画扇 提交于 2021-02-07 08:28:34
问题 I have written a chromakey filter for making the backgrounds of MPEG movies transparent so that you can use a movie file for longer animations without the need for lengthy sequences of PNGs (as is commonly done for some types of iOS animations). I am using AVPlayer , AVVideoComposition , and a custom CIFilter to render the video over a background image. The background image can be changed dynamically by the user interacting with the app. This used to work just fine until iOS 10 came out and

Expected behavior when using CIAdditionCompositing to add pure black?

爷,独闯天下 提交于 2021-01-27 06:22:48
问题 I am attempting to understand how CIAdditionCompositing works. As part of my testing, I have created a square mid-gray image: and a square black image: When I combined these two square images using a CIAdditionCompositing patch, I expected to see a gray square whose color matched the original mid-gray square exactly (because all color components of the black image have value 0). However, the final result is actually brighter than the original gray image: I don't understand how this result is

CIFilter with CIQRCodeGenerator cause crash

强颜欢笑 提交于 2020-08-10 19:52:07
问题 I'm trying to generate QR code with following code : DispatchQueue.main.async { let image = generateQRCode(from: qrCodeString) } func generateQRCode(from string: String?) -> UIImage? { if let data = string?.data(using: .utf8, allowLossyConversion: false) { if let filter = CIFilter(name: "CIQRCodeGenerator") { filter.setValue(data, forKey: "inputMessage") let transform = CGAffineTransform(scaleX: 5, y: 5) if let output = filter.outputImage?.transformed(by: transform) { return UIImage(ciImage:

CoreImage coordinate system

若如初见. 提交于 2020-08-04 10:54:09
问题 I have CVPixelBufferRef from an AVAsset . I'm trying to apply a CIFilter to it. I use these lines: CVPixelBufferRef pixelBuffer = ... CVPixelBufferRef newPixelBuffer = // empty pixel buffer to fill CIContex *context = // CIContext created from EAGLContext CGAffineTransform preferredTransform = // AVAsset track preferred transform CIImage *phase1 = [CIImage imageWithCVPixelBuffer:pixelBuffer]; CIImage *phase2 = [phase1 imageByApplyingTransform:preferredTransform]; CIImage *phase3 = [self