[Libreoffice-commits] core.git: Branch 'feature/tiledrendering' - 3 commits - ios/shared sw/source vcl/ios

Ptyl Dragon ptyl at cloudon.com
Mon Nov 4 15:10:53 CET 2013


 ios/shared/ios_sharedlo/objective_c/view_controllers/testing_tiles/MLOTestingTile.m |    2 ++
 sw/source/core/view/viewsh.cxx                                                      |    1 +
 vcl/ios/iosinst.cxx                                                                 |    1 +
 3 files changed, 4 insertions(+)

New commits:
commit f9e972fb84335de2e7e7533e8e5cfa1a488f4e99
Author: Ptyl Dragon <ptyl at cloudon.com>
Date:   Mon Nov 4 16:10:10 2013 +0200

    release BitmapReadAccess after use to fix 1 mb per render mem leak
    
    Change-Id: I4d9a580132eb9a8d618c1165f962b47be4e80695

diff --git a/sw/source/core/view/viewsh.cxx b/sw/source/core/view/viewsh.cxx
index 7ac4c0d..e3f7cbb 100644
--- a/sw/source/core/view/viewsh.cxx
+++ b/sw/source/core/view/viewsh.cxx
@@ -1830,6 +1830,7 @@ void touch_lo_draw_tile(void *context, int contextWidth, int contextHeight, MLOD
                              context,
                              contextWidth,
                              contextHeight);
+        aBitmap.ReleaseAccess(readAccess);
     }
     Application::ReleaseSolarMutex();
 }
commit 75f61fe97b3a6e5069ccad63995bfa2af981dc54
Author: Ptyl Dragon <ptyl at cloudon.com>
Date:   Mon Nov 4 16:08:39 2013 +0200

    releasing the CGDataProvider to prevent possible memory leaks
    
    Change-Id: Ib64f457bd9cc185e979b1a3e9f07fdba93da88d7

diff --git a/vcl/ios/iosinst.cxx b/vcl/ios/iosinst.cxx
index 39208f5..c0f7073 100644
--- a/vcl/ios/iosinst.cxx
+++ b/vcl/ios/iosinst.cxx
@@ -412,6 +412,7 @@ touch_lo_copy_buffer(const void * source, size_t sourceWidth, size_t sourceHeigh
     CGRect targetRect = CGRectMake( 0, 0, targetWidth, targetHeight );
     CGContextDrawImage( context, targetRect, sourceImage );
     CGImageRelease(sourceImage);
+    CGDataProviderRelease(provider);
 }
 
 extern "C"
commit 8121f1d8dca970edbe9c64441dabfc2efb7dc3a6
Author: Ptyl Dragon <ptyl at cloudon.com>
Date:   Mon Nov 4 16:06:15 2013 +0200

    measuring the time it takes to render a tile
    
    Change-Id: I37db170af0e507c99d571b94ff78a1987944290e

diff --git a/ios/shared/ios_sharedlo/objective_c/view_controllers/testing_tiles/MLOTestingTile.m b/ios/shared/ios_sharedlo/objective_c/view_controllers/testing_tiles/MLOTestingTile.m
index 1b25648..784c0dd 100644
--- a/ios/shared/ios_sharedlo/objective_c/view_controllers/testing_tiles/MLOTestingTile.m
+++ b/ios/shared/ios_sharedlo/objective_c/view_controllers/testing_tiles/MLOTestingTile.m
@@ -43,6 +43,7 @@
 
 - (void)drawRect:(CGRect)rect
 {
+    NSTimeInterval startTime = CACurrentMediaTime();
     CGContextRef context = UIGraphicsGetCurrentContext();
 
     MLODpxPoint tilePosition =MLODpxPointByDpxes(self.tester.params.tilePosX,self.tester.params.tilePosY);
@@ -62,6 +63,7 @@
                        tilePosition,
                        tileSize);
 
+    NSLog(@"tile rendering took %f seconds",CACurrentMediaTime() - startTime);
     MLODpxSize size = touch_lo_get_content_size();
     NSLog(@"touch_lo_get_content_size: width=%f, height=%f",size.width, size.height);
 }


More information about the Libreoffice-commits mailing list