Can you save an edited RAW .dng file on iOS?

前端 未结 4 1172
伪装坚强ぢ
伪装坚强ぢ 2021-01-14 07:34

I want to build an iOS 10 app that lets you shoot a RAW (.dng) image, edit it, and then saved the edited .dng file to the camera roll. By combining

4条回答
  •  猫巷女王i
    2021-01-14 08:10

    The only way to get DNG data as of the writing of this response (iOS 10.1) is:

    AVCapturePhotoOutput.dngPhotoDataRepresentation(forRawSampleBuffer: CMSampleBuffer, previewPhotoSampleBuffer: CMSampleBuffer?) 
    

    Noting the OP refers to Core Image. As mentioned by rickster, CI works on processed image data, therefore only offers processed image results (JPEG, TIFF):

    CIContext.writeJPEGRepresentation(of:to:colorSpace:options:)
    CIContext.writeTIFFRepresentation(of:to:format:colorSpace:options:)
    

提交回复
热议问题