From 3c9bcc285147154a2980f6e661efdfa676672b6a Mon Sep 17 00:00:00 2001 From: NCPlayz Date: Sat, 18 May 2019 06:04:54 -0400 Subject: Improve documentation --- discord/player.py | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) (limited to 'discord/player.py') diff --git a/discord/player.py b/discord/player.py index 3834a44a..9d9311e6 100644 --- a/discord/player.py +++ b/discord/player.py @@ -76,10 +76,7 @@ class AudioSource: raise NotImplementedError def is_opus(self): - """Checks if the audio source is already encoded in Opus. - - Defaults to ``False``. - """ + """Checks if the audio source is already encoded in Opus.""" return False def cleanup(self): @@ -98,7 +95,7 @@ class PCMAudio(AudioSource): Attributes ----------- - stream: file-like object + stream: :term:`py:file object` A file-like object that reads byte data representing raw PCM. """ def __init__(self, stream): @@ -122,16 +119,16 @@ class FFmpegPCMAudio(AudioSource): Parameters ------------ - source: Union[:class:`str`, BinaryIO] + source: Union[:class:`str`, :class:`io.BufferedIOBase`] The input that ffmpeg will take and convert to PCM bytes. If ``pipe`` is True then this is a file-like object that is passed to the stdin of ffmpeg. executable: :class:`str` The executable name (and path) to use. Defaults to ``ffmpeg``. pipe: :class:`bool` - If true, denotes that ``source`` parameter will be passed + If ``True``, denotes that ``source`` parameter will be passed to the stdin of ffmpeg. Defaults to ``False``. - stderr: Optional[BinaryIO] + stderr: Optional[:term:`py:file object`] A file-like object to pass to the Popen constructor. Could also be an instance of ``subprocess.PIPE``. options: Optional[:class:`str`] @@ -203,7 +200,7 @@ class PCMVolumeTransformer(AudioSource): ------------ original: :class:`AudioSource` The original AudioSource to transform. - volume: float + volume: :class:`float` The initial volume to set it to. See :attr:`volume` for more info. -- cgit v1.2.3