Mercurial > mm7
comparison VideoPlayer.h @ 2208:0b2eea6f80c9
for video in homes
author | Ritor1 |
---|---|
date | Wed, 12 Feb 2014 16:33:12 +0600 |
parents | ca548138d6aa |
children | c69013c186c7 |
comparison
equal
deleted
inserted
replaced
2207:ff8920a40c21 | 2208:0b2eea6f80c9 |
---|---|
264 CheckError(); | 264 CheckError(); |
265 | 265 |
266 | 266 |
267 int num_processed_buffers; | 267 int num_processed_buffers; |
268 alGetSourcei(samples_source_id, AL_BUFFERS_PROCESSED, &num_processed_buffers); | 268 alGetSourcei(samples_source_id, AL_BUFFERS_PROCESSED, &num_processed_buffers); |
269 while (num_processed_buffers) | 269 /*while (num_processed_buffers) |
270 { | 270 { |
271 unsigned int processed_buffers_id[4]; | 271 unsigned int processed_buffers_id[4]; |
272 alSourceUnqueueBuffers(samples_source_id, min(4, num_processed_buffers), processed_buffers_id); | 272 alSourceUnqueueBuffers(samples_source_id, min(4, num_processed_buffers), processed_buffers_id); |
273 CheckError(); | 273 CheckError(); |
274 alGetSourcei(samples_source_id, AL_BUFFERS_PROCESSED, &num_processed_buffers); | 274 alGetSourcei(samples_source_id, AL_BUFFERS_PROCESSED, &num_processed_buffers); |
275 } | 275 }*/ |
276 for (int i = 0; i < num_processed_buffers; ++i) | |
277 { | |
278 unsigned int processed_buffer_id; | |
279 alSourceUnqueueBuffers(samples_source_id, 1, &processed_buffer_id); | |
280 if (!CheckError()) | |
281 alDeleteBuffers(1, &processed_buffer_id); | |
282 } | |
276 | 283 |
277 int num_queued_buffers; | 284 int num_queued_buffers; |
278 alGetSourcei(samples_source_id, AL_BUFFERS_QUEUED, &num_queued_buffers); | 285 alGetSourcei(samples_source_id, AL_BUFFERS_QUEUED, &num_queued_buffers); |
279 if (num_queued_buffers >= MAX_SAMPLES_BUFFERS) | 286 if (num_queued_buffers >= MAX_SAMPLES_BUFFERS) |
280 { | 287 { |