20 Commits

Author SHA1 Message Date
NCPlayz
3c9bcc2851 Improve documentation 2019-06-07 19:27:46 -04:00
Rapptz
919dbcafb3 Consistent use of __all__ to prevent merge conflicts. 2019-04-20 17:20:58 -04:00
NCPlayz
fb02191b80 Organise documentation 2019-03-19 08:24:42 -04:00
Imayhaveborkedit
9c5259afd7 Update voice code to vws V4
- Update internals to be compatible with v4
- Adds multiple encryption mode support.  Previously only `xsalsa20_poly1305` was supported.  Now `xsalsa20_poly1305_suffix` is also supported.
  Note: There is no (nice) way to manually select a mode.  The user needn't worry about this however.
- Fixed speaking state bug.  When you disconnected from a voice channel while a bot was playing, upon reconnect you would be unable to hear the bot.  This was caused by bots not sending their speaking state while transmitting.  Bots will now set their speaking state properly when transmitting.  
  Note: This does not account for sending actual silence, the speaking indicator will still be active.
2019-01-28 22:22:52 -05:00
Dante Dam
9656a21ebe Bumped copyright years to 2019. 2019-01-28 22:22:50 -05:00
Hornwitser
fa46b07db1 [lint] Rename exception variables to exc
Use the more explicit (and common) exc instead of e as the variable
holding the exception in except handlers.
2018-11-24 22:17:57 -05:00
Hornwitser
a71b3b5fa0 [lint] Limit unneccessarily broad except clauses
Add exception qualifier(s) to bare except clauses swallowing exceptions.
2018-11-24 22:17:57 -05:00
Rapptz
5c24e69cf2 Fix up the Sphinx strings causing warnings. 2018-09-15 09:54:00 -04:00
Hornwitser
c8b49d37be [lint] Fix incorrect and inconsistent whitespace
Adjust whitespace to be consistent with the rest of the library.
2018-08-22 21:43:53 -04:00
Daniel
ceb82ecc7b
Fix self._process not existing during cleanup() in case of error 2017-11-21 17:51:34 -05:00
Daniel
b532da7906 Fix waiting for resume when calling stop() on AudioPlayer 2017-07-21 18:37:22 -04:00
Rapptz
5d75c44651 Call cleanup on AudioSource.__del__. 2017-07-19 05:58:20 -04:00
Rapptz
eda903f6b1 Add some logging for when ffmpeg processes get terminated. 2017-07-18 18:46:56 -04:00
Rapptz
daf066dd39 Log when a player's after function fails. 2017-06-02 06:43:33 -04:00
Rapptz
34c60002bf Allow setting a default volume in PCMVolumeTransformer. 2017-04-19 17:33:16 -04:00
Rapptz
f5cfc96aaf Add PCMVolumeTransformer to augment volume of a PCM stream.
This also introduces the idea of replacing the VoiceClient.source on
the fly. Note that this internally pauses and resumes the audio
stream.
2017-04-19 17:23:39 -04:00
Rapptz
07d5328873 Add VoiceClient.is_paused to query pause state. 2017-04-19 16:06:45 -04:00
Rapptz
efd6d11e9a Fix static cut-off when playing. 2017-04-18 22:20:40 -04:00
Rapptz
b4bc4dfd12 Fix FFmpegPCMAudio not working with spaces in filename. 2017-04-18 16:05:32 -04:00
Rapptz
3b1b26ffb1 Re-implement voice sending.
This is a complete redesign of the old voice code.

A list of major changes is as follows:

* The voice websocket will now automatically reconnect with
  exponential back-off just like the regular Client does.
* Removal of the stream player concept.
* Audio now gracefully pauses and resumes when a disconnect is found.
* Introduce a discord.AudioSource concept to abstract streams
* Flatten previous stream player functionality with the
  VoiceClient, e.g. player.stop() is now voice_client.stop()
* With the above re-coupling this means you no longer have to
  store players anywhere.
* The after function now requires a single parameter, the error,
  if any existed. This will typically be None.

A lot of this design is experimental.
2017-04-18 03:49:48 -04:00