Struct Profile
Represents a profile in FFmpeg, providing information about the profile ID and its associated name.
Inherited Members
Namespace: FFmpeg.Codecs
Assembly: FFmpeg.dll
Syntax
public readonly struct Profile : IEquatable<Profile>, IEquatable<_AVProfile>
Constructors
View SourceProfile(Codec, int)
Initializes a new instance of the Profile struct using a codec and a profile ID.
Declaration
public Profile(Codec codec, int profile)
Parameters
| Type | Name | Description |
|---|---|---|
| Codec | codec | The codec associated with this profile. |
| int | profile | The profile ID. |
Profile(CodecID, int)
Initializes a new instance of the Profile struct using a codec ID and a profile ID.
Declaration
public Profile(CodecID codec, int profile)
Parameters
| Type | Name | Description |
|---|---|---|
| CodecID | codec | The codec ID associated with this profile. |
| int | profile | The profile ID. |
Profile(int, byte*)
Initializes a new instance of the Profile struct using a profile ID and a name pointer.
Declaration
public Profile(int profile, byte* name)
Parameters
| Type | Name | Description |
|---|---|---|
| int | profile | The profile ID, an integer that uniquely identifies the profile. |
| byte* | name | A pointer to the profile name in memory. |
Profile(int, string?)
Initializes a new instance of the Profile struct using a profile ID and a profile name.
Declaration
public Profile(int profile, string? name)
Parameters
| Type | Name | Description |
|---|---|---|
| int | profile | The profile ID. |
| string | name | The name of the profile, or |
Properties
View SourceName
Gets the name of the profile. Returns null if the profile name is not available.
Declaration
public string? Name { get; }
Property Value
| Type | Description |
|---|---|
| string | The name of the profile, or |
ProfileID
Gets the profile ID.
Declaration
public int ProfileID { get; }
Property Value
| Type | Description |
|---|---|
| int | The ID of the profile. |
Unknown
Represents an unknown profile with an ID of AV_PROFILE_UNKNOWN and no associated name.
Declaration
public static Profile Unknown { get; }
Property Value
| Type | Description |
|---|---|
| Profile | A Profile instance representing an unknown profile. |
Methods
View SourceEquals(_AVProfile)
Declaration
public bool Equals(_AVProfile other)
Parameters
| Type | Name | Description |
|---|---|---|
| _AVProfile | other |
Returns
| Type | Description |
|---|---|
| bool |
Equals(Profile)
Declaration
public bool Equals(Profile other)
Parameters
| Type | Name | Description |
|---|---|---|
| Profile | other |
Returns
| Type | Description |
|---|---|
| bool |
Equals(object?)
Declaration
public override bool Equals(object? obj)
Parameters
| Type | Name | Description |
|---|---|---|
| object | obj |
Returns
| Type | Description |
|---|---|
| bool |
Overrides
View SourceGetHashCode()
Declaration
public override int GetHashCode()
Returns
| Type | Description |
|---|---|
| int |
Overrides
View SourceToString()
Returns the profile name or "UNKNOWN" if the name is not available.
Declaration
public override string ToString()
Returns
| Type | Description |
|---|---|
| string | A string representing the profile name, or "UNKNOWN" if not available. |
Overrides
Operators
View Sourceoperator ==(_AVProfile, Profile)
Determines whether a Profile instance and an FFmpeg.AutoGen._AVProfile instance are equal.
Declaration
public static bool operator ==(_AVProfile left, Profile right)
Parameters
| Type | Name | Description |
|---|---|---|
| _AVProfile | left | The FFmpeg.AutoGen._AVProfile instance. |
| Profile | right | The Profile instance. |
Returns
| Type | Description |
|---|---|
| bool |
|
operator ==(Profile, Profile)
Determines whether two Profile instances are equal.
Declaration
public static bool operator ==(Profile left, Profile right)
Parameters
| Type | Name | Description |
|---|---|---|
| Profile | left | The first Profile instance. |
| Profile | right | The second Profile instance. |
Returns
| Type | Description |
|---|---|
| bool |
|
operator !=(_AVProfile, Profile)
Determines whether a Profile instance and an FFmpeg.AutoGen._AVProfile instance are not equal.
Declaration
public static bool operator !=(_AVProfile left, Profile right)
Parameters
| Type | Name | Description |
|---|---|---|
| _AVProfile | left | The FFmpeg.AutoGen._AVProfile instance. |
| Profile | right | The Profile instance. |
Returns
| Type | Description |
|---|---|
| bool |
|
operator !=(Profile, Profile)
Determines whether two Profile instances are not equal.
Declaration
public static bool operator !=(Profile left, Profile right)
Parameters
| Type | Name | Description |
|---|---|---|
| Profile | left | The first Profile instance. |
| Profile | right | The second Profile instance. |
Returns
| Type | Description |
|---|---|
| bool |
|