aboutsummaryrefslogtreecommitdiffstats
path: root/android/skin
Commit message (Collapse)AuthorAgeFilesLines
* Handle SDL windows with BGRA colorJesse Hall2012-07-222-17/+56
| | | | | | | | | | | | The switch to CoreGraphics on OSX (instead of QuickDraw) in SDL 1.2.15 means the SDL-created window now has BGRA color order instead of ARGB. This change makes the r5g6b5 and xbgr32 format converters handle whatever channel ordering the main SDL surface has. Skin regions don't need to change, since we draw them into auxiliary surfaces we created with ARGB order, and SDL does the conversion when we blit them into the main window. Change-Id: I2ae0529c66c11b60b3ade7a7a742368a2ab614bd
* Fix 64-bit build.David 'Digit' Turner2011-11-231-5/+7
| | | | | | | | | | This fixes the 64-bit Linux build (i.e. ./android-rebuild.sh --try-64). You can't really call _mm_empty() when your target CPU doesn't support MMX. We should probably try to use XMM registers instead of MMX for this in the future, but this should be good enough for now. Change-Id: If5abf747939022ef47daf7eb4badf1798e22bf95
* Add hw.gpu.enabled hardware propertyDavid 'Digit' Turner2011-08-293-0/+82
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds a new hardware property to enable GPU emulation (named hw.gpu.enabled). It is currently disabled by default. It also modifies the UI code to display the GL output properly inside the UI window. And sets the kernel parameter qemu.gles to either 0 or 1 to indicate to the guest system's GLES libraries whether to use GPU emulation or fallback to the software renderer. A future patch will also add auto-detection of desktop GL capabilities. For example, if the emulator is started on a headless server without an X11/GL display, hw.gpu.enabled will be forced to 'no', forcing the guest to use the software renderer. Another patch will allow to change the property from the command-line for debugging purpose. NOTE: If you want to test GPU emulation, change the default value of the property in android/avd/hardware-properties.ini from 'no' to 'yes'. You will need to run a ToT master AOSP tree with the following pending patches applied: https://review.source.android.com/25797 https://review.source.android.com/25154 https://review.source.android.com/25759 Change-Id: I1fa3512be24395244fd5068f2bf59ad54db5c7d5
* Revert "Revert "Merge c80340 from master to r13: Move charmap to hardware ↵Xavier Ducrohet2011-08-222-26/+9
| | | | | | | | | | | | | properties"..." This reverts commit cccd28ca5064a7bd14282cd774ee5bb7126d5845. c80340 add a CL to tools_r13 that broken the build. It was therefore reverted with cccd28. This revert was merged into tools_r13 but shouldn't have been. This reverts the revert to put back the CL in master. Change-Id: I95fcefedb77596cfdf76269f248b2ae80c85c830
* merge from tools_r13The Android Open-Source Project2011-08-112-9/+26
|\ | | | | | | Change-Id: Iabd0b49a5c3ad991da1b4f636ecdf881b1c271aa
| * Revert "Merge c80340 from master to r13: Move charmap to hardware ↵Xavier Ducrohet2011-08-112-9/+26
| | | | | | | | | | | | | | | | properties". do not merge. This reverts commit f490aee025b3bab5bcdb065e5fc1b1abecf16b97. Change-Id: I59a0b2aebc8ab2b788a820a206c6eb4fc6e6e6d2
| * Merge c80340 from master to r13: Move charmap to hardware propertiesDavid 'Digit' Turner2011-08-052-26/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The name of the emulated charmap must be passed to the guest kernel because it is used by the guest input handling code to load the proper charmap files from the system partition. This mandates that the name becomes a hardware property for the sake of supporting proper snapshotting and ui/core separation. From now on, the charmap name found in a skin will be ignored completely. This shouldn't be a problem in practice because all skins used the default name (qwerty2) anyway. The only reason to change the default value would be if emulating a guest system image that depends on a different charmap during emulation. Change-Id: If571684000b159ae9e9849661c9ff18e19b4cc75
| * merge 62ffc42 from master to r13: Added GTV related keysMaciek Molerus2011-08-053-9/+51
| | | | | | | | | | | | | | | | Adds the definitions for keys present in GoogleTV. Standard linux definitions are used to send notifications to emulated system. Change-Id: Iafb84b68a270b6566361d1822b8e1098ee870280
| * Fix window scaling issue.David 'Digit' Turner2011-08-041-6/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a back-port from master to tools_r13 This patch fixes a bug in the MMX scaling code. The MMX state was not properly empties when we started the scaling functions. The end result was that, if the hardware FPU was in a certain state, rendering would be be erratic. Fixes http://code.google.com/p/android/issues/detail?id=18299 This bug was hard to reproduce, but the fact that it never happens when building a debug version (with -O0) of the emulator indicated a problem in the generated instruction stream. Glad this isn't a compiler error though :) Change-Id: I19d3b35215120b41d92c85473e419b624ffa0f5f Orig-Change-Id: Icea04a7152b8fa5d81cb70cc215c0cd95aed2142
| * Auto-adjust scale and window position when needed.David 'Digit' Turner2011-08-042-7/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a backport from master to tools_r13 This patch changes the emulator's default behaviour in two ways: - Automatically compute the window scale to ensure that the emulator's window can be displayed within the current screen. This ensures that it remains usable when emulating a large-resolution device on a small display (e.g. on a 13" laptop running at 1024x768). This check and auto-correction do not happen if you use the -scale or -dpi-monitor options. - When re-centering an out-of-focus window, ensure that the top of the window is visible (which generally includes the window's title bar). This allows the window to be easily moved or minimized by the user is needed. This fixes three bugs: http://code.google.com/p/android/issues/detail?id=16399 http://code.google.com/p/android/issues/detail?id=16398 http://code.google.com/p/android/issues/detail?id=16397 Change-Id: Ibbc3c8458bd99718e4902d0a032b154c7cff4757 Orig-Change-Id: I8e5a624446d064038b5b9ad16556db8328244906
* | Added GTV related keysMaciek Molerus2011-07-123-9/+51
| | | | | | | | | | | | | | | | Adds the definitions for keys present in GoogleTV. Standard linux definitions are used to send notifications to emulated system. Change-Id: Id87aebfc86c5ce8b7331314352f2640a00ef36ae
* | Fix window scaling issue.David 'Digit' Turner2011-07-081-6/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes a bug in the MMX scaling code. The MMX state was not properly empties when we started the scaling functions. The end result was that, if the hardware FPU was in a certain state, rendering would be be erratic. Fixes http://code.google.com/p/android/issues/detail?id=18299 This bug was hard to reproduce, but the fact that it never happens when building a debug version (with -O0) of the emulator indicated a problem in the generated instruction stream. Glad this isn't a compiler error though :) Change-Id: Icea04a7152b8fa5d81cb70cc215c0cd95aed2142
* | Move charmap to hardware propertiesDavid 'Digit' Turner2011-07-072-26/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The name of the emulated charmap must be passed to the guest kernel because it is used by the guest input handling code to load the proper charmap files from the system partition. This mandates that the name becomes a hardware property for the sake of supporting proper snapshotting and ui/core separation. From now on, the charmap name found in a skin will be ignored completely. This shouldn't be a problem in practice because all skins used the default name (qwerty2) anyway. The only reason to change the default value would be if emulating a guest system image that depends on a different charmap during emulation. Change-Id: If571684000b159ae9e9849661c9ff18e19b4cc75
* | Fix -audio <name> and -no-audio processing.David 'Digit' Turner2011-06-271-6/+0
| | | | | | | | | | | | | | | | | | Turns out that the string passed to putenv() must not be modified :-/ We provide our own win32 implementation for emulator-ui that doesn't embed the os-win32.c QEMU-specific file. Change-Id: I7260fbc37d23a5340dab589dfde577ef5eb10005
* | Auto-adjust scale and window position when needed.David 'Digit' Turner2011-06-172-7/+59
|/ | | | | | | | | | | | | | | | | | | | | | | | | This patch changes the emulator's default behaviour in two ways: - Automatically compute the window scale to ensure that the emulator's window can be displayed within the current screen. This ensures that it remains usable when emulating a large-resolution device on a small display (e.g. on a 13" laptop running at 1024x768). This check and auto-correction do not happen if you use the -scale or -dpi-monitor options. - When re-centering an out-of-focus window, ensure that the top of the window is visible (which generally includes the window's title bar). This allows the window to be easily moved or minimized by the user is needed. This fixes three bugs: http://code.google.com/p/android/issues/detail?id=16399 http://code.google.com/p/android/issues/detail?id=16398 http://code.google.com/p/android/issues/detail?id=16397 Change-Id: I8e5a624446d064038b5b9ad16556db8328244906
* Enabled the camera button in the emulatorsoledad penades2011-02-191-0/+1
| | | | Change-Id: I1587d5e6ccc0bf092bb38b2c841eb19cb006f2e7
* Add hw.keyboard.lidDavid 'Digit' Turner2011-02-102-4/+17
| | | | | | | | | | | This is used to control the lid switch virtual device. + Add support for a "version <number>" field to the skin format. This will later be used for skin format #3. + Fix a bug where string hw properties didn't work/compile Change-Id: I678a0988d2cd24169dd0c2ece96e7ab0b2822104
* Move framebuffer.h to android/David 'Digit' Turner2011-02-022-2/+2
| | | | | | | The QFrameBuffer is no used by QEMU-specific code anymore so it's more logical to move it here. Change-Id: Id49ff53dd49648000e7543652d66f7c03881a8cb
* Refactored ui-core-control and core-ui-control protocolsVladimir Chtchetkine2011-01-281-3/+3
| | | | | | | Also cleaned the code up from obsolete ui-core-protocol.* and core-ui-protocol.* Change-Id: I194bec669d25b68a10c32b2be50bc9da50c52ebb
* Use setenv when availablerich cannings2011-01-251-1/+2
| | | | | | | | Even putenv("X=y") is bad because the "string becomes part of the environment; changing it later will change the environment." (http://www.kernel.org/doc/man-pages/online/pages/man3/putenv.3.html) Change-Id: I0d57204a7020649493fb005c962951407d40fa45
* Use putenv when setenv is unavailablerich cannings2011-01-251-2/+7
| | | | | | | Windows builds and possibly others do not have putenv. Using "#ifdef HAVE_SETENV" which is common in qemu. Change-Id: I2cd6770a77cd192440ff4dc6a624568eb27d5558
* putenv(3) misused. Corrected with setenv(3).rich cannings2011-01-241-3/+3
| | | | | | | | POS34-C. Do not call putenv() with a pointer to an automatic variable as the argument: Change-Id: I0c973edd2cc8d6c86287ec0258bca6a06f319bfb https://www.securecoding.cert.org/confluence/display/seccode/POS34-C.+Do+not+call+putenv()+with+a+pointer+to+an+automatic+variable+as+the+argument
* Make "qwerty2" the default charmap.David 'Digit' Turner2011-01-191-4/+5
| | | | | | | | | | | | | | | This patch makes "qwerty2" the default charmap for skins that don't specifiy one explicitely. Note that the "qwerty" charmap is here for historical reasons only. All skins provided by all SDK Android platforms explicitely mention "qwerty2", so this patch will mainly impact "magic skins" like those created by an option like "-skin 1024x768". This gets rid of the obsolete "qwerty" charmap (it was never used by any of the skins provided by the SDK, and is incorrect). + Simplify android/charmap.[hc] code. + Lazy-load the charmap name in hw/goldfish_events_device.c
* Sligh speedup for pixel conversion routines with Duff's device.David 'Digit' Turner2011-01-181-28/+31
| | | | Change-Id: If832bc5844945f7a2027b2f8d09393586545d8d5
* Add support for 32-bit framebuffers.David 'Digit' Turner2011-01-183-89/+199
| | | | | | | | | | | | | | | This modifies the emulator so support 32-bit framebuffers. You can create such a frame-buffer using one of these methods: - Add a "bpp 32" line to the "display" element of your skin - Use the new 'magic' skin option format: e.g. -skin 320x480x32 Note that the result will be hideous since the kernel driver still thinks the hardware is only 16-bits. This will be addressed in a later patch to hw/goldfish_fb.c and to the kernel driver ($KERNEL/drivers/video/goldfishfb.c) Change-Id: I0fc700c4a4cb8521076605324e15ed34e5d01136
* Update android/utils/ with misc. new features.David 'Digit' Turner2010-11-171-2/+2
| | | | | | | | | | | | This introduces a few new features to android/utils/ that will be used in later patches. + <android/utils/assert.h> to handle assertions + <android/utils/vector.h> to handle dynamic arrays + <android/utils/reflist.h> slightly updated (more docs) + <android/utils/refset.h> implements a set of pointers Change-Id: Iebc14cfefd1c0e8aaecda9958a980d40f0be610a
* Fix incorrect orientation at boot.David 'Digit' Turner2010-10-201-8/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The goldfish kernel's event driver is very picky about the state of the virtual device it talks to. Essentially, it can only listen to h/w events if the corresponding IRQ is raised _after_ it has completed some initial setup. If the IRQ is raised before, the driver will refuse to listen to events, and any interaction becomes impossible. We changed the way our UI windows are built and managed previously, and this had the unfortunate effect of sending one h/w event too soon, which, in the old code, would raise the IRQ prematurely. This resulted in an input freeze. To work around this the UI code was modified to not send the initial h/w event, but this resulted in bad orientation of the home screen at the end of the boot sequence. This change allows the virtual device to wait for the kernel driver before raising the IRQ, in the case any h/w event has been buffered. It also removes the hack in the UI code, allowing the send of the initial h/w event at startup. BONUS MINOR CHANGES: EsounD probe: fix error message. console: fix compiler warnings libpng: proper handling of MMX support. android-configure.sh: fix --ignore-audio handling The option didn't do anything if the audio development packages are properly installed on the system. Change-Id: Ib134158873d5cb72290c9676d92d20233226c889
* emulator-ui: Remove dependencies from qemu sources.David 'Digit' Turner2010-10-191-6/+6
| | | | | | This change removes some QEMU-specifics that crept into the UI code. Change-Id: Ib1974dc64e54a35dc0cd01aec1eb547a9263a0c8
* Remove compiler warnings when building the emulator.David 'Digit' Turner2010-09-223-3/+4
| | | | | | | This forces -Wall during the build. Note that this patch doesn't remove all warnings, but most of the remaining ones are from upstream anyway. Change-Id: I8808d8495e99866e156ce5780d2e3c305eab491f
* Added qemu-android build target which will build bare (UI-stripped) emulatorVladimir Chtchetkine2010-07-271-3/+3
| | | | | | Also has some minor separation changes Change-Id: I367e26f691d4d77b43c59b090b01434133d33584
* Better separation of UI and Core sources for framebuffer emulation.David 'Digit' Turner2010-07-271-10/+12
| | | | | | + new document under docs/DISPLAY-STATE.TXT to explain what's happening. Change-Id: Ia0d233377266212da49af932c7528f46f5feb92d
* Move key event generation out of the UI realm into neutral space.Vladimir Chtchetkine2010-07-071-88/+11
| | | | | | | Abstracted keycode event array into keycode_array.[hc], Moved key to keycode translation into charmap.c Change-Id: I4de0c9853fa93d675895fc361e62ee36c1c0a652
* Add small user-event abstraction interface.David 'Digit' Turner2010-05-252-7/+8
| | | | | | | | | | | | | | | | Preparation for future UI frontend/backend separation. This is done to ensure that the code under android/skin/ does not depend on any QEMU-specific header. We achieve this by adding a new abstract header "user-events.h" and one QEMU-specific implementations for the functions defined here. This also modifies console.h and vl-android.c to make them closer to upstream (by removing Android-specific changes). + fix Makefile.android to always build SDL from sources in standalone mode. Change-Id: I0d152741e7bb2c9cd283f5c35bd054385c7c1eb3
* Upstream: HOST_WORDS_ALIGNED -> WORDS_ALIGNEDDavid 'Digit' Turner2010-05-101-2/+2
| | | | Change-Id: Ica9022695d83fb48a8c25fdb1e1f0dc1c63747ff
* Do not use qemu_malloc() to allocate arrays.David 'Digit' Turner2009-10-061-5/+8
| | | | | This function will call abort() for zero-sized arrays. This is stupid so use the Android-specific functions that return NULL instead.
* Implementation for dynamic charmap option in emulator.vchtchetkine2009-09-212-22/+37
| | | | | Created .kcm parser and added -charmap option to the emulator, so user can specify keyboard layout for emulator session.
* Allow skins to provide a "dpad-rotation" field for each layout.David 'Digit' Turner2009-09-194-2/+24
| | | | | | | | | | This is used to deal with the fact that the framework *always* assumes that the physical DPad is rotated in landscaped mode, while the default skin no longer does that. NOTE: tested on old skin files for backwards compatibility. (Upcoming skin fixes coming in another patch)
* Add our modified SDL sources under distrib/sdl-1.2.12David 'Digit' Turner2009-06-081-5/+11
| | | | | | Fix distrib/make-distrib.sh script to work with git Fix distrib/build-emulator.sh to accomodate for new SDL configure script Handle Tiger SDK usage in SDL configure script
* Allow emulator skins to provide a button for the "search" hardware scan-code.David 'Digit' Turner2009-05-261-0/+1
| | | | This is different from using the F5 default key-binding that generates the same thing.
* auto import from //branches/cupcake_rel/...@140373The Android Open Source Project2009-03-181-0/+6
|
* auto import from //branches/cupcake/...@137873The Android Open Source Project2009-03-112-155/+5
|
* auto import from //depot/cupcake/@135843The Android Open Source Project2009-03-0324-0/+16938
|
* auto import from //depot/cupcake/@135843The Android Open Source Project2009-03-0324-16938/+0
|
* auto import from //branches/cupcake/...@130745The Android Open Source Project2009-02-1024-0/+16938