This is a problem which regards all the gdal versions and is about the Python
GDAL bindings.
It seems to be impossible to setup PixelFunctionType and SourceTransferType
in VRTDerivedRasterBand from Python Gdal.
This is an example using IPython:
In [20]: vrtdriver = gdal.GetDriverByName('VRT')
In [21]: vrtdset = vrtdriver.Create('vrtdset.vrt', 1000, 1000, 0)
In [22]: vrtdset.AddBand(gdal.GetDataTypeByName('Float32'),
options=['subClass=VRTDerivedRasterBand', 'PixelFunctionType=phase',
'SourceTransferType=CFloat64'])
Out[22]: 0
In[23]: vrtdset.FlushCache()
Once these commands are run, the output file vrtdataset.vrt does not contain
the element PixelFunctionType in its VRTDerivedRasterBand :
VRTDataset rasterXSize=1000 rasterYSize=1000
VRTRasterBand dataType=Float32 band=1
subClass=VRTDerivedRasterBand/
/VRTDataset
On the contrary we would expect this result:
VRTDataset rasterXSize=1000 rasterYSize=1000
VRTRasterBand dataType=Float32 band=1
subClass=VRTDerivedRasterBand
PixelFunctionTypephase/PixelFunctionType
SourceTransferTypeCFloat64/SourceTransferType
/VRTRasterBand
/VRTDataset
Of course we have omitted the part concerning the Source Dataset.
--
View this message in context:
http://osgeo-org.1803224.n2.nabble.com/Problems-in-setting-PixelFunctionType-and-SourceTransferType-in-VRTDerivedRasterBand-tp5190363p5190363.html
Sent from the GDAL - Dev mailing list archive at Nabble.com.
___
gdal-dev mailing list
gdal-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/gdal-dev