Re: [GRASS-user] Exporting a raster tiff with RGB 3 bands produce a paletted tiff

2015-07-07 Thread Moritz Lennert
On Fri, 3 Jul 2015 14:06:58 +0200, Andrea Peri 
wrote:
> No, it was not what I expected .
> I expected to see the same image I see in the grass display (using
d.rgb)
> Instead I see someone completelly different.

That is expected, and also depends on the program you use to visualise the
data.

Color is arbitrary for raster data. Not all formats actually allow
transport of color info, and not all programs can read the color info
provided in a given format.

The question for you is: do you just want to export a georeferenced image
with a specific color choice, or do you export the actual data which is
independent of the colors (In any decent program you can define which color
to assign to which value) ?

If you want to export the data and the colors you created in GRASS GIS,
your best bet would probably to export to any format using r.out.gdal and
to export colors with r.colors.out.

Or you can create an image with the colors you want using r.composite and
then export just that. You would still need a program that can read the
color table in the output format, or use r.colors.out.

Moritz

___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Exporting a raster tiff with RGB 3 bands produce a paletted tiff

2015-07-03 Thread Andrea Peri
No, it was not what I expected .
I expected to see the same image I see in the grass display (using d.rgb)
Instead I see someone completelly different.

thx.

A.


2015-07-03 13:19 GMT+02:00 Moritz Lennert :
> On 02/07/15 16:23, Andrea Peri wrote:
>>
>> Hi Markus,
>> thx for hint.
>>
>> I tried but probably I miss something.
>> because have an error:
>>
>>> ERROR 6: SetColorTable() not supported for multi-sample TIFF
>>> files.
>>> 
>>> ERROR 6: SetColorTable() can only be called on band 1.
>>> ERROR 6: SetColorTable() can only be called on band 1.
>>
>>
>>
>> I defined a group named "gruppo" and insert in it the three raster I
>> like to have for the three bands.
>>
>> After I execute this command:
>>
>> r.out.gdal -f --overwrite input=gruppo
>> output=D:\temp\hpf_out_rescale2.tif format=GTiff type=Byte
>> createopt=INTERLEAVE=PIXEL,TFW=YES,PROFILE=BASELINE,COMPRESS=DEFLATE
>>
>> This is the results log:
>
>>
> [...]
>>
>> r.out.gdal completo. File  created.
>
>
> And the created file is not what you wanted ?
>
> Moritz



-- 
-
Andrea Peri
. . . . . . . . .
qwerty àèìòù
-
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user

Re: [GRASS-user] Exporting a raster tiff with RGB 3 bands produce a paletted tiff

2015-07-03 Thread Moritz Lennert

On 02/07/15 16:23, Andrea Peri wrote:

Hi Markus,
thx for hint.

I tried but probably I miss something.
because have an error:


ERROR 6: SetColorTable() not supported for multi-sample TIFF
files.

ERROR 6: SetColorTable() can only be called on band 1.
ERROR 6: SetColorTable() can only be called on band 1.



I defined a group named "gruppo" and insert in it the three raster I
like to have for the three bands.

After I execute this command:

r.out.gdal -f --overwrite input=gruppo
output=D:\temp\hpf_out_rescale2.tif format=GTiff type=Byte
createopt=INTERLEAVE=PIXEL,TFW=YES,PROFILE=BASELINE,COMPRESS=DEFLATE

This is the results log:

>
[...]

r.out.gdal completo. File  created.


And the created file is not what you wanted ?

Moritz
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Exporting a raster tiff with RGB 3 bands produce a paletted tiff

2015-07-02 Thread Andrea Peri
Hi Markus,
thx for hint.

I tried but probably I miss something.
because have an error:

>ERROR 6: SetColorTable() not supported for multi-sample TIFF
>files.
>
>ERROR 6: SetColorTable() can only be called on band 1.
>ERROR 6: SetColorTable() can only be called on band 1.


I defined a group named "gruppo" and insert in it the three raster I
like to have for the three bands.

After I execute this command:

r.out.gdal -f --overwrite input=gruppo
output=D:\temp\hpf_out_rescale2.tif format=GTiff type=Byte
createopt=INTERLEAVE=PIXEL,TFW=YES,PROFILE=BASELINE,COMPRESS=DEFLATE

This is the results log:


WARNING: Perdita di precisione: mappa raster
 di tipo DCELL da esportare come
Byte. Può essere evitata usando Float64.
WARNING: Perdita di precisione: mappa raster
 di tipo DCELL da esportare come
Byte. Può essere evitata usando Float64.
WARNING: Perdita di precisione: mappa raster
 di tipo DCELL da esportare come
Byte. Può essere evitata usando Float64.
WARNING: Si sta forzando l'esportazione del raster.
Checking GDAL data type and nodata value...
Using GDAL data type 
La mappa raster di input contiene celle con valore NULL (nessun dato).
Il valore 255 verrà usato per rappresentare i valori delle celle senza
dati nella mappa di input. È possibile specificare un valore per le
celle senza dati con l'opzione nodata.
Using GDAL data type 
La mappa raster di input contiene celle con valore NULL (nessun dato).
Il valore 255 verrà usato per rappresentare i valori delle celle senza
dati nella mappa di input. È possibile specificare un valore per le
celle senza dati con l'opzione nodata.
ERROR 6: SetColorTable() not supported for multi-sample TIFF
files.
Using GDAL data type 
La mappa raster di input contiene celle con valore NULL (nessun dato).
Il valore 255 verrà usato per rappresentare i valori delle celle senza
dati nella mappa di input. È possibile specificare un valore per le
celle senza dati con l'opzione nodata.
Exporting raster data to GTiff format...
ERROR 6: SetColorTable() can only be called on band 1.
ERROR 6: SetColorTable() can only be called on band 1.
r.out.gdal completo. File  created.


Thx,

A.


2015-07-02 12:56 GMT+02:00 Markus Neteler :
> Hi,
>
> On Jul 2, 2015 11:58 AM, "Andrea Peri"  wrote:
>>
>> Hi,
>> I'm try-ing to export a raster RGB using this command:
>
> If you have the three RGB channels, you can export via a group:
>
> http://grass.osgeo.org/grass70/manuals/r.out.gdal.html#export-r,g,b-imagery-bands-in-geotiff-format-suitable-for-esri-software:
>
> Best
> Markus



-- 
-
Andrea Peri
. . . . . . . . .
qwerty àèìòù
-
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user

Re: [GRASS-user] Exporting a raster tiff with RGB 3 bands produce a paletted tiff

2015-07-02 Thread Markus Neteler
Hi,

On Jul 2, 2015 11:58 AM, "Andrea Peri"  wrote:
>
> Hi,
> I'm try-ing to export a raster RGB using this command:

If you have the three RGB channels, you can export via a group:

http://grass.osgeo.org/grass70/manuals/r.out.gdal.html#export-r,g,b-imagery-bands-in-geotiff-format-suitable-for-esri-software
:

Best
Markus
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user

[GRASS-user] Exporting a raster tiff with RGB 3 bands produce a paletted tiff

2015-07-02 Thread Andrea Peri
Hi,
I'm try-ing to export a raster RGB using this command:

r.out.gdal -c input=input_image@PERMANENT
output=/path-to-raster//output_image.tif format="GTiff" type="Byte"
createopt="INTERLEAVE=PIXEL,TFW=YES,PROFILE=BASELINE,COMPRESS=DEFLATE"

It produce successfully a tiff ,
but it is a
paletted tiff.
Instead I like to have a true-color RGB tiff.

I miss some parameter ?

Thx,


-- 
-
Andrea Peri
. . . . . . . . .
qwerty àèìòù
-
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user