Skip to content

Commit

Permalink
Set ALsource::queue_channels even with static buffers and not a buffe…
Browse files Browse the repository at this point in the history
…r queue.

This lets us know if the source is mono, no matter where its buffer data comes
from, so we can decide if we need to spatialize it without a lot of trouble.
  • Loading branch information
icculus committed Apr 13, 2018
1 parent 40cf061 commit e98c02b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mojoal.c
Expand Up @@ -2277,7 +2277,7 @@ void alSourceiv(ALuint name, ALenum param, const ALint *values)
}
src->buffer = buffer;
src->type = buffer ? AL_STATIC : AL_UNDETERMINED;
src->queue_channels = 0;
src->queue_channels = buffer ? buffer->channels : 0;
src->queue_frequency = 0;
FIXME("must dump buffer queue");
/* if this was AL_PLAYING and the mixer is mixing this source RIGHT NOW you could alSourceStop and call this while it's still mixing. */
Expand Down

0 comments on commit e98c02b

Please sign in to comment.