If you are an android developer, you must have faced the problem of slowing down or even crash of your app while implementing complex image processing operations? I faced the same and found RenderScripts as appropriate solution to it.
The RenderScript are used in android for complex computations such as image processing. The Scripts are based on the C99 standard of C language. RenderScripts was introduced in API 11 i.e. Honeycomb.
For accessing RenderScript in android there are two API’s
1. Android.renderscript :- from API 11(HoneyComb) to higher API’s.
2. Android.support.v8.renderscript :- from API 8(Froyo) to higher.
This is basically a kind of tutorial which will be useful if you are learning and implementing bluetooth in your android app. In this tutorial I have shared the code for scanning of the Classic Bluetooth devices in range and fetching the paired devices list, moreover I will find some time to write about the implementation of further aspects of classic bluetooth.
Android offers bluetooth API that lets you share your stuff wireless. As per Bluetooth standards it offers you short range (10 m approx.) device connectivity. This API let application to the Bluetooth devices and enable point to point or multipoint wireless feature. Here we are discussing about the Classic Bluetooth that consumes more battery life.
Bluetooth devices with low power requirement Android 4.3 (API level 18) introduces support for Bluetooth Low Energy, I have talked about it in my last blog. We will get to understand about the API by creating a sample application that lets you share you stuff over bluetooth.
To start with we will first find to check that whether our device support bluetooth or not. For this we need to use Bluetooth Adapter class. Bluetooth Adapter is some sort of entry – point for all bluetooth interaction.
Don’t you think Bluetooth plays a significant role in making the smart phones smart? So let’s talk about something smarter i.e. Bluetooth Smart or BLE. As far as the BLE or the Bluetooth low energy is concerned it is not just a feature it’s a new technology
it was first proposed by NOKIA in 2006 with the name WIBREE. And now the devices which are equipped with BLE are called as Bluetooth Smart devices and the devices which has both Bluetooth classic and the BLE are called as Bluetooth Smart Ready devices.
If you want some customization in the seekbar which you use while developing android apps, there are several ways of doing this. You can customize seek bar with the help of the xml or you can make it impressive even programmatically.
Let’s have a look if you want to change its appearance with the help of xml
First of all the progress Drawable attribute of the seekbar should be set as the xml file in the drawables folder as
In this post we will be talking about the most helpful feature provided by Android for a quick notification to user, i.e. Toasts “Small informative texts shown at bottom-center of device screen, for defined time duration”.
Default UI design of these toasts is a semi-transparent dark color background with white text over it, not even showing the name of application which spawned it, no so eye-catching, right? I know… So, let’s make a custom Toast Notification that complements our awesome UI…
How about creating a backup setting for an android application, so that when the application is uninstalled the personal settings it does not get erased permanently, instead the settings is stored on the cloud and the next time when you install the application it asks you to restore the settings. Interestingly, it can restore the settings when you install the application into other device too. It can be achieved through Backup API provided by Google. You will find it really interesting, easy and useful.
It’s not for the synchronizing of the data with other apps or storing the data which could further be used as in the case of SQLite . Also there is no method to access the backed up data other than the API and neither any way to make the Backup status known. This makes it easier to implement and lesser code it requires.
Android currently supports and provides helpers to backup and restore the complete data of the Shared Preferences or the internal storage if they are light weighted i.e. less than one megabyte.
For the implementation of Backup API the first and the foremost thing which has to be done is create the API key for your application by clicking on the link
ListView is an extensively used widget in Android Applications for displaying data in a structured way. To display custom made views as row elements, it is always preferred to associate Base Adapter with ListView. This is how a BaseAdapter can be used to show a list in which each element contains a text field and a checkbox: MainActivity.java
// Initialize the ListView and set its adapter. ListView listView = (ListView) findViewById(R.id.list_view); listView.setAdapter(new NormalListAdapter((Context) this));
This post is about how to capture pictures using camera with sensor event updates (Proximity Sensor). This is about the simplest implementation of device camera in integration to a particular type of sensor (Proximity sensor here).
This post is also defines how to create and set a transparent theme to the main activity ready to capture pictures on change of proximity sensor state. It also defines how to create a preview for camera resource occupying no space on the activity’s layout.
LibGdx a cross-platform game development framework and a best way for beginners who turned into game development. Using LibGdx one can build 2D or 3D games with little efforts only you need to be familiar with the basic programming language. There is a core project that needs to create on java and some little coding needs to make it executable in different platforms like desktop, Android,IOS Html5 etc. We will focus on to develop android games. I am going to start with the very basics step that needs to be setup before the coding part. And then we build some Demo Projects and try to get understand that how the whole code is working. To work on LibGdx you need to install Java JDK, Android SDK and Ecllipse. There is a TroubleFire section in the blog where you will find solutions of the troubles that might come during your work.
Download the Java Standard Edition JDK for windows platform after downloading execute the downloaded installer file (for example, jdk-7u11-windows-x64.exe) and follow the instructions on the screen. Setup the Environment variable path with your jdk path
Start->Right Click on Computers->properties->Advanced System Setting → Environment Variable
look out to system variable click on Path click to edit add your JDK directory path (like C:\Java\jdk1.7.0_11)