Re: Open Source libraries for image loading
- From: Edward Rosten <Edward.Rosten@xxxxxxxxx>
- Date: Mon, 17 Mar 2008 08:39:13 -0700 (PDT)
On Jan 27, 2:16 pm, Domas <tasdo...@xxxxxxxxx> wrote:
Hi,
what open source libraries (preferably C) would you recommend for
loading images, so that they could be further processed?
If you're happy to use C++ (you can still do your processing in
essentially C) for loading you can try libCVD at
http://mi.eng.cam.ac.uk/~er258/cvd/index.html
This complete code snippet loads an image from the standard input for
further processing:
#include <cvd/image_io.h>
using namespace CVD;
using namespace std;
int main()
{
Image<Rgb<byte> > image = img_load(cin);
cout << "Pixel at x=10, y=7 == " << image[7][10] << endl;
}
In the interests of full disclosure, it's my library, it's suitable
for images which fit completely in to memory and it doesn't support a
huge range of formats. On the other hand it does support loading from
streams, and has good 16 bit support. It is also extensible in that
it is not hard to add either new formats or new pixel types (eg
float).
-Ed
--
(You can't go wrong with psycho-rats.)(http://mi.eng.cam.ac.uk/~er258)
/d{def}def/f{/Times s selectfont}d/s{11}d/r{roll}d f 2/m{moveto}d -1
r 230 350 m 0 1 179{ 1 index show 88 rotate 4 mul 0 rmoveto}for/s 12
d f pop 235 420 translate 0 0 moveto 1 2 scale show showpage
.
- Follow-Ups:
- Re: Open Source libraries for image loading
- From: bugbear
- Re: Open Source libraries for image loading
- Prev by Date: ASTER influence of pointing angle on reflectance
- Next by Date: Re: Open Source libraries for image loading
- Previous by thread: Re: Open Source libraries for image loading
- Next by thread: Re: Open Source libraries for image loading
- Index(es):
Relevant Pages
|
|