A Deep Look Into Camera API of Rhomobile

In this post, we will go through the available methods for Camera API in details using Rhodes. This post will just explain the methods and uses of the Camera API from ruby excluding the rho-element javascript API.

Camera Permission:
In order to use the device camera, we need to get the permission by defining the capabilities in build.yml file.

Continue reading

Advertisements

Capturing Image Using Camera API & Uploading it to Server

In this post, we will see how to capture the image using Camera API and store it to app base path so as to gain permission to later upload it to server. We will see the way to store the details of the image on the rhom ( SQLite database ), then later upload the file to server on the time of sync process.

Capturing Image Using Device Camera:
As described on the previous post, A Deep Look into Camera API of Rhomobile, we need to use take picture method to capture the photo.

Continue reading

Capture specific UI element from the screen at anytime with Corona

Introduction:
In my last blog ( Capture whole screen at any time with Corona ) I have explained you that how easily we can take screenshot of the screen of our app using corona. So today I am going to explain you that how can corona can be useful to take a picture of specific display object.

Description:
As we already know that the ‘display’ API can be used to capture any screen, in similar way display library has funcion called ‘capture’ used to take the picture of a pointed UI element.

So let’s have a screen where we will have few UI elements and then we will capture one of the display object present on screen.

Continue reading

Capture whole screen at any time with Corona

Introduction:
Think of a scenario where you are in certain position of a game level where you need to save the screenshot of that instance and probably you can share them later to your social network. So don’t worry more. Using Corona with few simple steps you can implement this feature to you application

Description:
Corona provides several API which makes your life easy while developing your application. ‘Display’ is the one of the API which generally called to populate UI element on the screen but it also have some function which can be called to capture the screen.
Continue reading