145 Commits

Author SHA1 Message Date
iwg..ic
044d81f7e8 Add calls to loseFocus and gainFocus when activity pauses and resumes
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@10048 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-12-28 04:47:50 +00:00
iwg..ic
1df4fe8346 Attempt to clean up some references to help with out of memory issues on second start of app on Android
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@10047 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-12-28 04:27:10 +00:00
iwg..ic
dd46be3688 Add support for multiple folder storage types for getStorageFolder
See forum post http://jmonkeyengine.org/groups/android/forum/topic/jmesystem-getstoragefolder-updates/

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@10020 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-12-05 00:59:52 +00:00
iwg..ic
200df1c84b androidInput.loadSettings was never called, so setting mouseEventsEnabled = false; in MainActivity had no effect.
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@10012 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-11-29 17:53:59 +00:00
Sha..rd
e9395812bc * Partial fix for issue 504 (Android renderer only)
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9990 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-11-10 22:03:37 +00:00
Sha..rd
9e03dba566 * Add checks for maximum texture resolution in all renderers
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9980 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-11-10 20:28:00 +00:00
Sha..rd
4d01146519 * Add ImageRaster.getWidth() and getHeight()
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9874 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-10-21 21:56:22 +00:00
sky..ok
28ce76245f Change all source licenses to say 2009-2012
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9838 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-10-05 17:01:57 +00:00
sky..ok
751cb9e20a Javadoc cleanup
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9837 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-10-05 16:44:26 +00:00
iwg..ic
3afb803c68 Added check for sensor data accuracy to ignore data when sensor accuracy is unreliable.
Fixed error in log entry when sensor accuracy changes
Added log entry on calibration of axis

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9789 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-10-01 13:58:15 +00:00
iwg..ic
56bf97a7e2 Update Android Sensors to be compatible with the new Joystick interface. http://code.google.com/p/jmonkeyengine/source/detail?r=9763 http://code.google.com/p/jmonkeyengine/source/detail?r=9762
Only Orientation is supported currently

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9781 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-27 01:59:19 +00:00
PSp..om
bd2695061d Updates to build with latest joystick changes.
This breaks joysticks on android until they can be
ported to the "new way"... but at least it should build.


git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9763 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-23 09:01:02 +00:00
iwg..ic
47cb989c63 Added mapping of Android Scale Gesture (ie PinchZoom) to mouse wheel. If mouseEventsEnabled is set, mouse wheel reacts to the gesture.
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9758 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-22 03:44:17 +00:00
rem..om
5111fd8b66 Implemented fixedfunc binding for AlphaTestFallOff
- Made the relvent changes in lwjgl1Renderer
- Changed the check in the lwjglRenderer (note that it's deprecated in opengl 3)
- Removed the test in the OglESRenderer since GL_ALPHA_TEST/GL_ALPHA_FUNC no longer exists in OGLES 2, this must be handled in the fragment shader aka the alphaDiscardThreshold that is coming back in an upcoming commit.

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9747 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-17 19:36:41 +00:00
iwg..ic
5b326f4054 Minor reorganization of how appSettings are created and passed to the Context on Android.
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9745 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-16 22:00:27 +00:00
iwg..ic
fa6716877e Remove requirement for buffer type images to have width=height on Android devices that do not support NPOT. Now images allowed as long as both height and width are POT on devices that don't support NPOT.
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9744 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-16 20:58:09 +00:00
iwg..ic
d2b97fb422 Fix issue with onPause trying to cancel vibration when user has not defined Vibration Service permission in manifest.
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9716 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-11 03:30:18 +00:00
iwg..ic
5a71423624 Fix issue with BEST config not choosing a valid config on some devices when RGBA is not matched (ie no config exists with 0bit alpha). ConfigChooser now looks for an exact match of all attributes first, then a match of RGBA only, then uses the first available config.
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9715 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-11 01:07:25 +00:00
iwg..ic
3aa223360a Add check for no Vibration Service on Device
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9714 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-11 00:52:49 +00:00
Sha..rd
2a11aae3a4 * ImageRaster now supports Android. However the constructor can no longer be used. Instead user should create it by using ImageRaster.create() which automatically defers the handling to JmeSystem.
* TestImageRaster tests both reading and writing from various types of formats now by chaining the image conversions
 * 

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9710 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-09 23:39:45 +00:00
iwg..ic
5aca23f9b3 Changed Android Joystick Rumble to pulses. Rumble amount is used to determine length of vibration pulse. Vibration now stays on (pulsing based on rumble amount) until user sets joystick.rumble(0).
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9709 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-08 20:56:29 +00:00
iwg..ic
f219c8596d Added Rumble support for Android. If joystick.rumble is used, then the Manifest file must have <uses-permission android:name="android.permission.VIBRATE"/>. Since Android doesn't allow for changing the vibration intensity, the rumble amount is convert into a vibration time duration in milliseconds (ie rumble amount of 0.25 = 250 milliseconds).
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9708 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-08 14:23:51 +00:00
iwg..om
39f265f50e Adding Android Sensor support as simulated joysticks. Only orientation is supported right now, more sensor types to be added later. When device orientation changes, Joystick[0] is updated just like using an actual joystick. Users need to add "joystickEventsEnabled = true" to the MainActivity to enable the orientation joystick so battery life is conserved if sensor data is not desired. See http://jmonkeyengine.org/groups/android/forum/topic/creating-engine-support-for-android-sensor-input/ for the long history.
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9700 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-09-01 21:10:41 +00:00
nor..67
23e949974a - change default error message of engine
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9695 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-08-29 15:58:18 +00:00
pot..om
16851eb1d8 Removing Android Sensor Support (undo r9610). Preparing for new way of implementing sensor support on Android.
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9646 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-08-12 01:35:56 +00:00
Sha..rd
ac0f3a107c * Fix issue where setting texture on renderer with no mipmaps and then setting the same texture with mipmaps would prevent them from being generated (fixed for desktop GL1/GL2 and android)
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9617 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-08-04 23:17:29 +00:00
pot..om
bb631ab13a Adding support for defining external (or internal in Android's case) sensors. This is still a work in progress. Major task yet to complete is defining the coordinate system to return the sensor data. 3 sensor types are defined: Magnetic, Accelerometer, Orientation. Right now the sensor data is returned in device coordinates for Magnetic and Acceleration, and World (Earth) coordinates for Orientation. Sensors use the Input Manager to define triggers and listeners like all other input types. Only Android has an implementation for SensorInput at this time. See forum post http://jmonkeyengine.org/groups/android/forum/topic/creating-engine-support-for-android-sensor-input/ for details of the operation and current status.
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9610 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-08-04 01:55:37 +00:00
pot..om
48b40f4e3c Fixed issue where MOVE events were being generated even if the deltaX and deltaY were both 0. Now MOVE events with both deltaX and deltaY values of 0 will not be generated. See post http://jmonkeyengine.org/groups/android/forum/topic/differentiating-tap-from-a-quick-downmoveup/
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9596 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-07-28 23:11:47 +00:00
pot..om
242f5d82f9 Fixed issue with AndroidInput not resetting the last touch position correctly on the UP and DOWN actions. See forum post http://jmonkeyengine.org/groups/android/forum/topic/small-bug-in-androidinput/#post-183530
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9572 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-07-20 19:28:35 +00:00
Sha..rd
c7186886bc * OGLESShaderRenderer.readFrameBuffer() can now read from the main framebuffer in RGBA format.
* Add JmeSystem.writeImageFile() for a platform independent image writing method. Desktop and Android implementations are available.
 * ScreenshotAppState no longer depends on AWT or Desktop Java, instead it uses JmeSystem.writeImageFile() which will run on Android as well.


git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9571 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-07-20 01:06:15 +00:00
Sha..rd
55d75c5abc * Shader now stores shader language in the ShaderSources instead of the Shader itself (everything makes a lot more sense now).
^ Make sure your shader languages are appropriate for each shader type (vert / frag) in your J3MS!
 * Shaders no longer have the "usable" member and the renderers don't use it either (its useless)

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9545 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-07-10 03:53:53 +00:00
Sha..rd
af7435ffdf * jME3 now shows error dialog on exception by default (unless user overrides handleError)
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9544 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-07-10 03:49:05 +00:00
Sha..rd
cc3577acdc * Android renderer now supports configuration changes (see: http://jmonkeyengine.org/groups/android/forum/topic/supporting-device-configuration-changes/#post-181170)
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9543 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-07-10 03:46:44 +00:00
rem..om
4e987ae63e Android : Pixel Format again. Transparent or Translucent pixel format should not be the deault setting as they drain a substential amount of fps and that most of the games will have an opaque background.
There is now a new ogles configType called BEST_TRANSLUCENT if users really want a transparent background.
The BEST or FASTEST confing are now both OPAQUE, this gives a nice boost to the BEST configuration.

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9508 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-06-17 15:23:49 +00:00
rem..om
67712589e2 Android : changed the way the glsurface's pixel format was chosen, allowing the surface to have a translucent background
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9507 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-06-17 08:43:09 +00:00
nor..67
ea0be5cf9f - fix imports across engine
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9451 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-06-03 13:10:26 +00:00
Sha..om
3cdeb6ed4d * Fix issue 476
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9442 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-06-01 04:05:37 +00:00
rem..om
cd64f74898 - ANDROID fixed multitouch move taht was not sending additional pointers event. thanks to iwgeric
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9438 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-05-30 19:40:24 +00:00
rem..om
d76d58c0e9 - ANDROID audio renderer : added a state check on the MediaPlayer to prenvent it to throw errors
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9437 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-05-29 14:52:23 +00:00
rem..om
0fe3b69f7d - ANDROID Reverted a change in resolution setting, as it apparently has bad side effects on GUI
- Android texture util ENABLE_COMPRESSION is now public to be able to change it. Accessing it through the appSettings would be better.

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9436 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-05-29 14:50:18 +00:00
Sha..rd
1009cd18b0 * Running jME3-android in emulator with GPU emulation now supported but sometimes there are opengl errors (?)
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9428 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-05-25 04:25:44 +00:00
Sha..rd
c34189dfe5 * Removed all "verbose logging" parts of OGLESShaderRenderer, as it made the code hard to read. This sort of logging functionality should be done in a "GL Wrapper" sort of class instead.
* The AndroidImageInfo.notifyBitmapUploaded() method is now called at the end of the upload as expected 
 * Huge overhaul of TextureUtil. It automatically compresses textures to ETC1 if selected by user. In addition, it will use hardware mipmap generation if possible, and fallback to software if not (e.g. for compressed textures)
 * Add support for DXT1 format (usually supported on NVIDIA Tegra devices). The BrightSky.dds skybox now works on Android if the device supports it.

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9410 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-05-20 22:11:59 +00:00
Sha..rd
4be1d2be1e * AndroidImageInfo now supports getting notification when the bitmap has been successfully uploaded to GL
* AndroidAudioRenderer no longer prints silly debug messages

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9409 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-05-20 19:56:39 +00:00
Sha..rd
29b2596359 * Removed various misc handling code from AndroidHarness to OGLESContext/JmeAndroidSystem to ease using jME3 outside of AndroidHarness
* Misc formatting changes in AndroidConfigChooser
 * AndroidLogHandler now takes parameters into account
 * Added additional settings in AppSettings to configure mouse emulation
 * JmeSystem will now automatically try to load JmeAndroidSystem if it fails to load JmeDesktopSystem

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9407 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-05-20 19:53:13 +00:00
Sha..rd
05d5c611e1 * AndroidAssetManager no longer fails on missing plugin classes
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9406 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-05-20 19:49:36 +00:00
sky..ok
a625e8ae2a Javadoc fixes R PHUN
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9358 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-05-08 15:11:38 +00:00
rem..om
1c92f500eb AndroidAudioRenderer : propperly set the looping value on media player
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9323 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-04-19 16:09:18 +00:00
Sha..rd
f68475319a * Added new image format: Depth24Stencil8, for framebuffers and textures that need stencil data
* Renderer now uses getArray() to access mesh's buffers
 * GL image format data now stored in a special data structure for easier management (instead of huge switch/case statement)
 * Android texture loading: If the format is not supported by GLES spec, the texture upload will fail

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9298 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-04-14 19:26:22 +00:00
Sha..rd
cf9d5b5ebc * Remove some useless files
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9297 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-04-14 19:21:41 +00:00
rem..om
2966b6a7b0 AndroidAudioRenderer : better mediaplayer life cycle handling
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9296 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
2012-04-14 13:15:39 +00:00