Java Code Examples for android.media.MediaCodecInfo.CodecProfileLevel#AVCProfileBaseline

The following examples show how to use android.media.MediaCodecInfo.CodecProfileLevel#AVCProfileBaseline . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: IjkMediaCodecInfo.java    From MediaSDK with Apache License 2.0 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 2
Source File: IjkMediaCodecInfo.java    From JZVideoDemo with MIT License 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 3
Source File: IjkMediaCodecInfo.java    From DanDanPlayForAndroid with MIT License 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 4
Source File: IjkMediaCodecInfo.java    From AndroidTvDemo with Apache License 2.0 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 5
Source File: IjkMediaCodecInfo.java    From ShareBox with Apache License 2.0 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 6
Source File: IjkMediaCodecInfo.java    From MKVideoPlayer with MIT License 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 7
Source File: IjkMediaCodecInfo.java    From TvPlayer with Apache License 2.0 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 8
Source File: IjkMediaCodecInfo.java    From talk-android with MIT License 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 9
Source File: IjkMediaCodecInfo.java    From LivePlayback with Apache License 2.0 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 10
Source File: IjkMediaCodecInfo.java    From IjkPlayerDemo with Apache License 2.0 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 11
Source File: IjkMediaCodecInfo.java    From WliveTV with Apache License 2.0 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 12
Source File: CodecSpecificDataUtil.java    From Exoplayer_VLC with Apache License 2.0 6 votes vote down vote up
@SuppressLint("InlinedApi")
private static int parseAvcProfile(byte[] data) {
  int profileIdc = data[6] & 0xFF;
  switch (profileIdc) {
    case 0x42:
      return CodecProfileLevel.AVCProfileBaseline;
    case 0x4d:
      return CodecProfileLevel.AVCProfileMain;
    case 0x58:
      return CodecProfileLevel.AVCProfileExtended;
    case 0x64:
      return CodecProfileLevel.AVCProfileHigh;
    case 0x6e:
      return CodecProfileLevel.AVCProfileHigh10;
    case 0x7a:
      return CodecProfileLevel.AVCProfileHigh422;
    case 0xf4:
      return CodecProfileLevel.AVCProfileHigh444;
    default:
      return 0;
  }
}
 
Example 13
Source File: IjkMediaCodecInfo.java    From GiraffePlayer with Apache License 2.0 6 votes vote down vote up
public static String getProfileName(int profile) {
    switch (profile) {
    case CodecProfileLevel.AVCProfileBaseline:
        return "Baseline";
    case CodecProfileLevel.AVCProfileMain:
        return "Main";
    case CodecProfileLevel.AVCProfileExtended:
        return "Extends";
    case CodecProfileLevel.AVCProfileHigh:
        return "High";
    case CodecProfileLevel.AVCProfileHigh10:
        return "High10";
    case CodecProfileLevel.AVCProfileHigh422:
        return "High422";
    case CodecProfileLevel.AVCProfileHigh444:
        return "High444";
    default:
        return "Unknown";
    }
}
 
Example 14
Source File: CodecProfileLevelList.java    From 365browser with Apache License 2.0 4 votes vote down vote up
private static int mediaCodecProfileToChromiumMediaProfile(int codec, int profile) {
    switch (codec) {
        case VideoCodec.CODEC_H264:
            switch (profile) {
                case CodecProfileLevel.AVCProfileBaseline:
                    return VideoCodecProfile.H264PROFILE_BASELINE;
                case CodecProfileLevel.AVCProfileMain:
                    return VideoCodecProfile.H264PROFILE_MAIN;
                case CodecProfileLevel.AVCProfileExtended:
                    return VideoCodecProfile.H264PROFILE_EXTENDED;
                case CodecProfileLevel.AVCProfileHigh:
                    return VideoCodecProfile.H264PROFILE_HIGH;
                case CodecProfileLevel.AVCProfileHigh10:
                    return VideoCodecProfile.H264PROFILE_HIGH10PROFILE;
                case CodecProfileLevel.AVCProfileHigh422:
                    return VideoCodecProfile.H264PROFILE_HIGH422PROFILE;
                case CodecProfileLevel.AVCProfileHigh444:
                    return VideoCodecProfile.H264PROFILE_HIGH444PREDICTIVEPROFILE;
                default:
                    throw new UnsupportedCodecProfileException();
            }
        case VideoCodec.CODEC_VP8:
            switch (profile) {
                case CodecProfileLevel.VP8ProfileMain:
                    return VideoCodecProfile.VP8PROFILE_ANY;
                default:
                    throw new UnsupportedCodecProfileException();
            }
        case VideoCodec.CODEC_VP9:
            switch (profile) {
                case CodecProfileLevel.VP9Profile0:
                    return VideoCodecProfile.VP9PROFILE_PROFILE0;
                case CodecProfileLevel.VP9Profile1:
                    return VideoCodecProfile.VP9PROFILE_PROFILE1;
                case CodecProfileLevel.VP9Profile2:
                    return VideoCodecProfile.VP9PROFILE_PROFILE2;
                case CodecProfileLevel.VP9Profile3:
                    return VideoCodecProfile.VP9PROFILE_PROFILE3;
                default:
                    throw new UnsupportedCodecProfileException();
            }
        case VideoCodec.CODEC_HEVC:
            switch (profile) {
                case CodecProfileLevel.HEVCProfileMain:
                    return VideoCodecProfile.HEVCPROFILE_MAIN;
                case CodecProfileLevel.HEVCProfileMain10:
                    return VideoCodecProfile.HEVCPROFILE_MAIN10;
                case CodecProfileLevel.HEVCProfileMain10HDR10:
                    return VideoCodecProfile.HEVCPROFILE_MAIN_STILL_PICTURE;
                default:
                    throw new UnsupportedCodecProfileException();
            }
        default:
            throw new UnsupportedCodecProfileException();
    }
}