mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-27 23:34:06 +00:00
Eliminate redundant casts to/from void* in Ffmpeg player
This commit is contained in:
parent
bd95948264
commit
2e25be8f71
|
@ -61,10 +61,10 @@ AudioPlayer::~AudioPlayer()
|
||||||
ao_shutdown();
|
ao_shutdown();
|
||||||
}
|
}
|
||||||
|
|
||||||
void AudioPlayer::playMemory( const void * ptr, int size )
|
void AudioPlayer::playMemory( const char * ptr, int size )
|
||||||
{
|
{
|
||||||
emit cancelPlaying( false );
|
emit cancelPlaying( false );
|
||||||
QByteArray audioData( ( char * )ptr, size );
|
QByteArray audioData( ptr, size );
|
||||||
DecoderThread * thread = new DecoderThread( audioData, this );
|
DecoderThread * thread = new DecoderThread( audioData, this );
|
||||||
|
|
||||||
connect( thread, SIGNAL( error( QString ) ), this, SIGNAL( error( QString ) ) );
|
connect( thread, SIGNAL( error( QString ) ), this, SIGNAL( error( QString ) ) );
|
||||||
|
|
|
@ -18,7 +18,7 @@ class AudioPlayer : public QObject
|
||||||
|
|
||||||
public:
|
public:
|
||||||
static AudioPlayer & instance();
|
static AudioPlayer & instance();
|
||||||
void playMemory( const void * ptr, int size );
|
void playMemory( const char * ptr, int size );
|
||||||
void stop();
|
void stop();
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
|
|
Loading…
Reference in a new issue