[gdal-dev] MrSID mask band support

Brian Claywell bcclaywell at gmail.com
Thu Feb 17 16:23:43 EST 2011


On Tue, Feb 15, 2011 at 1:19 PM, Even Rouault
<even.rouault at mines-paris.org> wrote:
>> Barring that, since the MrSID driver reimplements the
>> overview-related virtual functions to bypass the default overview
>> manager, would there be any harm in initializing the overview manager
>> when a MrSIDDataset object is created?
>
> Yes I think this should be harmless. But I'm not too sure of what will happen
> if you try to get the overviews of the mask, or the mask of the overviews ...

The basics of the patch were easy enough (23 lines): I initialize the
overview manager near the end of MrSIDDataset::Open(), and implemented
MrSIDDataset::IBuildOverviews() to simply print a warning, as Frank
suggested.

As to your last comment about masks of the overviews and overviews of
the masks, Even, the behavior as it stands after this patch is that 1)
the masks of the overviews are coming back as GMF_ALL_VALID, and 2)
overviews of the masks are non-existent. I believe this is consistent
with the current behavior of, e.g., adding a per-dataset mask to a
GeoTIFF file that already has overviews. If that's sufficient, I'll
create a ticket and submit the patch as-is -- otherwise, I'm open to
suggestions.

-b

-- 
Brian Claywell
bcclaywell at gmail.com


More information about the gdal-dev mailing list