Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(155)

Side by Side Diff: runtime/embedders/openglui/common/sound_handler.cc

Issue 12186002: Canvas API. There are still a number of things to do: (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/embedders/openglui/common/opengl.h ('k') | runtime/embedders/openglui/common/support.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "embedders/openglui/common/sound_handler.h" 5 #include "embedders/openglui/common/sound_handler.h"
6 6
7 #include <string.h> 7 #include <string.h>
8 8
9 #include "embedders/openglui/common/log.h" 9 #include "embedders/openglui/common/log.h"
10 10
(...skipping 15 matching lines...) Expand all
26 Sample* sample = new Sample(path); 26 Sample* sample = new Sample(path);
27 if (sample->Load() != 0) { 27 if (sample->Load() != 0) {
28 LOGI("Failed to load sample %s", path); 28 LOGI("Failed to load sample %s", path);
29 delete sample; 29 delete sample;
30 return NULL; 30 return NULL;
31 } 31 }
32 samples_.push_back(sample); 32 samples_.push_back(sample);
33 return sample; 33 return sample;
34 } 34 }
35 35
36
37 int32_t PlayBackgroundSound(const char* path) { 36 int32_t PlayBackgroundSound(const char* path) {
38 return SoundHandler::instance()->PlayBackground(path); 37 return SoundHandler::instance()->PlayBackground(path);
39 } 38 }
40 39
41 void StopBackgroundSound() { 40 void StopBackgroundSound() {
42 SoundHandler::instance()->StopBackground(); 41 SoundHandler::instance()->StopBackground();
43 } 42 }
44 43
45 int32_t LoadSoundSample(const char* path) { 44 int32_t LoadSoundSample(const char* path) {
46 return SoundHandler::instance()->LoadSample(path); 45 return SoundHandler::instance()->LoadSample(path);
47 } 46 }
48 47
49 int32_t PlaySoundSample(const char* path) { 48 int32_t PlaySoundSample(const char* path) {
50 return SoundHandler::instance()->PlaySample(path); 49 return SoundHandler::instance()->PlaySample(path);
51 } 50 }
52 51
OLDNEW
« no previous file with comments | « runtime/embedders/openglui/common/opengl.h ('k') | runtime/embedders/openglui/common/support.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698