Category Archives: Technology

Android Image Compression Using ImageZipper

How to Android Image Compression Using ImageZipper Library
How to Android Image Compression Using ImageZipper Library

We all know that good UI is important key factor for app success and for UI informative image is most important. But nowadays we don’t care about the size of that image which makes app bigger and bigger in size. ImageZipper is an image compression library which helps you to compress your images both in default and custom way. It allows you to control you the width, height, format, orientation and quality of Image. It ease out the task to send images to the server.

How to Android Image Compression Using ImageZipper Library?

How to Android Image Compression  Using ImageZipper Library

Gradle

Add this to your root build.gradle file:

allprojects {
repositories {

maven { url “https://jitpack.io” }
}
}

Default Compressor

File imageZipperFile=new ImageZipper(this).compressToFile(actualFile);

OK Now Get me Bitmap!!

Bitmap b=new ImageZipper(MainActivity.this).compressToBitmap(actualFile);

See full article here: ImageZipper – Android Image Compression Library

Get File from Clound Using FileStack File Picker in Android

FileStack Android allow your users to pull in their content from Dropbox, Facebook, and more!

FileStack Android : Amazing Cloud File Picker

It is an amazing cloud integrated file picker by which you got ability to integrate and allow your users to upload and download content from more than 20 cloud drives.

FileStack Android library provides an activity that your app can spawn that allows the user to open and save files.

FileStack Android Example
FileStack Android Example

How to use FileStack Android library:

For Gradle users:

compile ‘io.filepicker:filepicker-android:4.0.2’

By default the following services are available (meaning of keys in brackets is described below):

  • Gallery (GALLERY)
  • Camera (CAMERA)
  • Facebook (FACEBOOK)
  • Amazon Cloud Drive (CLOUDDRIVE)
  • Dropbox (DROPBOX)
  • Box (BOX)
  • Gmail (GMAIL)
  • Instagram (INSTAGRAM)
  • Flickr (FLICKR)
  • Picasa (PICASA)
  • Github (GITHUB)
  • Google Drive (GOOGLE_DRIVE)
  • Evernote (EVERNOTE)
  • OneDrive (SKYDRIVE)

See more here : FileStack Android : Amazing Cloud File Picker 

How to Add Uber Car Animation in Android? 

How to Add Uber Car Animation in Android
How to Add Uber Car Animation in Android

I found a question on Quora about How to add Uber car animation in Android application. I really like this question and found a solution which help you if want to do this in your application.

Solution is UberCarAnimation is an Android library which showing movement of car on map like in Uber.

  • Parse the “overview_polyline” from the JSON by providing the appropriate GET parameters. For eg:

https://maps.googleapis.com/maps/api/directions/json?” +
“mode=driving&”
+ “transit_routing_preference=less_driving&”
+ “origin=” + latitude + “,” + longitude + “&”
+ “destination=” + destination + “&”
+ “key=” + getResources().getString(R.string.google_directions_key)

  • Decode the polyline which will provide you with list of latitudes and longitudes that is List<LatLng> to be apt.
  • Create a value animator by providing the ofFloatValue, setting duration and adding update listener in Handler

ValueAnimator valueAnimator = ValueAnimator.ofFloat(0, 1);
valueAnimator.setDuration(3000);
valueAnimator.setInterpolator(new LinearInterpolator());
valueAnimator.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
@Override
public void onAnimationUpdate(ValueAnimator valueAnimator) {
//CODE
});

  • Finally set position of marker to the new position, also evaluating the bearing between the consecutive points so that it seems car is turning literally and finally update camera as:

marker.setPosition(newPos);
marker.setAnchor(0.5f, 0.5f);
marker.setRotation(getBearing(startPosition, newPos));
mMap.moveCamera(CameraUpdateFactory
.newCameraPosition
(new CameraPosition.Builder()
target(newPos)
.zoom(15.5f)
.build()));

 

See full article: Add Uber Car Animation Android

How to Add Material Shadow in Android?

Recently we discuss about Kotlin Native and daily used kotlin code, today we are going to discuss about Google’s Material Shadow library.

Add Material Shadow in Android

Material Shadow is a library for seamlessly integrating Material shadows. The library takes existing material shadows to next level by adding the following features :

  • Convex shadows : The shadows are not only rectangular or circular, they can take any convex shape depending on the view and its content.
  • Support for shadow offsets : The library allows developers to set X and Y offset for the shadows.
  • Support for shadow intensity : The library also has support for setting shadow intensity via shadowAlpha attribute.
  • Shadows for semi-transparent views : The library allows shadows for semi-transparent views.
  • Support for Async Shadow calculations : The library allows the operations to be async to avoid blocking the UI thread for long calculations.
  • Shadow animations : The library supports fade out animation for shadow.

How to use this library?

Just add the following dependency in your app’s build.gradle

dependencies {
compile ‘com.sdsmdg.harjot:materialshadows:1.2.5’
}

Example Usage 1 (Simple)

XML

<com.sdsmdg.harjot.materialshadows.MaterialShadowViewWrapper
android:layout_width=”match_parent”
android:layout_height=”match_parent”>

<ImageView
android:layout_width=”130dp”
android:layout_height=”130dp”
android:elevation=”5dp”
android:src=”@drawable/poly” />

</com.sdsmdg.harjot.materialshadows.MaterialShadowViewWrapper>

Result

Simple example of Material Shadow

See other example and full article here >> : Material Shadow for Android 

mPhone 8 Specification Features

specification of mPhone 8
specification of mPhone 8mPhone 8 with Deca core Specification and Features

The mPhone 8 renders 1920 x1080 in 441 PPI LG made FHD LTPS OGS multi-touch display. Hid with 2.5D AGC Dragontrail™. The quality and clarity of the display in any light condition is remarkable.

The 8MP selfie camera which possess improved low light imaging technology. Capable of capturing 84⁰ wide angle selfie which also shows the best performance in video calling.

mPhone 8 is fitted with a 21 MP Sony IMX318 F2.0 Sensor autofocus camera which gives excellent image quality even in low-lighting, the two-tone flash can create natural lighting which helps you to freeze the moments in its perfect meaning.

Before buying any mobile phone you should need to know about which type of Mobile Processors is best. It contain the MT6797 Deca core 2.3 GHz. (Helio X20) processor and ARM Mali-T880. This is a premium performance based 4G LTE. The Tri-Cluster CPU architecture reduces processor power consumption, saving up to 30% more power compared to existing smartphones.

Source: mPhone 8 Specification and Deca core Features » Tell Me How – A Place for Technology Geekier

iPhone 8 will come with Samasung oLED like display 

iPhone 8 will have Samasung oLED like display

Samsung is developing many next generation display technologies supported OLEDs. Samsung has been developing a folding OLED device for a protracted time – which can dramatically change the mobile device market because it may enable smartphone to turn into tablets or phones that may be folded into smaller devices.

But Samsung display can doubtless not be the only supplier of OLED screens going forward, as several other screen manufacturers are adapting their production lines to deal with Apple’s iPhone needs — and Apple isn’t aiming to be the only smartphone maker which will want lots of OLED screens in the future.

Source: iPhone 8 will have Samasung oLED like display » Tell Me How – A Place for Technology Geekier

Create First Android Kotlin application

Welcome to this series of articles where we are going to learn Kotlin, a new JVM language, while developing an Android App. I hope it will help you to learn this incredible language in the context of Android. This stories will be separated in different Parts. In the Content section you will have the different Parts and the main topics that are going to be discussing there, each Part will include different Kotlin features.

How to make Reddit like Android Kotlin app

My intention is not to create the best App in the world (I can’t do that hahah) but I’ll try to explain Kotlin and it’s main features while developing this app.

Libraries that we are going to use:

  • Retrofit 2.0: To consume public Reddit API.
  • RxJava: We will use Observables to decouple the UI thread with our background tasks. In this case to call the API and return this values to the UI.
  • Picasso: Load images from Reddit.
  • RecyclerView: We will use the RecyclerView to present the information and also to provide the infinite scroll behaviour.
  • Kotlin Android Extensions: to bind the UI (Views) with code.
  • Dagger 2: Dependency Injection

Source: How to Create Reddit like Android Kotlin app