diff -r 4c62338e03c8 -r 5cc7cc9a1c87 svgtopt/SVGEngineJI/src/SvgJavaInterfaceImpl.cpp --- a/svgtopt/SVGEngineJI/src/SvgJavaInterfaceImpl.cpp Fri May 14 16:45:42 2010 +0300 +++ b/svgtopt/SVGEngineJI/src/SvgJavaInterfaceImpl.cpp Wed Jun 23 19:13:25 2010 +0300 @@ -241,6 +241,34 @@ */ } +/* + * M2G: SvgEngineRenderDocument() overloaded to pass the CSvgtBitmap object to SvgEngine + */ +EXPORT_C void CSvgJavaInterfaceImpl::SvgEngineRenderDocument( + SvgEngineHandle aEngineHandle, SvgDocumentHandle aDocumentHandle, + SvgtBitmapHandle aSurfaceHandle, SvgtBitmapHandle aSurfaceMaskHandle, + TReal32 aCurrentTime ) + { + CSvgEngineInterfaceImpl::iFileIsLoaded = ETrue; + + SetDocument( (CSvgEngineImpl*)aEngineHandle, (CSvgDocumentImpl*)aDocumentHandle ); + + // GfxContext creation + TRAPD(error, SetGdiContextL( (CSvgEngineImpl*)aEngineHandle, (CSvgtBitmap*)aSurfaceHandle ) ); + if ( error != KErrNone ) + { + // ignore trap error + } + + //this udpates things like Viewport with whatever preserveAspectRatio and widths are set + //InitializeEngine((CSvgEngineImpl*)aEngineHandle); + + if ( ((CSvgtBitmap*)aSurfaceMaskHandle) != NULL) + GenerateMask((CSvgtBitmap*)aSurfaceMaskHandle); + + RenderFrame( (CSvgEngineImpl*)aEngineHandle, (TUint)(aCurrentTime * 1000) ); + } + /** * */ @@ -2688,8 +2716,8 @@ default: attribVal = KErrNotFound; + } return attribVal; - } } /** * This maps the Enumeration from SVG to JSR.