Home | History | Annotate | Download | only in mediaframeworktest
      1 /*
      2  * Copyright (C) 2008 The Android Open Source Project
      3  *
      4  * Licensed under the Apache License, Version 2.0 (the "License"); you may not
      5  * use this file except in compliance with the License. You may obtain a copy of
      6  * the License at
      7  *
      8  * http://www.apache.org/licenses/LICENSE-2.0
      9  *
     10  * Unless required by applicable law or agreed to in writing, software
     11  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
     12  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
     13  * License for the specific language governing permissions and limitations under
     14  * the License.
     15  */
     16 
     17 package com.android.mediaframeworktest;
     18 
     19 /**
     20  *
     21  * This class has the names of the all the activity name and variables in the
     22  * instrumentation test.
     23  *
     24  */
     25 public class MediaNames {
     26     // A directory to hold all kinds of media files
     27     public static final String MEDIA_SAMPLE_POOL = "/sdcard/media_api/samples/";
     28     // Audio files
     29     public static final String MP3CBR = "/sdcard/media_api/music/MP3_48KHz_128kbps_s_1_17_CBR.mp3";
     30     public static final String MP3VBR = "/sdcard/media_api/music/MP3_48KHz_128kbps_s_1_17_VBR.mp3";
     31     public static final String MP3ABR = "/sdcard/media_api/music/MP3_48KHz_128kbps_s_1_17_ABR.mp3";
     32     public static final String SHORTMP3 = "/sdcard/media_api/music/SHORTMP3.mp3";
     33     public static final String MIDI = "/sdcard/media_api/music/ants.mid";
     34     public static final String WAV = "/sdcard/media_api/music/rings_2ch.wav";
     35     public static final String AMR = "/sdcard/media_api/music/test_amr_ietf.amr";
     36     public static final String SINE_200_1000 = "/sdcard/media_api/music/sine_200+1000Hz_44K_mo.wav";
     37     // public static final String OGG =
     38     // "/sdcard/media_api/music/Revelation.ogg";
     39 
     40     public static final int MP3CBR_LENGTH = 71000;
     41     public static final int MP3VBR_LENGTH = 71000;
     42     public static final int SHORTMP3_LENGTH = 286;
     43     public static final int MIDI_LENGTH = 17000;
     44     public static final int AMR_LENGTH = 37000;
     45     public static final int SEEK_TIME = 10000;
     46 
     47     public static final long PAUSE_WAIT_TIME = 3000;
     48     public static final long WAIT_TIME = 2000;
     49     public static final long WAIT_SNAPSHOT_TIME = 5000;
     50 
     51     // local video
     52     public static final String VIDEO_MP4 = "/sdcard/media_api/video/MPEG4_320_AAC_64.mp4";
     53     public static final String VIDEO_SHORT_3GP = "/sdcard/media_api/video/short.3gp";
     54     public static final String VIDEO_LARGE_SIZE_3GP = "/sdcard/media_api/video/border_large.3gp";
     55     public static final String VIDEO_H263_AAC = "/sdcard/media_api/video/H263_56_AAC_24.3gp";
     56     public static final String VIDEO_H263_AMR = "/sdcard/media_api/video/H263_56_AMRNB_6.3gp";
     57     public static final String VIDEO_H264_AAC = "/sdcard/media_api/video/H264_320_AAC_64.3gp";
     58     public static final String VIDEO_H264_AMR = "/sdcard/media_api/video/H264_320_AMRNB_6.3gp";
     59     public static final String VIDEO_HIGHRES_H263 = "/sdcard/media_api/video/H263_500_AMRNB_12.3gp";
     60     public static final String VIDEO_HIGHRES_MP4 = "/sdcard/media_api/video/H264_500_AAC_128.3gp";
     61     public static final String VIDEO_WEBM = "/sdcard/media_api/video/big-buck-bunny_trailer.webm";
     62 
     63     // Media Recorder
     64     public static final String RECORDER_OUTPUT = "/sdcard/media_api/recorderOutput.amr";
     65 
     66     // video thumbnail
     67     public static final String THUMBNAIL_OUTPUT = "/sdcard/media_api/videoThumbnail.png";
     68     public static final String GOLDEN_THUMBNAIL_OUTPUT = "/sdcard/media_api/goldenThumbnail.png";
     69 
     70     /*
     71      * Metadata Utility Test media files which contain meta data.
     72      */
     73     public static final String[] THUMBNAIL_METADATA_TEST_FILES = {
     74         "/sdcard/media_api/video/H263_500_AMRNB_12.3gp",
     75         "/sdcard/media_api/video/H263_56_AAC_24.3gp",
     76         "/sdcard/media_api/video/H263_56_AMRNB_6.3gp",
     77         "/sdcard/media_api/video/H264_320_AAC_64.3gp",
     78         "/sdcard/media_api/video/H264_320_AMRNB_6.3gp",
     79         "/sdcard/media_api/video/H264_500_AAC_128.3gp",
     80         "/sdcard/media_api/video/H264_HVGA_500_NO_AUDIO.3gp",
     81         "/sdcard/media_api/video/H264_QVGA_500_NO_AUDIO.3gp",
     82         "/sdcard/media_api/video/MPEG4_320_AAC_64.mp4",
     83         "/sdcard/media_api/video/border_large.3gp",
     84         "/sdcard/media_api/videoeditor/H264_BP_800x480_15fps_512kbps_AACLC_24KHz_38Kbps_s_1_17.mp4",
     85         "/sdcard/media_api/videoeditor/H264_MP_960x720_25fps_800kbps_AACLC_48Khz_192Kbps_s_1_17.mp4",
     86         "/sdcard/media_api/videoeditor/MPEG4_SP_640x480_15fps_512kbps_AACLC_48khz_132kbps_s_0_26.mp4",
     87         "/sdcard/media_api/videoeditor/MPEG4_SP_176x144_12fps_92kbps_AMRNB_8KHz_12.2kbps_m_0_27.3gp",
     88         "/sdcard/media_api/videoeditor/MPEG4_SP_720x480_30fps_280kbps_AACLC_48kHz_161kbps_s_0_26.mp4"
     89     };
     90 
     91     public static final String[] ALBUMART_TEST_FILES = {
     92         "/sdcard/media_api/music/MP3_48KHz_128kbps_s_1_17_ID3V1_ID3V2.mp3",
     93         "/sdcard/media_api/music/MP3_48KHz_128kbps_s_1_17_ID3V2.mp3",
     94         "/sdcard/media_api/music/MP3_48KHz_128kbps_s_1_17_ID3V1.mp3",
     95     };
     96 
     97     // TEST_PATH_1: is a video and contains metadata for key "num-tracks"
     98     // TEST_PATH_2: any valid media file.
     99     // TEST_PATH_3: invalid media file
    100     public static final String TEST_PATH_1 = "/sdcard/media_api/video/MPEG4_320_AAC_64.mp4";
    101     public static final String TEST_PATH_3 = "/sdcard/media_api/data.txt";
    102     public static final String TEST_PATH_4 = "somenonexistingpathname";
    103     public static final String TEST_PATH_5 = "mem://012345";
    104 
    105     // Meta data expected result
    106     // The expected tag result in the following order
    107     // cd_track_number, album, artist, author, composer, date, genre
    108     // title, years, duration
    109     public static final String META_DATA_MP3[][] = {
    110         {"/sdcard/media_api/music/MP3_48KHz_128kbps_s_1_17_ID3V1_ID3V2.mp3", "2/34",
    111          "Test ID3V2 Album", "Test ID3V2 Artist", null, "Test ID3V2 Composer",
    112          null, "(1)Classic Rock", "Test ID3V2 Title ", null, "77640", "1", null},
    113         {"/sdcard/media_api/music/MP3_48KHz_128kbps_s_1_17_ID3V2.mp3", "1/10",
    114          "Test ID3V2 Album", "Test ID3V2 Artist", null, "Test ID3V2 Composer",
    115          null, "(74)Acid Jazz", "Test ID3V2 Tag", null, "77640", "1", null},
    116         {"/sdcard/media_api/music/MP3_48KHz_128kbps_s_1_17_ID3V1.mp3", "2",
    117          "Test ID3V1 Album", "Test ID3V1 Artist", null, null, null, "(15)",
    118          "Test ID3V1 Title", "2011", "77640", "1", null}
    119     };
    120 
    121     // output recorded video
    122     public static final String RECORDED_HVGA_H263 = "/sdcard/HVGA_H263.3gp";
    123     public static final String RECORDED_QVGA_H263 = "/sdcard/QVGA_H263.3gp";
    124     public static final String RECORDED_SQVGA_H263 = "/sdcard/SQVGA_H263.3gp";
    125     public static final String RECORDED_CIF_H263 = "/sdcard/CIF_H263.3gp";
    126     public static final String RECORDED_QCIF_H263 = "/sdcard/QCIF_H263.3gp";
    127     public static final String RECORDED_PORTRAIT_H263 = "/sdcard/QCIF_mp4.3gp";
    128 
    129     public static final String RECORDED_HVGA_MP4 = "/sdcard/HVGA_mp4.mp4";
    130     public static final String RECORDED_QVGA_MP4 = "/sdcard/QVGA_mp4.mp4";
    131     public static final String RECORDED_SQVGA_MP4 = "/sdcard/SQVGA_mp4.mp4";
    132     public static final String RECORDED_CIF_MP4 = "/sdcard/CIF_mp4.mp4";
    133     public static final String RECORDED_QCIF_MP4 = "/sdcard/QCIF_mp4.mp4";
    134 
    135     public static final String RECORDED_VIDEO_3GP = "/sdcard/temp.3gp";
    136 
    137     public static final String INVALD_VIDEO_PATH =
    138             "/sdcard/media_api/filepathdoesnotexist" + "/filepathdoesnotexist/temp.3gp";
    139 
    140     public static final long RECORDED_TIME = 5000;
    141     public static final long VALID_VIDEO_DURATION = 2000;
    142 
    143     // Streaming test files
    144     public static final byte[] STREAM_SERVER =
    145             new byte[] {(byte) 75, (byte) 17, (byte) 48, (byte) 204};
    146     public static final String STREAM_H264_480_360_1411k =
    147             "http://75.17.48.204:10088/yslau/stress_media/h264_regular.mp4";
    148     public static final String STREAM_WMV = "http://75.17.48.204:10088/yslau/stress_media/bugs.wmv";
    149     public static final String STREAM_H263_176x144_325k =
    150             "http://75.17.48.204:10088/yslau/stress_media/h263_regular.3gp";
    151     public static final String STREAM_H264_352x288_1536k =
    152             "http://75.17.48.204:10088/yslau/stress_media/h264_highBitRate.mp4";
    153     public static final String STREAM_MP3 =
    154             "http://75.17.48.204:10088/yslau/stress_media/mp3_regular.mp3";
    155     public static final String STREAM_MPEG4_QVGA_128k =
    156             "http://75.17.48.204:10088/yslau/stress_media/mpeg4_qvga_24fps.3gp";
    157     public static final int STREAM_H264_480_360_1411k_DURATION = 46000;
    158     public static final int VIDEO_H263_AAC_DURATION = 501000;
    159     public static final int VIDEO_H263_AMR_DURATION = 502000;
    160 
    161     // Video files for WiFi IOT video streaming test.
    162     public static final String[] NETWORK_VIDEO_FILES = {
    163             "H264_BP_720x480_25fps_256kbps_AMRNB_8khz_12.2kbps_m_0_26.mp4",
    164             "MPEG4_SP_720x480_30fps_280kbps_AACLC_48kHz_161kbps_s_0_26.mp4",
    165             "MPEG4_SP_720x480_30fps_280kbps_AACLC_48kHz_96kbps_s_0_21.mp4"
    166     };
    167 }
    168