openjump-gis / openjump

OpenJUMP, the Open Source GIS with more than one trick in its kangaroo pocket, takes the leap from svn to git. join the effort!
http://openjump.org
GNU General Public License v2.0
29 stars 14 forks source link

Image driver selection #107

Closed mukoki closed 4 months ago

mukoki commented 5 months ago

Image reading is supposed to choose the first driver which can successfully read the image, but actually, it fails even when some drivers can do the job. Example Only a few drivers can read BigTiff

With jp2 and the new driver, it is a bit different : older drivers display a blurred image, but does not throw exception, the new driver has no chance to be called.

edeso commented 5 months ago

Image reading is supposed to choose the first driver which can successfully read the image, but actually, it fails even when some drivers can do the job.

not sure that is what is implemented. afai recall we offer drivers claiming to be able to decode in an order sorted by a preference value we set, so we can make some to be the preferred.

are you sure the implementaion is supposed to bruteforce try in the preference order?

mukoki commented 5 months ago

Yes there is a preference order defined somewhere but i don't remember if next driver is searched when the current one is not found, or when it fails or what...

edeso commented 5 months ago

quick search. i'd say it was this priority setting

https://github.com/openjump-gis/openjump/blob/HEAD/src/com/vividsolutions/jump/workbench/imagery/ReferencedImageFactoryFileLayerLoader.java#L248

mukoki commented 4 months ago

OK, was changed on april, 10