summaryrefslogtreecommitdiff
path: root/android/README
blob: d7fdf77314227abb15a8236794e3c26294601a12 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
LibreOffice Android
*******************

Bootstrap
*********

Contains common code for all projects on Android to bootstrap LibreOffice. In
addition it is a home to LibreOfficeKit (LOK - see libreofficekit/README) JNI 
classes.

LOAndroid3 (in experimental)
****************************

LibreOffice Android application - the code is based on Fennec (Firefox for Android). 
It uses OpenGL ES 2 for rendering of the document tiles which are gathered from 
LibreOffice using LOK. The application contains the LibreOffice core in one shared 
library: liblo-native-code.so, which is bundled together with the application. 

TiledRendering
**************

Tiled rendering is a technique that splits the document to bitmaps of same size 
(typically 256x256) which are fetched on demand. 

Architecture and Threading
**************************

The application implements editing support using 4 threads:
1. The Android UI thread, we can't perform anything here that would take a considerable 
   amount of time.
2. An OpenGL thread which contains the OpenGL context and is responsible for drawing 
   all layers (including tiles) to the screen.
3. A thread (LOKitThread), that performs LibreOfficeKit calls, which may take more time
   to complete. In addition it also receives events from the soffice thread (see below) 
   when the callback emits an event. Events are stored in a blocking queue (thread 
   processes events in FCFS order, goes to sleep when no more event is available and
   awakens when there are events in queue again).
4. A native thread created by LibreOfficeKit (we call it the soffice thread), where 
   LibreOffice itself runs. It receives calls from LOKitThread, and may emit callback 
   events as necessary.