mz2 / carpaccio Goto Github PK
View Code? Open in Web Editor NEWA fast Swift library for decoding images (including the usual formats + RAW files) + EXIF metadata.
License: MIT License
A fast Swift library for decoding images (including the usual formats + RAW files) + EXIF metadata.
License: MIT License
Hello, and I'd like to echo others in saying thank you for this project. It has been really helpful.
I found when using it in Xcode 13 Beta (on macOS 12.0 beta) I needed to make this change to Sources/Carpaccio/CIImage+Extensions.swift
:
+ // This is deprecated in XCode 13 Beta and causes the code not to build. What should be used instead?
+ // https://developer.apple.com/documentation/coreimage/cirawfilteroption/3334940-ciinputenableedrmodekey
// Preserve pixel values beyond 0.0 … 1.0, which wide colour images will have
- rawFilter.setValue(true, forKey: kCIInputEnableEDRModeKey)
+ // rawFilter.setValue(true, forKey: kCIInputEnableEDRModeKey)
Without it I get this error and the project won't build:
Cannot convert value of type 'CIRAWFilterOption' to expected argument type 'String'
I'm not sure what the correct thing to do is rather than just commenting that line out but with this change the code builds and seems to work OK to my eyes but I thought I'd ask if you knew a better solution?
Thanks!
I've tried using your library with Fuji .RAF files and it failed to load the image metadata.
Adding "raf" to the list of RAWImageFileExtensions seems to fix the problem.
Any chance you can add this?
ImageMetadata doesn't contain valuable information when you call
loadFullSizeImage(options: FullSizedImageLoadingOptions, handler: @escaping PresentableImageHandler, errorHandler: @escaping ImageLoadingErrorHandler)
because the handler is run with empty ImageMetadata: handler(nonNilNakedImage, ImageMetadata(nativeSize: nonNilNakedImage.size))
I think this should be changed to handler(nonNilNakedImage, metadata)
Separate exifdump
into its own Package.swift to allow running tests on iOS via xcodebuild -scheme … test
for the SPM package (in short this is because there's no per-target platform choice in SPM).
See https://github.com/mz2/Carpaccio/pull/18/files#diff-3d7541c3a88f4d8bdbea8d2243071fa83c337cf991bb3c3e48b8f240861b19d7R37 for more info
Hi! Thank you for the great work!
Did you notice by any chance that Sony ARW photos are not getting processed on iOS? (The same exact snippet working on macOS M1).
I'm joining an example image.
And the example code.
let loader = ImageLoader(imageURL: fileItem.url, thumbnailScheme: ImageLoader.ThumbnailScheme.decodeFullImage)
let (ciImage, metadata) = try loader.loadCIImage(options: ImageLoadingOptions(allowDraftMode: true), cancelled: nil)
// On iOS, the line above throws the exception "Failed to decode image at [...]" while it completes correctly on macOS.
Thank you!
Couldn't select "Carpaccio.xcodeproj" in "Embedded Binaries" so i added "Carpaccio.frameworkiOS".
When i added code given in the document to process RAW file it throws error ---> Use of unresolved identifier 'RAWImageLoader'.
Help me to solve this problem.
Thanks!!
First off, thanks for making this project! It's been really helpful for loading and grabbing thumbnails of photos, especially RAW photos!
I'm wondering if there are plans to add more metadata fields in the future? Ones that come to mind are lens info, exif data like Title, Description, etc. If this should be in user-land, maybe just exposing the metadata dict in either the ImageLoader
or ImageMetadata
structs?
I'm happy to take a first pass at a PR, but wanted to check if there was a reason they were left out from the project.
@markuspiipari I noticed after your recent changes, Travis is complaining regarding one of the EXIF metadata / image size related tests:
[CarpaccioTests_iOS.CarpaccioTests testSonyRAWConversion] : XCTAssertEqual failed: ("1078.0") is not equal to ("1080.0") -
Hi,
I was trying to update your Podspec, unfortunately it's still not working (see my branch), but I think together we can figure out this problem.
Currently, I have the following problems:
- ERROR | file patterns: The `preserve_paths` pattern did not match any file.
- ERROR | file patterns: The `vendored_libraries` pattern did not match any file.
- ERROR | xcodebuild: Returned an unsuccessful exit code.
- ERROR | xcodebuild: Carpaccio/Carpaccio/RAWConverter.h:27:46: error: unknown type name 'NSImage'
- NOTE | xcodebuild: Carpaccio/Carpaccio/RAWConverter.mm:11:9: fatal error: 'Cocoa/Cocoa.h' file not found
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.