<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:padding="20dp">

    <com.google.android.exoplayer2.ui.PlayerView
        android:id="@+id/video_view"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_gravity="center"
        app:auto_show="true"
        app:controller_layout_id="@layout/custom_exo_controller_view"
        app:repeat_toggle_modes="none"
        app:resize_mode="fixed_width"
        app:surface_type="surface_view"
        app:use_controller="true" />

</FrameLayout>