Android Fading (Circle/ Custom Corner) Image

Overview

Android Fading (Circle/ Custom Corner) Image

Implementation

add maven { url 'https://jitpack.io' } to build.gradle in your project:

allprojects {
    repositories {
		...
        maven { url 'https://jitpack.io' }
    }
}

and in your app.gradle:

dependencies {
	...
	implementation 'com.github.aghiadodeh:xfadingimage:1.0.1'
}

in your_activity.xml

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical"
    android:gravity="center"
    tools:context=".MainActivity">

    <com.aghiadodeh.xfadingimage.FadingImage
        android:id="@+id/fadingImage"
        android:layout_width="120dp"
        android:layout_height="120dp"
        android:layout_margin="10dp"
    />

    <com.aghiadodeh.xfadingimage.CircleImage
        android:id="@+id/circleImage"
        android:layout_width="120dp"
        android:layout_height="120dp"
        app:border="true"
        app:border_color="@android:color/black"
        app:border_width="1dp"
        android:layout_margin="10dp"/>

    <com.aghiadodeh.xfadingimage.CornerImageView
        android:id="@+id/cornerImage"
        android:layout_width="120dp"
        android:layout_height="120dp"
        app:image_corner_radius="10dp"
        android:layout_margin="10dp"/>

</LinearLayout>

in YourActivity.kt:

val fadingImage: FadingImage = findViewById(R.id.fadingImage)
val circleImage: CircleImage = findViewById(R.id.circleImage)
val cornerImage: CornerImageView = findViewById(R.id.cornerImage)

val imageUrl = "https://images.pexels.com/photos/5595490/pexels-photo-5595490.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500"
val videoUrl = "https://player.vimeo.com/external/387242416.sd.mp4?s=57e2d102f99b0c27b03d4db5fe9ca903b5646d41&profile_id=165&oauth2_token_id=57447761"
fadingImage.loadImage(url = imageUrl, duration = 500L, iFadeImage = { loaded ->
	// return boolean if image loaded successfully or not
})
/**
* load video Thumbnail
*/
// fadingImage.loadVideoThumbnail(url = videoUrl, duration = 1800L)

circleImage.loadImage(url = imageUrl, duration = 500L, iFadeImage = { loaded ->
	// return boolean if image loaded successfully or not
})

cornerImage.loadImage(url = imageUrl, duration = 500L, iFadeImage = { loaded ->
	// return boolean if image loaded successfully or not
})

set dark filter to image:

circleImage.darkenImage()

clear dark filter to image:

circleImage.defaultColorFilter()

Overview

You might also like...
Image loading library for Android

Image Loader Image loader library for Android. Deprecated. See Glide. Features Image transformations Automatic memory and storage caching Ability to l

Image Cropping Library for Android, optimised for Camera / Gallery.
Image Cropping Library for Android, optimised for Camera / Gallery.

Image Cropping Library for Android, optimised for Camera / Gallery.

An Android project containing image recognition and object detection models.
An Android project containing image recognition and object detection models.

An Android project containing image recognition and object detection models. Users can input images into the deep learning model by taking photos, opening photo albums, and real-time previews on the Android side. After the calculation on the Android side is completed, the model will output the prediction result and show it to the user.

An image loading library for android.

Bilder Download Add following to your project's build.gradle allprojects { repositories { ... maven { url 'https://jitpack.io' } } }

An Android transformation library providing a variety of image transformations for Coil, Glide, Picasso, and Fresco.
An Android transformation library providing a variety of image transformations for Coil, Glide, Picasso, and Fresco.

An Android transformation library providing a variety of image transformations for Coil, Glide, Picasso, and Fresco.

An image board client based on Gelbooru for android, made from Jetpack Compose šŸš€ .
An image board client based on Gelbooru for android, made from Jetpack Compose šŸš€ .

Mejiboard An image board client based on Gelbooru for android, made from Jetpack Compose šŸš€ . Features Material Design UI Easy one-handed operation Li

Image classifier app build in Android Studio.
Image classifier app build in Android Studio.

Android Image Classifier App Strongly based on https://github.com/microsoft/onnxruntime-inference-examples/tree/main/mobile/examples/image_classificat

šŸŽØ Modern image loading library for Android. Simple by design, powerful under the hood.
šŸŽØ Modern image loading library for Android. Simple by design, powerful under the hood.

Simple Image Loader Modern image loading library for Android. Simple by design, powerful under the hood. Kotlin: Simple Image Loader is Kotlin-native

Pixel Boom is a Java-based Android software, featuring image super-resolution and colorization

Pixel Boom is a Java-based Android software, featuring image super-resolution and colorization.

Releases(1.0.4)
Owner
Aghiad Odeh
- šŸ‘‹ Hi, Iā€™m @AghiadOdeh - šŸ‘€ Iā€™m interested in Android (Kotlin,Java and Flutter), Angular and NodeJS
Aghiad Odeh
This is an Image slider with swipes, Here we used Volley to Image load URL's from JSON! Here we make it very easy way to load images from Internet and We customized the description font style(OpenSans).

ImageSliderWithSwipes This is an Image slider with swipes, Here we used Volley to load URL's from JSON! Here we make it very easy way to load images f

Prabhakar Thota 44 May 31, 2021
Phimp.me Android Phimp.me is an Android image editor app

Phimp.me Android Phimp.me is an Android image editor app that aims to replace proprietary photographing and image apps on smart phones. It offers feat

FOSSASIA 2.6k Jan 6, 2023
some android image filters

android-image-filter some android image filters in some filter, I use NDK to implement to make it more efficient Setup Install Android NDK and properl

RagnarokStack 643 Dec 27, 2022
An android image compression library.

Compressor Compressor is a lightweight and powerful android image compression library. Compressor will allow you to compress large photos into smaller

Zetra 6.7k Dec 31, 2022
Android widget for cropping and rotating an image.

Cropper The Cropper is an image cropping tool. It provides a way to set an image in XML and programmatically, and displays a resizable crop window on

Edmodo 2.9k Nov 14, 2022
A simple image cropping library for Android.

SimpleCropView The SimpleCropView is an image cropping library for Android. It simplifies your code for cropping image and provides an easily customiz

Issei Aoki 2.5k Dec 28, 2022
Customizable Android full screen image viewer for Fresco library supporting "pinch to zoom" and "swipe to dismiss" gestures. Made by Stfalcon

This project is no longer supported. If you're able to switch from Fresco to any other library that works with the Android's ImageView, please migrate

Stfalcon LLC 1.8k Dec 19, 2022
Dali is an image blur library for Android. It contains several modules for static blurring, live blurring and animations.

Dali Dali is an image blur library for Android. It is easy to use, fast and extensible. Dali contains several modules for either static blurring, live

Patrick Favre-Bulle 1k Dec 1, 2022
An image resizing library for Android

Resizer Inspired by zetbaitsu's Compressor, Resizer is a lightweight and easy-to-use Android library for image scaling. It allows you to resize an ima

Kakit Ho 426 Dec 22, 2022
Simple android image popup Library

Android Image Popup Show image as a popup on a click event or any event. Simply set the image as drawable and thats it!!!. And also you can set width,

Chathura Lakmal 64 Nov 15, 2022