Skip to content

Commit

Permalink
doc - Added missing documentation
Browse files Browse the repository at this point in the history
---

We've added missing documentation in the FormatTools documentation.

---

Type: doc
Breaking: False
Doc Required: False
Backport Required: False
Part: 1/1
  • Loading branch information
AptiviCEO committed Sep 18, 2024
1 parent 14844ae commit a92b595
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions BassBoom.Basolia/Format/FormatTools.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ public static class FormatTools
/// <summary>
/// Gets the format information
/// </summary>
/// <param name="basolia">Basolia instance that contains a valid handle</param>
public static (long rate, int channels, int encoding) GetFormatInfo(BasoliaMedia? basolia)
{
if (basolia is null)
Expand Down Expand Up @@ -123,7 +124,7 @@ public static string GetEncodingName(int encoding)
// We're now entering the dangerous zone
unsafe
{
// Get the encodings
// Get the encoding name
var @delegate = MpgNative.GetDelegate<NativeOutputLib.out123_enc_name>(MpgNative.libManagerOut, nameof(NativeOutputLib.out123_enc_name));
IntPtr namePtr = @delegate.Invoke(encoding);
encodingName = Marshal.PtrToStringAnsi(namePtr);
Expand Down Expand Up @@ -151,7 +152,7 @@ public static string GetEncodingDescription(int encoding)
// We're now entering the dangerous zone
unsafe
{
// Get the encodings
// Get the encoding description
var @delegate = MpgNative.GetDelegate<NativeOutputLib.out123_enc_longname>(MpgNative.libManagerOut, nameof(NativeOutputLib.out123_enc_longname));
IntPtr descriptionPtr = @delegate.Invoke(encoding);
encodingDescription = Marshal.PtrToStringAnsi(descriptionPtr);
Expand All @@ -164,8 +165,10 @@ public static string GetEncodingDescription(int encoding)
/// <summary>
/// Gets the supported formats
/// </summary>
/// <param name="basolia">Basolia instance that contains a valid handle</param>
public static FormatInfo[] GetFormats(BasoliaMedia? basolia)
{
InitBasolia.CheckInited();
if (basolia is null)
throw new BasoliaException("Basolia instance is not provided", mpg123_errors.MPG123_BAD_HANDLE);
var formats = new List<FormatInfo>();
Expand Down

0 comments on commit a92b595

Please sign in to comment.