I want to know how to make the edges of a view to be rounded, not just setting the background image with a rounded corner rectangle. Everywhere I looked, I could only find information creating the rounded corner BG image.
Specifically, I have a Google Maps fragment inside a RelativeLayout, and I want Google Maps to have rounded edges:
<RelativeLayout
            android:layout_width="match_parent"
            android:layout_height="120dp"
            android:id="@+id/puInfoGoogleMapLayout"
            android:animateLayoutChanges="true">
            <fragment xmlns:android="http://schemas.android.com/apk/res/android"
                android:name="com.google.android.gms.maps.MapFragment"
                android:id="@+id/map"
                android:layout_width="match_parent"
                android:layout_height="match_parent"/>
        </RelativeLayout>
Obviously, setting a rounded corner BG image wouldn't work. On iOS, I could do it by setting view.layer.cornerRadius = 10 and view.layer.masksToBound = YES. How do I do it in Android?
 
     
    