[Gdal-dev] IdrisiDataset::SetGeoTransform
Ivan Lucena
ILucena at clarku.edu
Mon Apr 2 10:58:53 EDT 2007
Mateusz, Ari,
I lost track of my original code (previous to the introduction of
GDALPamDataset). But it looks like however did that change on
IdrisiDataset::GetGeoTransform() only concern was the PAM Dataset but it
also needs to update the .rdc file and adfGeotransform:
CPLErr IdrisiDataset::GetGeoTransform( double * padfTransform )
{
if( GDALPamDataset::GetGeoTransform( padfTransform ) != CE_None )
memcpy( padfTransform, adfGeoTransform, sizeof( double ) * 6 );
return CE_None;
}
I believe that because the RST driver is used mostly for "translate"
operations that problem never bother anyone (besides the test script).
Thanks for your help and suggestions.
I will take care of that.
Ivan
-----Original Message-----
From: gdal-dev-bounces at lists.maptools.org
[mailto:gdal-dev-bounces at lists.maptools.org] On Behalf Of Mateusz Loskot
Sent: Sunday, April 01, 2007 11:52 AM
To: gdal
Subject: Re: [Gdal-dev] IdrisiDataset::SetGeoTransform
Ari Jolma wrote:
> Mateusz Loskot wrote:
>>
>> Even if the prototype of IdrisiDataset::SetGeoTransform() does not
>> explicitly inform about constness of input parameter,
>> I think it's safe to assume the following:
>>
>> IdrisiDataset::SetGeoTransform( double const* padfGeoTransform );
^^^^^^^^^^^^^^
IdrisiDataset::SetGeoTransform( const double *padfGeoTransform );
^^^^^^^^^^^^^^
>>
>
> I'm not being very clear I believe. In my eyes the fact that
> SetGeoTransform does not change the adfGeoTransform property (note
*adf*
> not *padf*) of the object looks like a bug. It only changes some
> NameValues (?). When you ask the transformation parameters from the
> object using GetGeoTransform, it does not query these NameValues but
the
> adfGeoTransform, which has not been changed. adfGeoTransform is
> initialized if a new dataset is created and it is filled (from the
> NameValues) in Open method, but not if SetGeoTransform is called.
I think Frank has explained it in previous post (bug).
Also, I have to admit I wasn't sure if it is a bug or not, but sounds
suspicious.
>>> Then, I see the buildbot is running a csharp-test. Maybe it would be
>>> a good idea to run the Perl-bindings test? Regards,
>>
>> Ari, please send me instructions how to configure/run Perl bindings
test
>> and I will add it to the buildbot, no problem.
>
> in swig/perl and in Linux (can be done in Windows but it is really not
> so nice since it is difficult to delete the temporary files the test
> creates and it is much slower also):
>
> make generate
> make build
> make test
>
> The last step returns a report saying that 3 out of 1301 tests failed
> (the Idrisi set/getGeoTransform tests) and all ogr tests were ok. The
> report is standard Perl format.
Ari, thank you I will try to add it today.
Cheers
--
Mateusz Loskot
http://mateusz.loskot.net
_______________________________________________
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