Hi All,
is anyone can tell me is there any wrongs at my draw image code below?
i got problem when i call draw ( use DrawNow() ), the image successfully draw but not for long time the screen became white again even image is still contained at memory.
THX,Code:void CTestMain::Draw( const TRect& aRect ) const { CWindowGc& gc = SystemGc(); gc.Clear( aRect ); if (iBolDraw) { CFbsBitmap* bitmap = new CFbsBitmap; RFs fs; User::LeaveIfError(fs.Connect()); CImageDecoder* decoder = CImageDecoder::DataNewL(fs, *iBuf); //iBuf = HBufc8* TFrameInfo frameInfo = decoder->FrameInfo(0); bitmap->Create(frameInfo.iOverallSizeInPixels, frameInfo.iFrameDisplayMode); TRequestStatus status = KRequestPending; decoder->Convert(&status, *bitmap); gc.BitBlt(TPoint(0,0), bitmap); fs.Close(); } }
Best Regards,
Jun



