<div dir="ltr">Ok I think I get it :<div>the width are in pixel and not in map unit.</div><div><br></div><div>Cheers,</div><div>Rémi-C</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/12/18 Rémi Cura <span dir="ltr"><<a href="mailto:remi.cura@gmail.com" target="_blank">remi.cura@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hey list,<div><br></div><div>again noob question.<br><br></div><div>It seems impossible to create an empty raster with less than one scale (takes integer !).<br>
Now when I want to update the scale, the number of pixel is not updated :</div>
<div>Is it normal/what should I do?</div><div>Cheers,</div><div>Rémi-C</div><div><br></div><div><div>DROP TABLE IF EXISTS patch_to_raster;</div><div><span style="white-space:pre-wrap"> </span>CREATE TABLE patch_to_raster(rid serial primary key, rast raster);</div>

<div><br></div><div><span style="white-space:pre-wrap"> </span>--</div><div><span style="white-space:pre-wrap">       </span>--delete  from patch_to_raster</div><div><span style="white-space:pre-wrap">  </span>INSERT INTO patch_to_raster (rast) VALUES (</div>

<div><span style="white-space:pre-wrap">          </span>ST_MakeEmptyRaster(</div><div><span style="white-space:pre-wrap">                      </span>1</div><div><span style="white-space:pre-wrap">                        </span>,1</div><div><span style="white-space:pre-wrap">                       </span>,upperleftx:=0</div>

<div><span style="white-space:pre-wrap">                  </span>,upperlefty:=0</div><div><span style="white-space:pre-wrap">                   </span>,scalex:=1</div><div><span style="white-space:pre-wrap">                       </span>, scaley:=1</div><div><span style="white-space:pre-wrap">                      </span>, skewx:=0</div>

<div><span style="white-space:pre-wrap">                  </span>,skewy:=0</div><div><span style="white-space:pre-wrap">                        </span>--, srid:=932011</div><div><span style="white-space:pre-wrap">         </span>) --srid of translated lambert 93 to match laser referential</div>

<div><span style="white-space:pre-wrap">  </span>);</div><div>UPDATE patch_to_raster SET rast = ST_SetScale(rast,0.02,0.02)</div><div><br></div><div>FROM </div><div><span style="white-space:pre-wrap">     </span>SELECT ST_SetScale(rast,0.02,0.02)</div>

<div><span style="white-space:pre-wrap">  </span>FROM patch_to_raster;</div><div><span style="white-space:pre-wrap">    </span></div><div><span style="white-space:pre-wrap"> </span>SELECT ST_Summary(rast)</div><div>
<span style="white-space:pre-wrap">     </span>FROM patch_to_raster</div><div><span style="white-space:pre-wrap">     </span>--Raster of 1x1 pixels has 0 bands and extent of BOX(0 0,0.02 0.02)</div></div><div><br><br></div>
<div>Thanks,</div><div><br></div><div>Rémi-C</div></div>
</blockquote></div><br></div>