Giter Site home page Giter Site logo

Comments (6)

RReverser avatar RReverser commented on June 15, 2024

For example, right now there are no bindings for gp_filesystem_get_file in CameraFS, but there are CameraFilePath::{download, get_in_memory}.

Since the former is strictly more general (supports any files, not just those captured via capture_image), replacing the latter with CameraFS bindings would cover both use-cases.

from gphoto2-rs.

maxicarlos08 avatar maxicarlos08 commented on June 15, 2024

Yes but from where do I get a CameraFilesystem? and is it meant to be used in for this? the docs say it should be only used by camera drivers

from gphoto2-rs.

RReverser avatar RReverser commented on June 15, 2024

Yes but from where do I get a CameraFilesystem?

What do you mean? You already have bindings for it in filesys.rs 🤔

the docs say it should be only used by camera drivers

Oh, I haven't seen those. Are you saying CameraFS bindings shouldn't exist at all?

from gphoto2-rs.

maxicarlos08 avatar maxicarlos08 commented on June 15, 2024

What do you mean? You already have bindings for it in filesys.rs thinking

Actually no, CameraFS just has a reference and calls the gp_camera_file_* and gp_camera_folder_* functions. (I agree that this naming is confusing)

Oh, I haven't seen those. Are you saying CameraFS bindings shouldn't exist at all?

Our CameraFS is ok since it used the filesystem functions on the camera, just the CameraFilesystem should not be used

from gphoto2-rs.

RReverser avatar RReverser commented on June 15, 2024

Actually no, CameraFS just has a reference and calls the gp_camera_file_* and gp_camera_folder_* functions. (I agree that this naming is confusing)

Ah sorry I got confused, I thought it's using gp_filesystem_* functions for some reason.

Our CameraFS is ok since it used the filesystem functions on the camera, just the CameraFilesystem should not be used

I guess you meant to link to https://github.com/gphoto/libgphoto2/blob/8b462f8c835b9d3ab0cee4117e0b0458dac00445/gphoto2/gphoto2-filesys.h#L227-L233 instead, since that comment is about Camera fields.


Anyway, okay, yeah, I got confused about specific APIs :) In that case my suggestion about unifying entry points for filesystem access still stands, but it's just about moving download & get_in_memory into CameraFS instead of CameraFilePath.

from gphoto2-rs.

RReverser avatar RReverser commented on June 15, 2024

Reopening as per #35 (comment).

from gphoto2-rs.

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.