-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Image I/O #49
Comments
Pinging guys working on DCV @DmitryOlshansky @9il @henrygouk |
It looks like ffmpeg supports all of those image formats [1], which could cut down on the amount of work required. It's also already a dependency for the video IO, so no new dependencies would need to be added. |
Aw, snap - I'm sorry, forgot to add that one! Added to original post. This actually sounds like a great plan! Relatively easy to implement, and truly powerful - whole lot of formats are supported there. Have you had any experience with this pipeline? Are there any potential drawbacks? I'd suppose there are none or very few... |
I've never worked with the ffmpeg libraries before, so I'm not sure how easy it would be to use them. It looks like the ff_load_image function will come in handy, though saving images may be a bit more involved. |
We'll figure it out - ffmpeg tool has options to load image sequence and save them as video file, and vice versa, so there's a way to do this for sure. |
As discussed in #48, maybe we should start planning on how to enrich the image I/O package of the library. Imageformats library is good (especially because it is purely written in D), but format coverage is poor (especially for encoders).
Use C libraries
So first idea is to build minimal bindings (or use existing ones) to popular C libraries:
Pros:
Cons:
Translate libraries to D
Some people already translated some of the popular encoder/decoders to D. I feel that's not that easy to do, and I'd personally much more like to focus on the DCV's core, but if we decide to take this step, no problem.
Using FFmpeg
@henrygouk suggested we could use ffmpeg to encode/decode image formats. This also seems like a great choice since lot of formats are supported, and ffmpeg-d is already a dependency.
Custom image I/O library's synergy with dcv:core
There was also discussion that users should be free to use 3rd party libraries for image I/O with DCV. I believe this is already achievable in DCV - e.g. if user is working with gtkd, and dcv:core, he/she can load pixbuf from file, then slice it's data and work along with dcv algorithms. So, I believe we're OK here, except maybe we should make an example on this topic to show it to people.
Separation of Image I/O from Video
Also we discussed if image io should be separated from video - in #48 we defined
dcv:io
sub-package, where we could have defineddcv:ioimage
, anddcv:iovideo
. If we decide to go with first option (bind C libs), I really think we should do this since it would be heavy loaded with C libs.Any comment is welcome.
The text was updated successfully, but these errors were encountered: