[Gdal-dev] GDAL Thread Safety

Jason Beverage jbeverage at prologic-inc.com
Fri Dec 1 13:04:05 EST 2006


Hi Howard,

Actually, I saw that question, but I guess I didn't get any warm fuzzies
from the answer:)  Let me explain my specific situation a little better
and maybe it will make more sense.

I am loading geospatial data into my application, displaying it and
doing some analysis on it.  There are really only 2 threads in the
application: the main application thread and a background thread that
does the visualization.  Both the main thread and the background thread
are accessing the same files on disk and using GDAL to read them at the
same time.  However, both threads are using different GDALDataset
objects.  I'm not using GDALOpenShared, just GDALOpen.

Is there anything in particular that I should be looking out for in this
situation?  I'm using different GDALDataset objects, but they are
pointing to the same file on disk, which I wasn't sure if it was a
problem.

Thanks,

Jason

-----Original Message-----
From: Howard Butler [mailto:hobu at iastate.edu] 
Sent: Friday, December 01, 2006 12:34 P
To: Jason Beverage; gdal-dev at lists.maptools.org
Subject: Re: [Gdal-dev] GDAL Thread Safety

Jason,

Did you happen to see the question in the FAQ 
<http://gdal.org/faq.html>?  It covers the current situation fairly
well.

Howard

At 11:24 AM 12/1/2006, Jason Beverage wrote:
>Hi all,
>
>Does anyone have some insight on what the thread safety status is of
>GDAL/OGR?  I know in the 1.3.2 release notes it mentioned that some
>operations are thread safe, but apparently not all of them.  Any best
>practices or situations to avoid?
>
>Thanks,
>
>Jason
>
>_______________________________________________
>Gdal-dev mailing list
>Gdal-dev at lists.maptools.org
>http://lists.maptools.org/mailman/listinfo/gdal-dev





More information about the Gdal-dev mailing list