com.aliyun.svideosdk.common.struct.common

## Class AliyunSnapVideoParam

- java.lang.Object
- - com.aliyun.svideosdk.common.struct.common.AliyunSnapVideoParam

-     public class AliyunSnapVideoParam
      extends java.lang.Object

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `AliyunSnapVideoParam.Builder`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static java.lang.String` | `BEAUTY_LEVEL`
    `static java.lang.String` | `BEAUTY_STATUS`
    `static java.lang.String` | `CAMERA_TYPE`
    `static java.lang.String` | `CROP_MODE`
    `static java.lang.String` | `CROP_USE_GPU`
    `static java.lang.String` | `FILTER_LIST`
    `static java.lang.String` | `FLASH_TYPE`
    `static java.lang.String` | `MAX_DURATION`
    `static java.lang.String` | `MAX_VIDEO_DURATION`
    `static java.lang.String` | `MIN_CROP_DURATION`
    `static java.lang.String` | `MIN_DURATION`
    `static java.lang.String` | `MIN_VIDEO_DURATION`
    `static java.lang.String` | `NEED_CLIP`
    `static java.lang.String` | `NEED_RECORD`
    `static int` | `RATIO_MODE_1_1` 宽高比为1：1
    `static int` | `RATIO_MODE_3_4` 宽高比为3：4
    `static int` | `RATIO_MODE_9_16` 宽高比为9：16
    `static java.lang.String` | `RECORD_MODE`
    `static int` | `RECORD_MODE_AUTO` `RECORD_MODE_PRESS`和`RECORD_MODE_TOUCH`两种都支持
    `static int` | `RECORD_MODE_PRESS` 按压录制，即按住时录制，松手停止录制
    `static int` | `RECORD_MODE_TOUCH` 按下录制，再次按下停止录制。
    `static int` | `RESOLUTION_360P`
    `static int` | `RESOLUTION_480P`
    `static int` | `RESOLUTION_540P`
    `static int` | `RESOLUTION_720P`
    `static VideoDisplayMode` | `SCALE_CROP`
    `static VideoDisplayMode` | `SCALE_FILL`
    `static java.lang.String` | `SORT_MODE`
    `static int` | `SORT_MODE_MERGE` 照片和视频混合显示
    `static int` | `SORT_MODE_PHOTO` 只显示照片
    `static int` | `SORT_MODE_VIDEO` 只显示视频
    `static java.lang.String` | `VIDEO_BITRATE`
    `static java.lang.String` | `VIDEO_CODEC`
    `static java.lang.String` | `VIDEO_FRAMERATE`
    `static java.lang.String` | `VIDEO_GOP`
    `static java.lang.String` | `VIDEO_QUALITY`
    `static java.lang.String` | `VIDEO_RATIO`
    `static java.lang.String` | `VIDEO_RESOLUTION`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `AliyunSnapVideoParam()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `getBeautyLevel()`
    `boolean` | `getBeautyStatus()`
    `CameraType` | `getCameraType()` 获取摄像头类型
    `java.lang.String[]` | `getFilterList()`
    `FlashType` | `getFlashType()` 获取闪光灯类型
    `int` | `getFrameRate()`
    `int` | `getGop()`
    `int` | `getMaxDuration()`
    `int` | `getMaxVideoDuration()`
    `int` | `getMinCropDuration()`
    `int` | `getMinDuration()`
    `int` | `getMinVideoDuration()`
    `int` | `getRatioMode()`
    `int` | `getRecordMode()`
    `int` | `getResolutionMode()`
    `VideoDisplayMode` | `getScaleMode()`
    `int` | `getSortMode()`
    `int` | `getVideoBitrate()`
    `VideoCodecs` | `getVideoCodec()`
    `VideoQuality` | `getVideoQuality()`
    `boolean` | `isCropUseGPU()`
    `boolean` | `isNeedClip()`
    `boolean` | `isNeedRecord()`
    `void` | `setBeautyLevel(int mBeautyLevel)` 设置美颜级别
    `void` | `setBeautyStatus(boolean mBeautyStatus)` 设置美颜开关
    `void` | `setCameraType(CameraType mCameraType)`
    `void` | `setCropUseGPU(boolean isUseGPU)` 设置裁剪使用GPU
    `void` | `setFilterList(java.lang.String[] mFilterList)` 设置滤镜资源列表
    `void` | `setFlashType(FlashType mFlashType)` 设置闪光灯类型
    `void` | `setFrameRate(int mFrameRate)` 设置帧率
    `void` | `setGop(int mGop)` 设置Gop大小，单位是帧数
    `void` | `setMaxDuration(int mMaxDuration)` 设置录制的最大时长
    `void` | `setMaxVideoDuration(int mMaxVideoDuration)` 设置视频选择界面过滤视频的最大时长
    `void` | `setMinCropDuration(int mMinCropDuration)` 设置视频裁剪的最小时长，裁剪界面选取裁剪时间段无法比这个时长小
    `void` | `setMinDuration(int mMinDuration)` 设置录制的最小时长，小于这个时长视频会被丢弃。
    `void` | `setMinVideoDuration(int mMinVideoDuration)` 设置视频选择页面过滤视频的最小时长
    `void` | `setNeedClip(boolean mNeedClip)` 是否多段录制
    `void` | `setNeedRecord(boolean mNeedClip)` 视频选择界面是否需要"录制"的入口
    `void` | `setRatioMode(int mRatioMode)` 设置分辨率宽高比，最终的分辨率由该值和`setResolutionMode(int)`的值一起计算出。
    `void` | `setRecordMode(int mRecordMode)` 设置录制模式
    `void` | `setResolutionMode(int mResolutionMode)` 设置分辨率基数，支持四种分辨率基数，最终的分辨率是由该基数跟`setRatioMode(int)`的值一起计算出来的
    `void` | `setScaleMode(VideoDisplayMode mCropMode)` 设置视频裁剪缩放模式
    `void` | `setSortMode(int sortMode)` 设置媒体文件选择界面的过滤模式
    `void` | `setVideoBitrate(int bitrate)` 设置bitrate大小，单位是kps
    `void` | `setVideoCodec(VideoCodecs codec)` 设置编码方式
    `void` | `setVideoQuality(VideoQuality mVideoQuality)` 设置输出视频质量

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### CROP_MODE

          public static final java.lang.String CROP_MODE

      See Also:
        Constant Field Values

    - #### VIDEO_FRAMERATE

          public static final java.lang.String VIDEO_FRAMERATE

      See Also:
        Constant Field Values

    - #### VIDEO_GOP

          public static final java.lang.String VIDEO_GOP

      See Also:
        Constant Field Values

    - #### VIDEO_BITRATE

          public static final java.lang.String VIDEO_BITRATE

      See Also:
        Constant Field Values

    - #### NEED_RECORD

          public static final java.lang.String NEED_RECORD

      See Also:
        Constant Field Values

    - #### MAX_VIDEO_DURATION

          public static final java.lang.String MAX_VIDEO_DURATION

      See Also:
        Constant Field Values

    - #### MIN_VIDEO_DURATION

          public static final java.lang.String MIN_VIDEO_DURATION

      See Also:
        Constant Field Values

    - #### MIN_CROP_DURATION

          public static final java.lang.String MIN_CROP_DURATION

      See Also:
        Constant Field Values

    - #### VIDEO_RESOLUTION

          public static final java.lang.String VIDEO_RESOLUTION

      See Also:
        Constant Field Values

    - #### MIN_DURATION

          public static final java.lang.String MIN_DURATION

      See Also:
        Constant Field Values

    - #### MAX_DURATION

          public static final java.lang.String MAX_DURATION

      See Also:
        Constant Field Values

    - #### VIDEO_QUALITY

          public static final java.lang.String VIDEO_QUALITY

      See Also:
        Constant Field Values

    - #### VIDEO_RATIO

          public static final java.lang.String VIDEO_RATIO

      See Also:
        Constant Field Values

    - #### RECORD_MODE

          public static final java.lang.String RECORD_MODE

      See Also:
        Constant Field Values

    - #### FILTER_LIST

          public static final java.lang.String FILTER_LIST

      See Also:
        Constant Field Values

    - #### BEAUTY_STATUS

          public static final java.lang.String BEAUTY_STATUS

      See Also:
        Constant Field Values

    - #### BEAUTY_LEVEL

          public static final java.lang.String BEAUTY_LEVEL

      See Also:
        Constant Field Values

    - #### CAMERA_TYPE

          public static final java.lang.String CAMERA_TYPE

      See Also:
        Constant Field Values

    - #### FLASH_TYPE

          public static final java.lang.String FLASH_TYPE

      See Also:
        Constant Field Values

    - #### NEED_CLIP

          public static final java.lang.String NEED_CLIP

      See Also:
        Constant Field Values

    - #### SORT_MODE

          public static final java.lang.String SORT_MODE

      See Also:
        Constant Field Values

    - #### CROP_USE_GPU

          public static final java.lang.String CROP_USE_GPU

      See Also:
        Constant Field Values

    - #### VIDEO_CODEC

          public static final java.lang.String VIDEO_CODEC

      See Also:
        Constant Field Values

    - #### SCALE_CROP

          public static final VideoDisplayMode SCALE_CROP

    - #### SCALE_FILL

          public static final VideoDisplayMode SCALE_FILL

    - #### SORT_MODE_VIDEO

          public static final int SORT_MODE_VIDEO

      只显示视频
      See Also:
        Constant Field Values

    - #### SORT_MODE_PHOTO

          public static final int SORT_MODE_PHOTO

      只显示照片
      See Also:
        Constant Field Values

    - #### SORT_MODE_MERGE

          public static final int SORT_MODE_MERGE

      照片和视频混合显示
      See Also:
        Constant Field Values

    - #### RATIO_MODE_3_4

          public static final int RATIO_MODE_3_4

      宽高比为3：4
      See Also:
        Constant Field Values

    - #### RATIO_MODE_1_1

          public static final int RATIO_MODE_1_1

      宽高比为1：1
      See Also:
        Constant Field Values

    - #### RATIO_MODE_9_16

          public static final int RATIO_MODE_9_16

      宽高比为9：16
      See Also:
        Constant Field Values

    - #### RESOLUTION_360P

          public static final int RESOLUTION_360P

      See Also:
        Constant Field Values

    - #### RESOLUTION_480P

          public static final int RESOLUTION_480P

      See Also:
        Constant Field Values

    - #### RESOLUTION_540P

          public static final int RESOLUTION_540P

      See Also:
        Constant Field Values

    - #### RESOLUTION_720P

          public static final int RESOLUTION_720P

      See Also:
        Constant Field Values

    - #### RECORD_MODE_TOUCH

          public static final int RECORD_MODE_TOUCH

      按下录制，再次按下停止录制。
      See Also:
        Constant Field Values

    - #### RECORD_MODE_PRESS

          public static final int RECORD_MODE_PRESS

      按压录制，即按住时录制，松手停止录制
      See Also:
        Constant Field Values

    - #### RECORD_MODE_AUTO

          public static final int RECORD_MODE_AUTO

      `RECORD_MODE_PRESS`和`RECORD_MODE_TOUCH`两种都支持
      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### AliyunSnapVideoParam

          public AliyunSnapVideoParam()

  - ### Method Detail

    - #### getSortMode

          public int getSortMode()

    - #### setSortMode

          public void setSortMode(int sortMode)

      设置媒体文件选择界面的过滤模式
      Parameters:
        `sortMode` -
      See Also:
        `SORT_MODE_VIDEO`, `SORT_MODE_PHOTO`, `SORT_MODE_MERGE`

    - #### setCropUseGPU

          public void setCropUseGPU(boolean isUseGPU)

      设置裁剪使用GPU
      Parameters:
        `isUseGPU` - true：使用gpu， false：使用cpu

    - #### getRecordMode

          public int getRecordMode()

    - #### setRecordMode

          public void setRecordMode(int mRecordMode)

      设置录制模式
      Parameters:
        `mRecordMode` -
      See Also:
        `RECORD_MODE_PRESS`, `RECORD_MODE_TOUCH`, `RECORD_MODE_AUTO`

    - #### isNeedClip

          public boolean isNeedClip()

    - #### setNeedClip

          public void setNeedClip(boolean mNeedClip)

      是否多段录制
      Parameters:
        `mNeedClip` - true：多段录制，false：单段录制

    - #### getBeautyStatus

          public boolean getBeautyStatus()

    - #### setBeautyStatus

          public void setBeautyStatus(boolean mBeautyStatus)

      设置美颜开关
      Parameters:
        `mBeautyStatus` - true：开， false：关

    - #### getFilterList

          public java.lang.String[] getFilterList()

    - #### setFilterList

          public void setFilterList(java.lang.String[] mFilterList)

      设置滤镜资源列表
      Parameters:
        `mFilterList` -

    - #### getBeautyLevel

          public int getBeautyLevel()

    - #### getCameraType

          public CameraType getCameraType()

      获取摄像头类型
      Returns:
        摄像头类型
      See Also:
        `CameraType`

    - #### setCameraType

          public void setCameraType(CameraType mCameraType)

    - #### getFlashType

          public FlashType getFlashType()

      获取闪光灯类型
      Returns:
        闪光灯类型
      See Also:
        `FlashType`

    - #### setFlashType

          public void setFlashType(FlashType mFlashType)

      设置闪光灯类型
      Parameters:
        `mFlashType` -

    - #### setBeautyLevel

          public void setBeautyLevel(int mBeautyLevel)

      设置美颜级别
      Parameters:
        `mBeautyLevel` - [0,100] 0表示关闭美颜

    - #### getMaxDuration

          public int getMaxDuration()

    - #### setMaxDuration

          public void setMaxDuration(int mMaxDuration)

      设置录制的最大时长
      Parameters:
        `mMaxDuration` -

    - #### getMinDuration

          public int getMinDuration()

    - #### setMinDuration

          public void setMinDuration(int mMinDuration)

      设置录制的最小时长，小于这个时长视频会被丢弃。
      Parameters:
        `mMinDuration` -

    - #### getMinVideoDuration

          public int getMinVideoDuration()

    - #### setMinVideoDuration

          public void setMinVideoDuration(int mMinVideoDuration)

      设置视频选择页面过滤视频的最小时长
      Parameters:
        `mMinVideoDuration` - 单位是毫秒

    - #### getMaxVideoDuration

          public int getMaxVideoDuration()

    - #### setMaxVideoDuration

          public void setMaxVideoDuration(int mMaxVideoDuration)

      设置视频选择界面过滤视频的最大时长
      Parameters:
        `mMaxVideoDuration` - 单位是毫秒

    - #### getMinCropDuration

          public int getMinCropDuration()

    - #### setMinCropDuration

          public void setMinCropDuration(int mMinCropDuration)

      设置视频裁剪的最小时长，裁剪界面选取裁剪时间段无法比这个时长小
      Parameters:
        `mMinCropDuration` - 单位是毫秒

    - #### isCropUseGPU

          public boolean isCropUseGPU()

    - #### getFrameRate

          public int getFrameRate()

    - #### setFrameRate

          public void setFrameRate(int mFrameRate)

      设置帧率
      Parameters:
        `mFrameRate` -

    - #### getScaleMode

          public VideoDisplayMode getScaleMode()

    - #### setScaleMode

          public void setScaleMode(VideoDisplayMode mCropMode)

      设置视频裁剪缩放模式
      Parameters:
        `mCropMode` -
      See Also:
        `VideoDisplayMode`

    - #### getResolutionMode

          public int getResolutionMode()

    - #### setResolutionMode

          public void setResolutionMode(int mResolutionMode)

      设置分辨率基数，支持四种分辨率基数，最终的分辨率是由该基数跟`setRatioMode(int)`的值一起计算出来的
      Parameters:
        `mResolutionMode` -
      See Also:
        `RESOLUTION_360P`, `RESOLUTION_480P`, `RESOLUTION_540P`, `RESOLUTION_720P`

    - #### getRatioMode

          public int getRatioMode()

    - #### setRatioMode

          public void setRatioMode(int mRatioMode)

      设置分辨率宽高比，最终的分辨率由该值和`setResolutionMode(int)`的值一起计算出。
      Parameters:
        `mRatioMode` -
      See Also:
        `RATIO_MODE_1_1`, `RATIO_MODE_3_4`, `RATIO_MODE_9_16`

    - #### isNeedRecord

          public boolean isNeedRecord()

    - #### setNeedRecord

          public void setNeedRecord(boolean mNeedClip)

      视频选择界面是否需要"录制"的入口
      Parameters:
        `mNeedClip` -

    - #### getVideoQuality

          public VideoQuality getVideoQuality()

    - #### setVideoQuality

          public void setVideoQuality(VideoQuality mVideoQuality)

      设置输出视频质量
      Parameters:
        `mVideoQuality` -
      See Also:
        `VideoQuality`

    - #### getGop

          public int getGop()

    - #### setGop

          public void setGop(int mGop)

      设置Gop大小，单位是帧数
      Parameters:
        `mGop` -

    - #### setVideoBitrate

          public void setVideoBitrate(int bitrate)

      设置bitrate大小，单位是kps
      Parameters:
        `bitrate` -

    - #### getVideoBitrate

          public int getVideoBitrate()

    - #### setVideoCodec

          public void setVideoCodec(VideoCodecs codec)

      设置编码方式
      Parameters:
        `codec` - 默认是硬编
      See Also:
        `VideoCodecs`

    - #### getVideoCodec

          public VideoCodecs getVideoCodec()