Android - View
Introduction
We provide two most important classes for layout: SurfaceViewRender
which is a View used for image output and PercentFrameLayout
which helps to efficiently lay out SurfaceViewRender
in RelativeLayout
. Given these classes, SurfaceViewRender
is the most important; therefore, let's first look at it.
SurfaceViewRender
Basic
You can use SurfaceViewRender
by placing it in the layout in your Android layout file like this:
Then, the object of this View is obtained in a specific Activity as follows.
You are now ready to use this View. If you set these two pairs of Views in the Config
object when you create an object of class Remon
, the communication will start and the camera or remote video stream will be output to the View.
Advenced
Let\'s look at some SurfaceViewRender
methods.
You can set the Z-Order between views. That is, set a view above other views. If there are overlapping views, the other views should be false
and only the view should be set to true
.
You can show the image of the view in a mirror-effect manner.
Determines how to fill the layout.
PercentFrameLayout
RemoteMonster Android SDK provides PercentFrameLayout
for easy layout of video views. PercentFrameLayout
allows you to freely position and dynamically move video views within RelativeLayout
. PercentFrameLayout
places the views in the layout in a percentage manner.
Places the layout with 100% width and height on relativeLayout.
Divide relativeLayout into four quarters and place the layout to take 50% of the available space in the bottom left corner.
Last updated