use of android.media.videoeditor.MediaVideoItem in project android_frameworks_base by ParanoidAndroid.
the class MediaPropertiesTest method testPropertiesMPEGNTSC.
/**
*To test media properties for MPEG4 720x480 (NTSC) + AAC file.
*/
@LargeTest
public void testPropertiesMPEGNTSC() throws Exception {
final String videoItemFilename = INPUT_FILE_PATH + "MPEG4_SP_720x480_30fps_280kbps_AACLC_48kHz_161kbps_s_0_26.mp4";
final int aspectRatio = MediaProperties.ASPECT_RATIO_3_2;
final int fileType = MediaProperties.FILE_MP4;
final int videoCodecType = MediaProperties.VCODEC_MPEG4;
final int duration = 26866;
final int videoBitrate = 403000;
final int audioBitrate = 160000;
final int fps = 30;
final int audioCodecType = MediaProperties.ACODEC_AAC_LC;
final int audioSamplingFrequency = 48000;
final int audioChannel = 2;
final int videoProfile = MediaProperties.MPEG4Profile.MPEG4ProfileSimple;
final int videoLevel = MediaProperties.MPEG4Level.MPEG4Level1;
final int width = 720;
final int height = MediaProperties.HEIGHT_480;
final int renderingMode = MediaItem.RENDERING_MODE_BLACK_BORDER;
final MediaVideoItem mvi = mVideoEditorHelper.createMediaItem(mVideoEditor, "m1", videoItemFilename, renderingMode);
validateVideoProperties(aspectRatio, fileType, videoCodecType, duration, videoBitrate, fps, videoProfile, videoLevel, width, height, audioCodecType, audioSamplingFrequency, audioChannel, audioBitrate, mvi);
}
use of android.media.videoeditor.MediaVideoItem in project android_frameworks_base by ParanoidAndroid.
the class MediaPropertiesTest method testPropertiesH264NTSC.
/**
*To test Media Properties for file H264 NTSC
*/
@LargeTest
public void testPropertiesH264NTSC() throws Exception {
final String videoItemFilename = INPUT_FILE_PATH + "H264_BP_720x480_25fps_256kbps_AMRNB_8khz_12.2kbps_m_0_26.mp4";
final int aspectRatio = MediaProperties.ASPECT_RATIO_3_2;
final int fileType = MediaProperties.FILE_MP4;
final int videoCodecType = MediaProperties.VCODEC_H264;
final int duration = 26880;
final int videoBitrate = 244000;
final int audioBitrate = 12200;
final int fps = 25;
final int audioCodecType = MediaProperties.ACODEC_AMRNB;
final int audioSamplingFrequency = 8000;
final int audioChannel = 1;
final int videoProfile = MediaProperties.H264Profile.H264ProfileBaseline;
final int videoLevel = MediaProperties.H264Level.H264Level13;
final int width = 720;
final int height = MediaProperties.HEIGHT_480;
final int renderingMode = MediaItem.RENDERING_MODE_BLACK_BORDER;
final MediaVideoItem mvi = mVideoEditorHelper.createMediaItem(mVideoEditor, "m1", videoItemFilename, renderingMode);
validateVideoProperties(aspectRatio, fileType, videoCodecType, duration, videoBitrate, fps, videoProfile, videoLevel, width, height, audioCodecType, audioSamplingFrequency, audioChannel, audioBitrate, mvi);
}
use of android.media.videoeditor.MediaVideoItem in project android_frameworks_base by ParanoidAndroid.
the class MediaPropertiesTest method testPropertiesMPEGVGA.
/**
*To test Media Properties for file MPEG4 VGA
*/
@LargeTest
public void testPropertiesMPEGVGA() throws Exception {
final String videoItemFilename = INPUT_FILE_PATH + "MPEG4_SP_640x480_15fps_512kbps_AACLC_48khz_132kbps_s_0_26.mp4";
final int aspectRatio = MediaProperties.ASPECT_RATIO_4_3;
final int fileType = MediaProperties.FILE_MP4;
final int videoCodecType = MediaProperties.VCODEC_MPEG4;
final int duration = 26933;
final int videoBitrate = 533000;
final int audioBitrate = 128000;
final int fps = 15;
final int audioCodecType = MediaProperties.ACODEC_AAC_LC;
final int audioSamplingFrequency = 48000;
final int audioChannel = 2;
final int videoProfile = MediaProperties.MPEG4Profile.MPEG4ProfileSimple;
final int videoLevel = MediaProperties.MPEG4Level.MPEG4Level1;
final int width = 640;
final int height = MediaProperties.HEIGHT_480;
final int renderingMode = MediaItem.RENDERING_MODE_BLACK_BORDER;
final MediaVideoItem mvi = mVideoEditorHelper.createMediaItem(mVideoEditor, "m1", videoItemFilename, renderingMode);
validateVideoProperties(aspectRatio, fileType, videoCodecType, duration, videoBitrate, fps, videoProfile, videoLevel, width, height, audioCodecType, audioSamplingFrequency, audioChannel, audioBitrate, mvi);
}
use of android.media.videoeditor.MediaVideoItem in project android_frameworks_base by ParanoidAndroid.
the class MediaPropertiesTest method testPropertiesH264VGA.
/**
*To test Media Properties for file H264 VGA
*/
@LargeTest
public void testPropertiesH264VGA() throws Exception {
final String videoItemFilename = INPUT_FILE_PATH + "H264_BP_640x480_15fps_1200Kbps_AACLC_48KHz_64kps_m_0_27.3gp";
final int aspectRatio = MediaProperties.ASPECT_RATIO_4_3;
final int fileType = MediaProperties.FILE_3GP;
final int videoCodecType = MediaProperties.VCODEC_H264;
final int duration = 77600;
final int videoBitrate = 745000;
final int audioBitrate = 64000;
final int fps = 15;
final int audioCodecType = MediaProperties.ACODEC_AAC_LC;
final int audioSamplingFrequency = 48000;
final int audioChannel = 2;
final int videoProfile = MediaProperties.H264Profile.H264ProfileBaseline;
final int videoLevel = MediaProperties.H264Level.H264Level13;
final int width = 640;
final int height = MediaProperties.HEIGHT_480;
final int renderingMode = MediaItem.RENDERING_MODE_BLACK_BORDER;
final MediaVideoItem mvi = mVideoEditorHelper.createMediaItem(mVideoEditor, "m1", videoItemFilename, renderingMode);
validateVideoProperties(aspectRatio, fileType, videoCodecType, duration, videoBitrate, fps, videoProfile, videoLevel, width, height, audioCodecType, audioSamplingFrequency, audioChannel, audioBitrate, mvi);
}
use of android.media.videoeditor.MediaVideoItem in project android_frameworks_base by ParanoidAndroid.
the class MediaPropertiesTest method testPropertiesMPEGWVGA.
/**
*To test Media Properties for file MPEG4 WVGA
*/
@LargeTest
public void testPropertiesMPEGWVGA() throws Exception {
final String videoItemFilename = INPUT_FILE_PATH + "MPEG4_SP_800x480_515kbps_15fps_AMR_NB_8KHz_12.2kbps_m_0_26.mp4";
final int aspectRatio = MediaProperties.ASPECT_RATIO_5_3;
final int fileType = MediaProperties.FILE_MP4;
final int videoCodecType = MediaProperties.VCODEC_MPEG4;
final int duration = 26933;
final int videoBitrate = 384000;
final int audioBitrate = 12800;
final int fps = 15;
final int audioCodecType = MediaProperties.ACODEC_AMRNB;
final int audioSamplingFrequency = 8000;
final int audioChannel = 1;
final int videoProfile = MediaProperties.MPEG4Profile.MPEG4ProfileSimple;
final int videoLevel = MediaProperties.MPEG4Level.MPEG4Level1;
final int width = 800;
final int height = MediaProperties.HEIGHT_480;
final int renderingMode = MediaItem.RENDERING_MODE_BLACK_BORDER;
final MediaVideoItem mvi = mVideoEditorHelper.createMediaItem(mVideoEditor, "m1", videoItemFilename, renderingMode);
validateVideoProperties(aspectRatio, fileType, videoCodecType, duration, videoBitrate, fps, videoProfile, videoLevel, width, height, audioCodecType, audioSamplingFrequency, audioChannel, audioBitrate, mvi);
}
Aggregations