This is my 'ScaleDown' function to scale Jpeg . How to call this function on the time of drawing the image or simply, how can i use this function to scale from Draw Function .Here is my scale function.Help me....

Code:
CFbsBitmap* CTestAppView::ScaleDown(TInt newWidth, TInt newHeight)
	{
	TInt KNewImageWidth = newWidth;
	TInt KNewImageHeight = newHeight;
	

	iScaler = CMdaBitmapScaler::NewL();

	TRAPD(err,iScaler->ScaleL(*this,*iBitmap,TSize(KNewImageWidth,KNewImageHeight)));
	//iScaler->ScaleL(*this,*iBitmap,TSize(100,100)
	//iBmpScale->Scale(&iStatus, *iSrcBitmap, TSize(100,100));
	//SetActive();

	CActiveScheduler::Start();

	if (err == KErrNone)
		{
		iConvertState = EConvertStateScaling;
		}
	
	return iBitmap;
	}