Posts

Showing posts with the label Android

Download Android SDK standalone for offline installation

Update :- SDK for Android version (6.0) added ! How to install Android SDK without internet connection I searched all over the internet and found no posts like this, hence I'm making one hoping it would be helpful for a lot of people. The magic URL used to be  - http://dl-ssl.google.com/android/repository/repository.xml  (Outdated) That is the XML file from which the URL for downloading the SDK packages are obtained. Update :- The previous URL is now invalid, the new URL is given below https://dl-ssl.google.com/android/repository/repository-5.xml  (Outdated) Update 4  :- New URL https://dl-ssl.google.com/android/repository/repository-10.xml  (thanks topcoder from comments) Update 5  :- New URL https://dl-ssl.google.com/android/repository/repository-12.xml For e.g. if you want to download Android SDK for version 4.0.3 for all platforms, you could look up that XML file. You will find a block under tag SDK 4.0.3 like this <sdk:arch...

Android keyCodes list

a - z 29 - 54 "0" - "9" 7 - 16 BACK BUTTON - 4 MENU BUTTON - 82 UP, DOWN, LEFT, RIGHT 19, 20, 21, 22 SELECT (MIDDLE) BUTTON - 23 SPACE - 62 SHIFT - 59 ENTER - 66 BACKSPACE - 67

How to take Screenshot in Android Emulator with Eclipse

Image
I used to use PrintScreen > MSPAINT > Ctrl+V combination to capture screen of Android Emulator. Recently discovered that we can get a neat screen shot inside Eclipse using the Devices View. If the Devices panel is not visible, on the menu bar click Window > Show View > Other. In the newly opened dialog box, under Android category, select Devices. Now on the Devices panel, Click the button as shown in the Image and your screenshot is ready. tags:- android screen capture, android screenshot, android emulator screenshot .

How to load a texture in Android OpenGL ES

Here is how you can easily load a texture from any image format - PNG, BMP, JPG etc.. in OpenGL ES in Android. **Before you begin the code, you need to import your images into your project's /res/drawable/ folder. Just right click the project in eclipse and select import to do that.** //First setup the integer array to hold texture numbers which OpenGL generates int texture[] = new int[1]; //Generate and bind to the texture (gl is my GL10 object) gl.glGenTextures(1, texture, 0); gl.glBindTexture(GL10.GL_TEXTURE_2D, texture[0]); //Setup the texture co-ordinates float texCoords[] = { 0.0f, 0.0f, 1.0f, 0.0f,.......}; FloatBuffer texcoords = FloatBuffer.wrap(texCoords); gl.glTexCoordPointer(2, GL10.GL_FLOAT, 0, texcoords); Bitmap wood = BitmapFactory.decodeResource(this.getContext().getResources(), R.drawable.myimagefilenamewithoutextension); //Setup optional texture parameters gl.gl...