SetSrcRect example for C++ Builder
This example zooms in on the image by reducing the source rectangle and repaints the image.
float NewLeft, NewTop, NewWidth, NewHeight;
NewLeft= LEADRasterView1->SrcLeft + (LEADRasterView1->SrcWidth * 0.1);
NewTop= LEADRasterView1->SrcTop + (LEADRasterView1->SrcHeight * 0.1);
NewWidth = LEADRasterView1->SrcWidth * 0.8;
NewHeight = LEADRasterView1->SrcHeight* 0.8;
if ((NewWidth > 1) && (NewHeight >1))
LEADRasterView1->SetSrcRect (NewLeft, NewTop, NewWidth, NewHeight);
LEADRasterView1->ForceRepaint ();