final report about utilizing the android opengl ... · final report about utilizing the android...

18
Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Rainer Rehak Dr. rer. nat. Wolf Müller Prof. Dr. rer. nat. Jens-Peter Redlich HUMBOLDT-UNIVERSITÄT ZU BERLIN COMPUTER SCIENCE DEPARTMENT Systems Architecture Group - 1 -

Upload: others

Post on 21-Jun-2020

4 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

Final report about utilizing the Android OpenGL

capabilities for designing graphical user interfaces

Rainer RehakDr. rer. nat. Wolf Müller

Prof. Dr. rer. nat. Jens-Peter Redlich

HUMBOLDT-UNIVERSITÄT ZU BERLINCOMPUTER SCIENCE DEPARTMENT

Systems Architecture Group

- 1 -

Page 2: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

Table of contents1. Summary of Tasks and Goals.............................................................................3

2. Technology Background.....................................................................................3

2.1. Overview of the Android platform ...........................................................3

2.2. Google Android and its SDK......................................................................4

3. Android-GUI........................................................................................................5

3.1. Graphics API and philosophy....................................................................5

3.2. Graphics Architecture...............................................................................5

3.3. Using OpenGL in a view............................................................................6

3.4. Problems of proposed solution & alternative approaches........................7

4. Existing GUI elements and tutorial.....................................................................7

4.1. How do they look and how are they used.................................................7

4.2. How are they programmed?.....................................................................8

4.3. Technical details – energy consumption and performance issues..........10

5. Practical Examples – GUI rendering capabilities in innovative applications......11

5.1. Android developer's challenge...............................................................11

5.2. Discussion of new/innovative GUI elements...........................................14

6. Android SDK versions and upgrade strategies.................................................15

7. Results and conclusion.....................................................................................15

7.1. Summary of what we have done............................................................15

7.2. Summary of what we have learned from doing that..............................16

7.3. Future outlook........................................................................................16

8. Appendix..........................................................................................................17

8.1. Our development environment..............................................................17

8.2. Source code – files and instructions how to use/install...........................17

- 2 -

Page 3: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

1. Summary of Tasks and Goals

For our work with Android we defined the following goals:

➢ Study the Android SDK, especially its graphics rendering capabilities

➢ Implement demo applications that make use of the Android GUI toolkit and integrate them

with OpenGL ES

➢ Analyze applications from the Android Developer Challenge for innovative GUI concepts and

study their GUI requirements

➢ Report our experience with the SDK, its tools, the updates and development process.

2. Technology Background

2.1. Overview of the Android platform

The Android platform consists of an underlying Linux as operating system, drivers for various devices

to abstract the hardware and provide interfaces to use it as well as several libraries for accessing and

using the devices easily. Android also contains a number of high level managers such as

ViewSystemManager, LocationManager and TelephonyManager which makes it a comfortable and

complete application framework for mobile devices. On top of it, Android ships with an already

working mobile phone software bundle including contact management, media player, map viewer,

browser, camera software, instant messaging and a comfortable home screen. The provided libraries

and the managed environment use the Java programming language. So far, the Android project is still

closed source but the code will presumably be released under an open source license soon1.

1 http://code.google.com/android/kb/licensingandoss.html (18.09.2008)

- 3 -

Page 4: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

2.2. Google Android and its SDK

Current version and features of Android

There have bee several versions of the Android SDK so far with the most recent being v0.9 beta2. It

provides the following features

A powerful application framework enabling reuse and replacement of components

the Dalvik virtual machine which is optimized for mobile devices

An integrated browser based on the open source WebKit engine

Optimized graphics powered by a custom 2D graphics library and 3D graphics based on the

OpenGL ES 1.0 specification (hardware acceleration optional)

SQLite for structured data storage

Media support for common audio, video, and still image formats (MPEG4, H.264, MP3,

AAC, AMR, JPG, PNG, GIF)

Interfaces for using GSM Telephony (hardware dependent)

Interfaces for using Bluetooth, EDGE, 3G, and WLAN (hardware dependent)

Interfaces for using Camera, GPS, compass, and accelerometer (hardware dependent)

Rich development environment

Tools and features of the Android SDK 

In addition to the Android platform itself, the SDK includes several tools for testing and debugging.

A device emulator which displays a modern

generic mobile phone with its screen,

buttons and an external keyboard. All

buttons work properly and clicking the

mouse on the screen simulates using a touch

screen. The emulator can be started by

executing the “emulator” binary in the tools

folder.

An Android Asset Packaging Tool for

creating apk-files files that can be loaded

into Android. Those apk-files contain all

necessary files (binaries, images, per-

missions) of an application. The Packaging Tool can be used by executing the “aapt” binary in

the tools folder.

2 http://code.google.com/android/download_list.html (18.09.2008)

- 4 -

Page 5: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

Tools for debugging the Dalvik virtual machine

Tools for memory and performance profiling

The SDK also contains many demo applications showing how to use certain widgets and

features as well as how to deal with different aspects of the Android environment. The source

code is well commented and very helpful.

There is also a plug-in for the Eclipse IDE. This plug-in is not part of the Android core SDK,

i.e. it has to be downloaded separately. Using the Eclipse IDE together with the Android plug-

in creates a very comfortable development environment, since compilation, signing, packet

creation (apk-files), starting the emulator, installing the application and starting it are all done

automatically.

How to get started

This is just a summary of what and how to set up at the very beginning:

i. Install a recent Java JDK3

If you are using any flavor of Linux, java-gcj has to be uninstalled and replaced by

SUN's sun-java6-jdk

ii. Install the Eclipse IDE4

iii. Install the Android SDK5 and add its tools/ folder to the system path for easy access

iv. Install the Android Development Tools plug-in6 for Eclipse and add the path to the

Android SDK in the preferences

3. Android-GUI

3.1. Graphics API and philosophy

Graphical user interfaces in Android are designed by using XML files and controlled via Java. A lot of

helping libraries called widgets are provided for creating graphical user interfaces. This includes

buttons, pull down menus, auto completion, display of data sets and maps. A detailed analysis will be

shown later. Android ships with an implementation of OpenGL ES (Embedded Systems) version 1.0

which corresponds to OpenGL 1.3. OpenGL ES is an API consisting of well-defined subset profiles of

desktop OpenGL optimized for embedded graphic processors.

3.2. Graphics Architecture

The basic elements for creating graphical user interfaces are views. A view is a rectangular area on the

screen, which displays a specific GUI-element. Furthermore, it handles button events, touch events

and its layout. If it can be focused, it also takes care of its focus management. The Android platform

3 http://java.sun.com/javase/downloads/index.jsp (18.09.2008)

4 http://www.eclipse.org/downloads/ (18.09.2008)

5 http://code.google.com/android/download_list.html (18.09.2008)

6 http://code.google.com/android/intro/installing.html#installingplugin (18.09.2008)

- 5 -

Page 6: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

already provides a large variety of different presets. Those predefined views are called widgets. Some

examples are (visual examples can be found further down):

1. Text view

2. Image view

3. Button, check box, radio button, pull down menu

4. Auto completion edit text view

5. Progress bar

6. Lists, galleries

7. Free areas to draw on (e.g using 2D tools or OpenGL)

8. Custom views can be created as well

In Android an UI is typically constructed as a tree of views, where a view is a leaf in that tree held

together by nodes that are called view groups. View groups define common attribute of views further

down the tree. View groups contain other views or even other view groups. This relation can be

visualized as follows:

3.3. Using OpenGL in a view

Creating a normal (non-3D) Android GUI, all Android functions such as buttons, lists, galleries,

images and so on can easily be used, but using OpenGL requires the use of a SurfaceView, which is a

view that holds a drawing surface. This surface can be freely used as canvas for OpenGL 3D

rendering. Unfortunately, rendering in OpenGL works fundamentally differently from building an UI

with widgets. For rendering scenes in OpenGL, vertices have to be defined, textures generated, lights

positioned and so on. Since the SurfaceView is a leaf in the view tree structure, the handy widgets

provided by Android cannot be used just like that within the 3D world anymore.

- 6 -

Page 7: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

3.4. Problems of proposed solution & alternative approaches

The following solutions are reasonable options but still with speculations and further research is

needed to evaluate them. Probably there are ways to implement a graphical user interfaces involving

OpenGL that would seamlessly integrate into the Android GUI's look and feel, but solutions may

involve one or more of the following methods:

The basic Android window and window manager system could be customized/rewritten so

that the framework itself supports several virtual screens which could be mapped onto 3D

objects7. Difficulties arise when the Android platform receives an update.

All widgets could be customized/rewritten not to render onto a main window but into a

texture, which could then be used on cubes8 or similar. This will entail handling of change

detection for rendering (e.g. animated widgets have to be redrawn frequently) and event

forwarding (from the OpenGL surface to the Activities). Again, difficulties arise when the

Android platform receives an update.

Internal classes could be used in ways that they are not supposed to be used. One example

would be the utilization of the internal PhoneWindow class to change the internal way of how

windows are handled.

Recently, there has been OpenGL support added for drawing normal views faster. In addition

to the latest release of the Android SDK (v0.9 beta), indirect access to the front and back

buffer was granted, so possibly projecting running applications onto 3D surfaces might be

working in the future when the API changes again.

4. Existing GUI elements and tutorial

4.1. How do they look and how are they used

This is a simple dialog box consisting of a title

bar, a text field, a text input field and two

buttons. Further down we will examine the

source code.

This is an alarm clock with a dedicated drawing

surface for 2D rendering and several text fields

and check boxes

7 http://www.compiz-fusion.org (18.09.2008)

8 http://www.compiz-fusion.org (18.09.2008)

- 7 -

Page 8: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

Here is another more complex interface

showing a contact's information. It uses

images, icons and text fields. One can see

how easy it is to create a nice look and

feel because the colors are mainly

determined by the chosen theme, but not

by the program-mer.

This is a highly complex design using

dynamically loaded images, overlay

menus and icons. As in all examples

above, the screen navigation works with

both the digital pad and the touch

screen.

4.2. How are they programmed?

Using standard widgets, screen design can easily be done

using XML. There you also define ID to which you can

refer for event handling or other actions. As a simple

example, see the XML-code for this dialog box:

- 8 -

Page 9: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

<?xml version="1.0" encoding="utf­8"?><RelativeLayout 

xmlns:android="http://schemas.android.com/apk/res/   android   "android:layout_width="fill_parent" 

  android:layout_height="wrap_content"  android:background="#000099"  android:padding="10px">

  <TextView   android:id="@+id/label" 

android:layout_width="fill_parent"android:layout_height="wrap_content" 

  android:text="Type here:"></TextView>

  <EditText   android:id="@+id/entry"   android:layout_width="fill_parent"   android:layout_height="wrap_content"  android:background="#FFF"  android:layout_below="@id/label">

</EditText>   <Button   android:id="@+id/ok"   android:layout_width="wrap_content"   android:layout_height="wrap_content"   android:layout_below="@id/entry"  android:layout_alignParentRight="true"  android:layout_marginLeft="10px"  android:text="OK">

</Button>

  <Button   android:layout_width="wrap_content"   android:layout_height="wrap_content"  android:layout_toLeftOf="@id/ok"  android:layout_alignTop="@id/ok"  android:text="Cancel">

</Button>

</RelativeLayout>

- 9 -

Page 10: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

This sample XML code snippet shows that the ViewGroup “RelativeLayout” is the root node and the

text and button views are children for this view. The structure can be visualized as follows:

As mentioned earlier, OpenGL SurfaceViews are also views and XML code using them would look

like this:

<de.hu_berlin.informatik.sar.OpenGL_SurfaceView    android:id="@+id/OpenGL_SurfaceView_Handle"    android:layout_width="wrap_content"    android:layout_height="wrap_content"></de.hu_berlin.informatik.sar.OpenGL_SurfaceView>

Within this view, polygons, colors, images, transitions and other 3D instructions have to be defined,

processed and then rendered like in any other OpenGL application on desktop computers. This is

especially beneficial when porting OpenGL games to Android, but clearly disadvantageous for normal

GUI programming.

4.3. Technical details – energy consumption and performance issues

Rendering scenes using OpenGL is fundamentally different from 2D screen creation. If there is a

change in a 2D scene, only this part has to be be redrawn. That is different for 3D scenes, since

changes in a small part of the scene require a complete recalculation. Therefore the need for more

computation power is immanent to using OpenGL. This is not a big problem on desktop computers in

general, but the significantly higher power consumption has heavy impact on battery life of mobile

devices. Several solutions to reduce the need for recalculation are as follows.

Usually 3D applications render the screen at the highest rate possible to provide a fluent 3D

experience. This means the graphics processor works at full load.

Rendering at a fixed frame rate

On a mobile device it might be wanted to reduce the frame rate to 24 frames per second or even less to

save battery life. This can be achieved by letting the drawing thread wait some time if it finished the

previous frame faster than necessary. The frame rate should be adjusted to fit the displayed content.

Please consult the source code for further details of implementation9.

No rendering when there is no motion

The second approach to reduce battery consumption is to define a state when there is nothing changing

on the screen. At periods of time, where a static scenes is being displayed, the rendering process can

9 GL_Base.java, line 252

- 10 -

Page 11: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

pause too. This has to be carefully dealt with, because it needs deeper knowledge of the displayed

content, since even an input form could let the focused line glow periodically to draw attention. Again,

please consult the source code for further details of implementation10.

RBGA conversion

For storing images Android internally uses the 32-bit ARGB (8 bit alpha, 8 Bit red, 8 bit green, 8 bit

blue) format, but since OpenGL uses the 32-bit RGBA format, images have to be reformatted before

using them in OpenGL, which takes some time11. For games this loading time of several seconds at the

beginning is tolerable, but for using it in a highly dynamic context, more optimization is needed.

Float / fixed data types

Especially 3D calculations make heavy use of floating point numbers to define vertices. On desktop

computers this is done in hardware, but on mobile devices, embedded processors frequently do not

have hardware floating point support, so all operations on "float" and "double" are performed in

software, which is much slower. This has to be kept in mind when using 3D technology. Presumably

the technological progress of embedded 3D controllers will quickly make this problem less significant.

Further optimizations

Some basic rules have to be obeyed writing fast code for mobile devices, since their hardware is

optimized other aspects than desktop systems. Some examples are:

Minimize object creation

Minimize the use of synchronized methods

Use Enhanced For-Loop-Syntax

A more detailed analysis of how to write efficient code for Android can be found online12.

5. Practical Examples – GUI rendering capabilities in innovative applications

5.1. Android developer's challenge

This is a choice of innovative applications from the Android developer's

challenge. Each application is summarized and a representative screen

shot is shown:

➔ cab4me - Enables you to easily call a cab to any

location worldwide. You do not need to know the

number of the local cab company. You do not need

to enter or even know the address you want to be

10 GL_Base.java, line 256

11 This heavily depends on the hardware, but we experienced 0.2 seconds for a 300x400 image in our emulator tests.

12 http://code.google.com/android/toolbox/performance.html (18.09.2008)

- 11 -

Page 12: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

picked up at. The screen shot displays where you are at the moment and when

approximately you will be picked up by a cab.

➔ Compare - Scan a bar code to instantly

check if that "sale price" really is a

good deal. Read reviews to find out if

those hiking boots will last a lifetime or

fall apart next month. Keep track of

shopping lists, wish lists, and more.

The screen shot shows a picture of a

bar code which has been taken with the

built-in phone camera and is to be

analyzed at the moment.

➔ Locale - An advanced settings

manager that auto-matically changes

your phone's settings based on

conditions such as location. The screen

shot visualizes areas for which the user

defined specific presets.

➔ Piggyback - A revolutionary real-time

carpooling application for mobile

phones that helps you save time and

money while reducing your carbon

footprint. In this picture, one can see a

photo of the car, its number plate and

estimated time of arrival to make it

easier to recognize your carpooling

partner.

- 12 -

Page 13: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

➔ Pocket Journey - Turn your mobile phone

into a personal tour guide by connecting

you to location-specific multimedia

created by a community of the most pro-

fessional tour guides and story-tellers

worldwide. Here you see an animation

explaining how the landscape you have

around you has been created.

➔ BioWallet - Biometric authen-tication system

and security platform that performs user

identification based on some-thing that the

user is or has, rather than something that the

user knows or owns. Here you see a picture of

an iris which has been captured and analyzed

with the mobile device.

➔ City Slikkers - A Pervasive Game which takes place in the real-existing city. It is

designed to connect a large number of

players throughout the city and enable

them to organize the city's metaphorical re-

capture. The game combines elements of

strategy, role-playing, sports and social and

tactical games. Here you see your character

sheet and a part of the surroundings. This

application used 3D techniques, probably

OpenGL.

➔ FreeFamilyWatch.com - Free location-based

services helping family to navigate safety risks

in daily living through real-time and risk-

preventing measures against crimes,

environmental health hazards and distressing

emergencies. This screen shot visualized areas

of potential dangers.

- 13 -

Page 14: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

➔ JOYity - A platform for next generation mo-

bile entertainment applications that provides a

pioneering mixture of real-life adventure

games, geocaching and intensive social

networking acti-vities. In this screen shot, you

see the map in the background and an item that

has just been found.

➔ Wikitude - A mobile travel guide

based on location-based Wikipedia

content. Points of interest can be

viewed in a map, list, or a cam view.

This image shows a photo with

additional in-formation about the area

around you.

5.2. Discussion of new/innovative GUI elements

Most of the applications make use of the vast amount of widgets, 2D drawing capabilities, Google

maps API and overlay structures to combine all of them. Underlying Android features are the Android

GPS capabilities, the Google Open Social API and the always on-line principle Google proposes. The

GUIs look nice, modern and they integrate well into

the Android environment since the widgets are

provided.

Although it is now very easy to design neat and stylish

user interfaces, the novelty of the Android platform is

not the graphical improvement but the seamless

integration of formerly separate technologies(e.g.

WLAN, telephone, GPS...) and techniques (e.g. route

planning, instant messaging...).

To visualize this idea, here is a use case. Some friends

arranged a spontaneous barbecue in a rather big park

using a social network platform. One person is a bit

late and since his friends changed to a better fireplace,

he cannot find them. He calls them and they tell him

that the charcoal probably will not be enough while

sending him the GPS coordinates and some pictures of

their new barbecue site. He uses a location-based

service to check online where the next petrol station is

to buy charcoal and then finds his way there and back

to his friends using the map application.

- 14 -

Page 15: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

We expect that even totally new ideas and applications will be using mostly those basic views

provided by Android.

6. Android SDK versions and upgrade strategies

The recent release of the Android SDK is the first one that is formally on the path to Android 1.0. This

is also hinted by the version numbering scheme (m3 to m5 to 0.9) so far. The present release contains

a lot of API improvements, cleanups and changes. The classes OpenGLContext and Texture

disappeared completely, and on other parts of the code methods have been renamed and such. The

differences in the API between this release and final 1.0 compatible releases are expected to be

small13.

Since the source code of the Android platform is still closed, it is impossible to say what changes, for

example the Java Virtual machine or the Android libraries, have been undergone, but the performance

now is noticeably better. With the m5 release, one could observe a drop in execution time of an

application after it had been run once. This ranged from up to the factor 2 or 3. Now the code runs fast

from the first execution on. Furthermore, one could observe a high impact of touch pad or button

activity on the performance such as 3D calculations heavily slowing down. This has been minimized

greatly, so we assume event handling has been optimized. The last versions had the same tools and

mainly the same features. The heavy changes took place in actual implementations and some heavy

interface changes took place.

Migration strategy and effort

In our case, porting the code was not very difficult. We updated the Android SDK and the Eclipse

plug-in, and then erased the errors. The latest version recognized the majority of errors as update

related and suggested a way to solve them. In the rare case that errors persisted, checking the shipped

sample code and demo applications for hints, changes and implementations finally solved all problems

and gave new inspiration. It has to be noted that the Android community is already huge and common

problems are being worked on together, which also helped upgrading.

When does it make sense to migrate?

With the given stage of development of Android, migration is vital for productive development since

the Android code still has lots of bugs and the interface definitions are still changing. Erroneous

behavior might be caused by errors in the Android code and not in the application. Keeping one's

application for a past or even the present version (0.9 beta) of Android is not an investment in the

future. The motivation to update is to be compatible with the present API since it is moving closer to

1.0. Not updating, therefore, means not being compatible with the official Android release.

7. Results and conclusion

7.1. Summary of what we have done

We implemented two applications using the OpenGL ES API. The first one is a 3D cube showing

screen shots of applications that are actually executable and the second one is an image gallery

13 http://code.google.com/android/RELEASENOTES.html (18.09.2008)

- 15 -

Page 16: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

implementing a carousel-like view for flipping though pictures. Both applications allow freehand

rotation using the touch pad.

7.2. Summary of what we have learned from doing that

The Android platform offers a powerful framework for developing applications. Standard GUI design

is easy and a comfortable programming environment is provided, hence an active community has

formed itself long before the version 1.0 has been released. From the way OpenGL is integrated into

Android we assume it is meant to be used mainly for games.

7.3. Future outlook

The openness of the project will produce a vast amount of user generated software since it will attract

the open source community. If Android becomes a successful project. It will be populated with lots of

very creative and also not so creative applications.

Google is planning to release the source code using the Apache Open Source license14. This license

allows to use the source code in proprietary products as well. Therefore, Android is a platform not

only for open source supporters, but also commercially oriented closed source companies. This means

that a company using Android can chose whether to use and keep the platform open or to alter and

customize it as closed source for the companies’ needs.15 Selling binaries will still be a business

model, although a tough one.

14 http://www.apache.org/licenses/LICENSE-2.0 (18.09.2008)

15 http://code.google.com/android/kb/licensingandoss.html#apache2 (18.09.2008)

- 16 -

Page 17: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

8. Appendix

8.1. Our development environment

➔ Hardware: Intel Pentium 4 with 3 GHz, 2 GB RAM

Operating System: Ubuntu 8.04 with kernel 2.6.24-19

➔ Software: Eclipse v3.4

Android Development Tools Eclipse plug-in v0.7.1

Android SDK v0.9 beta

8.2. Source code – files and instructions how to use/install

To install the application, start the emulator and wait for it to finish booting. Then unpack our file

archive and navigate there, then type

adb install <path­to­the­apk­file>

in our case probably

adb install OpenGLES_HUB/bin/OpenGLES_HUB.apk

and the program will appear in the list of installed programs in Android.

File list:

OpenGLES_HUBOpenGLES_HUB/AndroidManifest.xmlOpenGLES_HUB/assetsOpenGLES_HUB/binOpenGLES_HUB/resOpenGLES_HUB/srcOpenGLES_HUB/bin/OpenGLES_HUB.apkOpenGLES_HUB/bin/classes.dexOpenGLES_HUB/bin/deOpenGLES_HUB/bin/resources.ap_OpenGLES_HUB/bin/de/hu_berlinOpenGLES_HUB/bin/de/hu_berlin/informatikOpenGLES_HUB/bin/de/hu_berlin/informatik/sarOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/GL_Base$TimeMarker.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/GL_Base.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/GL_carousel.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/GL_carousel_Act.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/GL_cube.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/GL_cube_Act.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/OpenGLES_HUB$1.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/OpenGLES_HUB$2.class

- 17 -

Page 18: Final report about utilizing the Android OpenGL ... · Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces Tools for debugging the

Final report about utilizing the Android OpenGL capabilities for designing graphical user interfaces

OpenGLES_HUB/bin/de/hu_berlin/informatik/sar/OpenGLES_HUB.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/R$attr.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/R$drawable.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/R$id.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/R$layout.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/R$string.classOpenGLES_HUB/bin/de/hu_berlin/informatik/sar/R.classOpenGLES_HUB/res/drawableOpenGLES_HUB/res/layoutOpenGLES_HUB/res/valuesOpenGLES_HUB/res/drawable/android.pngOpenGLES_HUB/res/drawable/browser.pngOpenGLES_HUB/res/drawable/browser_small.pngOpenGLES_HUB/res/drawable/dialer.pngOpenGLES_HUB/res/drawable/dialer_small.pngOpenGLES_HUB/res/drawable/gmaps.pngOpenGLES_HUB/res/drawable/gmaps_small.pngOpenGLES_HUB/res/drawable/icon.pngOpenGLES_HUB/res/drawable/menu.pngOpenGLES_HUB/res/drawable/menu_small.pngOpenGLES_HUB/res/drawable/settings.pngOpenGLES_HUB/res/drawable/settings_small.pngOpenGLES_HUB/res/layout/main.xmlOpenGLES_HUB/res/values/strings.xmlOpenGLES_HUB/src/deOpenGLES_HUB/src/de/hu_berlinOpenGLES_HUB/src/de/hu_berlin/informatikOpenGLES_HUB/src/de/hu_berlin/informatik/sarOpenGLES_HUB/src/de/hu_berlin/informatik/sar/GL_Base.javaOpenGLES_HUB/src/de/hu_berlin/informatik/sar/GL_carousel.javaOpenGLES_HUB/src/de/hu_berlin/informatik/sar/GL_carousel_Act.javaOpenGLES_HUB/src/de/hu_berlin/informatik/sar/GL_cube.javaOpenGLES_HUB/src/de/hu_berlin/informatik/sar/GL_cube_Act.javaOpenGLES_HUB/src/de/hu_berlin/informatik/sar/OpenGLES_HUB.javaOpenGLES_HUB/src/de/hu_berlin/informatik/sar/R.java

- 18 -