docs/doc/reference/com/google/android/exoplayer2/source/rtsp/RtpPayloadFormat.html
Package com.google.android.exoplayer2.source.rtsp
[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")public final classRtpPayloadFormatextends[Object](https://developer.android.com/reference/java/lang/Object.html "class or interface in java.lang")
Deprecated. com.google.android.exoplayer2 is deprecated. Please migrate to androidx.media3 (which contains the same ExoPlayer code). See the migration guide for more details, including a script to help with the migration.
Represents the payload format used in RTP.
In RTSP playback, the format information is always present in the SessionDescription enclosed in the response of a DESCRIBE request. Within each track's MediaDescription, it is the attributes FMTP and RTPMAP that allows us to recreate the media format.
This class wraps around the Format class, in addition to the instance fields that are specific to RTP.
Fields | Modifier and Type | Field | Description |
| --- | --- | --- |
| int | clockRate |
Deprecated.
The clock rate in Hertz, associated with the format.
|
| ImmutableMap<String,String> | fmtpParameters |
Deprecated.
The format parameters, mapped from the SDP FMTP attribute (RFC2327 Page 22).
|
| Format | format |
Deprecated.
The Format of this RTP payload.
|
| String | mediaEncoding |
Deprecated.
The RTP media encoding.
|
| static String | RTP_MEDIA_AC3 |
Deprecated.
|
| static String | RTP_MEDIA_AMR |
Deprecated.
|
| static String | RTP_MEDIA_AMR_WB |
Deprecated.
|
| static String | RTP_MEDIA_H263_1998 |
Deprecated.
|
| static String | RTP_MEDIA_H263_2000 |
Deprecated.
|
| static String | RTP_MEDIA_H264 |
Deprecated.
|
| static String | RTP_MEDIA_H265 |
Deprecated.
|
| static String | RTP_MEDIA_MPEG4_GENERIC |
Deprecated.
|
| static String | RTP_MEDIA_MPEG4_LATM_AUDIO |
Deprecated.
|
| static String | RTP_MEDIA_MPEG4_VIDEO |
Deprecated.
|
| static String | RTP_MEDIA_OPUS |
Deprecated.
|
| static String | RTP_MEDIA_PCM_L16 |
Deprecated.
|
| static String | RTP_MEDIA_PCM_L8 |
Deprecated.
|
| static String | RTP_MEDIA_PCMA |
Deprecated.
|
| static String | RTP_MEDIA_PCMU |
Deprecated.
|
| static String | RTP_MEDIA_VP8 |
Deprecated.
|
| static String | RTP_MEDIA_VP9 |
Deprecated.
|
| int | rtpPayloadType |
Deprecated.
The payload type associated with this format. |
Constructors | Constructor | Description |
| --- | --- |
| RtpPayloadFormat(Format format, int rtpPayloadType, int clockRate, Map<String,String> fmtpParameters, String mediaEncoding) |
Deprecated.
Creates a new instance. |
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods | Modifier and Type | Method | Description |
| --- | --- | --- |
| boolean | equals(Object o) |
Deprecated.
|
| static String | getMimeTypeFromRtpMediaType(String mediaType) |
Deprecated.
Gets the MIME type that is associated with the RTP media type.
|
| static @com.google.android.exoplayer2.C.PcmEncoding int | getRawPcmEncodingType(String mediaEncoding) |
Deprecated.
Returns the PCM encoding type for mediaEncoding.
|
| int | hashCode() |
Deprecated.
|
-
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_AC3
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_AMR
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_AMR_WB
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_MPEG4_GENERIC
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_MPEG4_LATM_AUDIO
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_MPEG4_VIDEO
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_H263_1998
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_H263_2000
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_H264
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_H265
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_OPUS
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_PCM_L8
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_PCM_L16
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_PCMA
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_PCMU
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_VP8
Deprecated. See Also:Constant Field Values
-
public static final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")RTP_MEDIA_VP9
Deprecated. See Also:Constant Field Values
-
public final int rtpPayloadType
Deprecated.
The payload type associated with this format.
-
public final int clockRate
Deprecated.
The clock rate in Hertz, associated with the format.
-
public final[Format](../../Format.html "class in com.google.android.exoplayer2")format
Deprecated.
The Format of this RTP payload.
-
public final[ImmutableMap](https://guava.dev/releases/31.1-android/api/docs/com/google/common/collect/ImmutableMap.html?is-external=true "class or interface in com.google.common.collect")<[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang"),[String](https://developer.android.com/reference/java/lang/String.html?is-external=true "class or interface in java.lang")> fmtpParameters
Deprecated.
The format parameters, mapped from the SDP FMTP attribute (RFC2327 Page 22).
-
public final[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")mediaEncoding
Deprecated.
The RTP media encoding.
-
public RtpPayloadFormat([Format](../../Format.html "class in com.google.android.exoplayer2")format,
int rtpPayloadType,
int clockRate,[Map](https://developer.android.com/reference/java/util/Map.html "class or interface in java.util")<[String](https://developer.android.com/reference/java/lang/String.html?is-external=true "class or interface in java.lang"),[String](https://developer.android.com/reference/java/lang/String.html?is-external=true "class or interface in java.lang")> fmtpParameters,[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")mediaEncoding)
Deprecated.
Creates a new instance.
Parameters:format - The associated media format.rtpPayloadType - The assigned RTP payload type, from the RTPMAP attribute in MediaDescription.clockRate - The associated clock rate in hertz.fmtpParameters - The format parameters, from the SDP FMTP attribute (RFC2327 Page 22), empty if unset. The keys and values are specified in the RFCs for specific formats. For instance, RFC3640 Section 4.1 defines keys like profile-level-id and config.mediaEncoding - The RTP media encoding.
-
public static[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")getMimeTypeFromRtpMediaType([String](https://developer.android.com/reference/java/lang/String.html?is-external=true "class or interface in java.lang")mediaType)
Deprecated.
Gets the MIME type that is associated with the RTP media type.
For instance, RTP media type "H264" maps to MimeTypes.VIDEO_H264.
Throws:IllegalArgumentException - When the media type is not supported/recognized.
-
public static @com.google.android.exoplayer2.C.PcmEncoding int getRawPcmEncodingType([String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")mediaEncoding)
Deprecated.
Returns the PCM encoding type for mediaEncoding.
-
public boolean equals(@Nullable[Object](https://developer.android.com/reference/java/lang/Object.html "class or interface in java.lang")o)
Deprecated.
Overrides:equals in class Object
-
public int hashCode()
Deprecated.
Overrides:hashCode in class Object