Giter Site home page Giter Site logo

Comments (6)

danielebogo avatar danielebogo commented on June 17, 2024

Good question. I'll check the metadata of the taken image from the library.

from dbcamera.

 avatar commented on June 17, 2024

Awesome! Really enjoy your cool camera library, extremely nice. Thanks!

from dbcamera.

danielebogo avatar danielebogo commented on June 17, 2024

Thank you for your suggestions!

from dbcamera.

 avatar commented on June 17, 2024

@danielebogo - Just wanted to check in and see if there was any progress on this request? I am nearing completion of an app using this library, but want to allow the user to save the NEW images to their camera roll when they take a new picture. Have you found a way to determine if a new image is taken, or an existing image was selected?

Thanks!

from dbcamera.

danielebogo avatar danielebogo commented on June 17, 2024

Hi @jhickman7 ,
unfortunately i haven't find a solution for this issue. It seems it's impossibile to check if the image is already saved directly form the Library. I've found these two posts: URL1 & URL2.
Maybe one solution could be to compare the asset URL. But i'm not sure.

from dbcamera.

dougdiego avatar dougdiego commented on June 17, 2024

Maybe I don't understand your question, but can't you do the following?

// Save to Camera Roll if from Camera
NSString *source = [metadata objectForKey:@"DBCameraSource"];
NSLog@("source: %@", source);
if( [source hasSuffix:@"Camera"] ){
UIImageWriteToSavedPhotosAlbum(image, nil, nil, nil);
}

If the DBCameraSource is the Camera, then you know the picture was taken with DBCamera and therefore you should save it.

If it is not Camera, then it came from the Camera Roll and do not save it.

from dbcamera.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.