Member-only story
Android: How to make a circular view as a thumbnail of OpenTok?
Because OpenTok using GLSurfaceView for a renderer, and with multi GLSurfaceView on screen, we must use .setZOrderOnTop(true); for all thumbnail function. That is the problem.
I tried with a circle drawable XML place at parent view as background, it does not work.
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="oval">
<solid
android:color="#666666"/>
<size
android:width="120dp"
android:height="120dp"/>
</shape>
I tried with customizing ViewGroup such as FrameLayout and it does not work also.
public class CircleFrameLayout extends FrameLayout {
private Path clippingPath;public CircleFrameLayout(Context context) {
this(context, null, 0, 0);
}public CircleFrameLayout(Context context, AttributeSet attrs) {
this(context, attrs, 0, 0);
}
public CircleFrameLayout(Context context, AttributeSet attrs, int defStyleAttr) {
this(context, attrs, defStyleAttr, 0);
}public CircleFrameLayout(Context context, AttributeSet attrs, int…