weixj2003ld,<br><br>Can you provide your code and a link to the sample dataset that shows this error?<br><br><div class="gmail_quote">2010/4/14 weixj2003ld <span dir="ltr">&lt;<a href="mailto:weixj2003ld@163.com">weixj2003ld@163.com</a>&gt;</span><br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div> I use the following code to read data from a geotiff file and do some computing and write it into<br>
 a new one.the bands number is 6; ...<br> GDALDataset *poSrcDS,*poDstDS;//poSrcDs:the source file,poDstDS:the goal<br> source GDALRasterBand *poSrcBand,*poDstBand;//poSrcBand:the source<br> band,poDstBand:the goal band GDALDriver *poDstDriver;<br>
 double *m_AdGeoTransform=new double[6];<br><br> ...<br> poDstDriver=GetGDALDriverManager()-&gt;GetDriverByName(poSrcDS-&gt;GetDriver()-&gt;G<br>etDescrition());<br> poDstDS=poDstDriver-&gt;create(DstFilename,nX,nY,6,GDT_Float32,NULL);<br>
 poSrcDS-&gt;GetGeoTransform(m_AdGeoTransform)<br> poDstDS-&gt;SetGeoTransform(m_AdGeoTransform);<br> poDstDS-&gt;SetProjection(poSrcDS-&gt;GetProjectionRef());<b><br> for(int iBand=0;iBand&lt;6;iBand++)<br>{<br>    poSrcBand=poSrcDS-&gt;GetRaserBand(iBand+1);<br>
   poDstBand=poDstDS-&gt;GetRaserBand(iBand+1);<br>   float *pafScanline;<br>   pafScanline=(float *)CPLMalloc(sizeof(float)*nX;<br>   for(int i=0;i&lt;nY;i++)<br>  {   <br>poSrcBand-&gt;RasterIO(GF_Read,0,0,nX,i,pafScanline,nX,1,GDT_Float32,0,0);<br>
 poDstBand-&gt;RasterIO(GF_Write,0,0,nX,i,pafScanline,nX,1,GDT_Float32,0,0);//If I comment this code,the program will be ok. }<br> }<br>GDALClose((GDALDatasetH)poDstDS);<br><br>When I run my program,CPU is very alway busy,and the program is<br>
 blocked,why?<br></b></div><br><br><span title="neteasefooter"></span><br>_______________________________________________<br>
gdal-dev mailing list<br>
<a href="mailto:gdal-dev@lists.osgeo.org">gdal-dev@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br></blockquote></div><br><br clear="all"><br>-- <br>Best regards,<br>Chaitanya kumar CH.<br>
/tʃaɪθənjə/ /kʊmɑr/ <br>+91-9848167848<br>17.2416N 80.1426E<br>