Posts

Photo Editor | Android Studio | Kotlin

Image
Image Editor | Android Studio | KotlinAndroid allows us to apply many kinds of effects on images. In this tutorial, we will apply some effects to an Image in the ImageView. We will apply the following effects to the image. GrayBrightDarkRed/GamaGreenBlue >>Watch For Java Step 1: Create a new project OR Open your existing projectStep 2: Place image in the drawable folderPlace any image (to apply the effects to it) in the drawable folder.

Step 3: Code activity_main.xml <?xml version="1.0" encoding="utf-8"?><RelativeLayoutxmlns:android="http://schemas.android.com/apk/res/android"xmlns:tools="http://schemas.android.com/tools"android:layout_width="match_parent"android:layout_height="match_parent"android:padding="10dp"tools:context=".MainActivity"><TextViewandroid:id="@+id/label1Tv"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_a…

Photo Editor | Android Studio | Java

Image
Image Editor | Android Studio | JavaAndroid allows us to apply many kinds of effects on images. In this tutorial, we will apply some effects to an Image in the ImageView. We will apply the following effects to the image. GrayBrightDarkRed/GamaGreenBlue >>Watch For Kotlin Step 1: Create a new projectOROpen your existing projectStep 2: Place image in the drawable folderPlace any image (to apply the effects to it) in the drawable folder.
Step 3: Code activity_main.xml <?xml version="1.0" encoding="utf-8"?><RelativeLayoutxmlns:android="http://schemas.android.com/apk/res/android"xmlns:tools="http://schemas.android.com/tools"android:layout_width="match_parent"android:layout_height="match_parent"android:padding="10dp"tools:context=".MainActivity"><TextViewandroid:id="@+id/label1Tv"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_ali…

Vibrate Phone | Android Studio | Java

Image
How to vibrate phone programmatically for a specific time? You can easily implement the phone vibrate programmatically using Android Vibrator API. In this example, we will vibrate the phone for 1000 microseconds i.e. 1 second by clicking a button you can change the duration according to your requirements. >>Watch For Kotlin Step 1: Create a new projectOROpen your existing project Step 2: CodeOpen AndroidManifest and add VIBRATE permission.

AndroidManifest <?xml version="1.0" encoding="utf-8"?><manifestxmlns:android="http://schemas.android.com/apk/res/android"package="com.blogspot.atifsoftwares.vibratephone"><!--VIBRATE permission--><uses-permissionandroid:name="android.permission.VIBRATE"/><applicationandroid:allowBackup="true"android:icon="@mipmap/ic_launcher"android:label="@string/app_name"android:roundIcon="@mipmap/ic_launcher_round"android:supportsRtl="true&…