axmol/CocosDenshion/third_party/fmod/fmoddesignerapi/examples/programmer_selected/main.cpp

111 lines
3.8 KiB
C++
Raw Normal View History

modified: cocos2dx/.cproject modified: cocos2dx/CCConfiguration.cpp modified: cocos2dx/CCConfiguration.h modified: cocos2dx/actions/CCActionGrid3D.cpp modified: cocos2dx/platform/Linux/CCAplication_linux.cpp modified: cocos2dx/platform/Linux/CCAplication_linux.h modified: cocos2dx/platform/Linux/CCImage_Linux.cpp modified: mycreate-android-project.sh new file: post.sh modified: template/android/mycopy_files.sh modified: tests/AppDelegate.cpp new file: tests/test.linux/Res deleted: tests/test.linux/Res/Hello.png deleted: tests/test.linux/Res/Images/BoilingFoam.plist deleted: tests/test.linux/Res/Images/BurstPipe.plist deleted: tests/test.linux/Res/Images/Comet.plist deleted: tests/test.linux/Res/Images/Comet.png deleted: tests/test.linux/Res/Images/ExplodingRing.plist deleted: tests/test.linux/Res/Images/Flower.plist deleted: tests/test.linux/Res/Images/Fog.png deleted: tests/test.linux/Res/Images/Galaxy.plist deleted: tests/test.linux/Res/Images/HelloWorld.png deleted: tests/test.linux/Res/Images/Icon.png deleted: tests/test.linux/Res/Images/LavaFlow.plist deleted: tests/test.linux/Res/Images/Pea.png deleted: tests/test.linux/Res/Images/Phoenix.plist deleted: tests/test.linux/Res/Images/PlanetCute-1024x1024.png deleted: tests/test.linux/Res/Images/SendScoreButton.png deleted: tests/test.linux/Res/Images/SendScoreButtonPressed.png deleted: tests/test.linux/Res/Images/SpinningPeas.plist deleted: tests/test.linux/Res/Images/SpinningPeas.png deleted: tests/test.linux/Res/Images/Spiral.plist deleted: tests/test.linux/Res/Images/SpookyPeas.plist deleted: tests/test.linux/Res/Images/SpookyPeas.png deleted: tests/test.linux/Res/Images/Upsidedown.plist deleted: tests/test.linux/Res/Images/atlastest.png deleted: tests/test.linux/Res/Images/b1-hd.png deleted: tests/test.linux/Res/Images/b1.png deleted: tests/test.linux/Res/Images/b2-hd.png deleted: tests/test.linux/Res/Images/b2.png deleted: tests/test.linux/Res/Images/background.png deleted: tests/test.linux/Res/Images/background1-hd.png deleted: tests/test.linux/Res/Images/background1.png deleted: tests/test.linux/Res/Images/background2-hd.png deleted: tests/test.linux/Res/Images/background2.png deleted: tests/test.linux/Res/Images/background3-hd.png deleted: tests/test.linux/Res/Images/background3.png deleted: tests/test.linux/Res/Images/ball-hd.png deleted: tests/test.linux/Res/Images/ball.png deleted: tests/test.linux/Res/Images/bitmapFontTest3.fnt deleted: tests/test.linux/Res/Images/bitmapFontTest3.png deleted: tests/test.linux/Res/Images/blocks-hd.png deleted: tests/test.linux/Res/Images/blocks.png deleted: tests/test.linux/Res/Images/btn-about-normal.png deleted: tests/test.linux/Res/Images/btn-about-selected.png deleted: tests/test.linux/Res/Images/btn-highscores-normal.png deleted: tests/test.linux/Res/Images/btn-highscores-selected.png deleted: tests/test.linux/Res/Images/btn-play-normal.png deleted: tests/test.linux/Res/Images/btn-play-selected.png deleted: tests/test.linux/Res/Images/bugs/RetinaDisplay.jpg deleted: tests/test.linux/Res/Images/bugs/bug886.jpg deleted: tests/test.linux/Res/Images/bugs/bug886.png deleted: tests/test.linux/Res/Images/bugs/circle-hd.plist deleted: tests/test.linux/Res/Images/bugs/circle-hd.png deleted: tests/test.linux/Res/Images/bugs/circle.plist deleted: tests/test.linux/Res/Images/bugs/circle.png deleted: tests/test.linux/Res/Images/bugs/corner.png deleted: tests/test.linux/Res/Images/bugs/edge.png deleted: tests/test.linux/Res/Images/bugs/fill.png deleted: tests/test.linux/Res/Images/bugs/picture-hd.png deleted: tests/test.linux/Res/Images/bugs/picture.png deleted: tests/test.linux/Res/Images/close-hd.png deleted: tests/test.linux/Res/Images/close.png deleted: tests/test.linux/Res/Images/debian.plist deleted: tests/test.linux/Res/Images/f1-hd.png deleted: tests/test.linux/Res/Images/f1.png deleted: tests/test.linux/Res/Images/f2-hd.png deleted: tests/test.linux/Res/Images/f2.png deleted: tests/test.linux/Res/Images/fire-grayscale.png deleted: tests/test.linux/Res/Images/fire.png deleted: tests/test.linux/Res/Images/fps_images.png deleted: tests/test.linux/Res/Images/grossini-hd.png deleted: tests/test.linux/Res/Images/grossini.png deleted: tests/test.linux/Res/Images/grossini_128x256_mipmap.pvr deleted: tests/test.linux/Res/Images/grossini_dance_01.png deleted: tests/test.linux/Res/Images/grossini_dance_02.png deleted: tests/test.linux/Res/Images/grossini_dance_03.png deleted: tests/test.linux/Res/Images/grossini_dance_04.png deleted: tests/test.linux/Res/Images/grossini_dance_05.png deleted: tests/test.linux/Res/Images/grossini_dance_06.png deleted: tests/test.linux/Res/Images/grossini_dance_07.png deleted: tests/test.linux/Res/Images/grossini_dance_08.png deleted: tests/test.linux/Res/Images/grossini_dance_09.png deleted: tests/test.linux/Res/Images/grossini_dance_10.png deleted: tests/test.linux/Res/Images/grossini_dance_11.png deleted: tests/test.linux/Res/Images/grossini_dance_12.png deleted: tests/test.linux/Res/Images/grossini_dance_13.png deleted: tests/test.linux/Res/Images/grossini_dance_14.png deleted: tests/test.linux/Res/Images/grossini_dance_atlas-hd.png deleted: tests/test.linux/Res/Images/grossini_dance_atlas-mono.png deleted: tests/test.linux/Res/Images/grossini_dance_atlas.png deleted: tests/test.linux/Res/Images/grossini_dance_atlas_nomipmap.png deleted: tests/test.linux/Res/Images/grossini_pvr_rgba4444.pvr deleted: tests/test.linux/Res/Images/grossini_pvr_rgba8888.pvr deleted: tests/test.linux/Res/Images/grossinis_sister1-hd.png deleted: tests/test.linux/Res/Images/grossinis_sister1-testalpha.png deleted: tests/test.linux/Res/Images/grossinis_sister1-testalpha.ppng deleted: tests/test.linux/Res/Images/grossinis_sister1.png deleted: tests/test.linux/Res/Images/grossinis_sister2-hd.png deleted: tests/test.linux/Res/Images/grossinis_sister2.png deleted: tests/test.linux/Res/Images/landscape-1024x1024.png deleted: tests/test.linux/Res/Images/logo-mipmap.pvr deleted: tests/test.linux/Res/Images/logo-nomipmap.pvr deleted: tests/test.linux/Res/Images/menuitemsprite.png deleted: tests/test.linux/Res/Images/paddle-hd.png deleted: tests/test.linux/Res/Images/paddle.png deleted: tests/test.linux/Res/Images/particles-hd.png deleted: tests/test.linux/Res/Images/particles.png deleted: tests/test.linux/Res/Images/pattern1.png deleted: tests/test.linux/Res/Images/piece.png deleted: tests/test.linux/Res/Images/powered.png deleted: tests/test.linux/Res/Images/r1-hd.png deleted: tests/test.linux/Res/Images/r1.png deleted: tests/test.linux/Res/Images/r2-hd.png deleted: tests/test.linux/Res/Images/r2.png deleted: tests/test.linux/Res/Images/snow.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-0-0.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-0-1.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-0-2.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-0-3.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-0-4.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-0-5.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-0-6.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-0-7.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-1-0.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-1-1.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-1-2.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-1-3.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-1-4.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-1-5.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-1-6.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-1-7.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-2-0.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-2-1.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-2-2.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-2-3.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-2-4.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-2-5.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-2-6.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-2-7.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-3-0.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-3-1.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-3-2.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-3-3.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-3-4.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-3-5.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-3-6.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-3-7.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-4-0.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-4-1.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-4-2.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-4-3.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-4-4.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-4-5.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-4-6.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-4-7.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-5-0.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-5-1.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-5-2.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-5-3.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-5-4.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-5-5.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-5-6.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-5-7.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-6-0.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-6-1.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-6-2.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-6-3.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-6-4.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-6-5.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-6-6.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-6-7.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-7-0.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-7-1.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-7-2.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-7-3.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-7-4.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-7-5.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-7-6.png deleted: tests/test.linux/Res/Images/sprites_test/sprite-7-7.png deleted: tests/test.linux/Res/Images/spritesheet1.png deleted: tests/test.linux/Res/Images/stars-grayscale.png deleted: tests/test.linux/Res/Images/stars.png deleted: tests/test.linux/Res/Images/stars2-grayscale.png deleted: tests/test.linux/Res/Images/stars2.png deleted: tests/test.linux/Res/Images/streak.png deleted: tests/test.linux/Res/Images/test-rgba1.png deleted: tests/test.linux/Res/Images/test_blend.png deleted: tests/test.linux/Res/Images/test_image-bad_encoding.pvr deleted: tests/test.linux/Res/Images/test_image.jpeg deleted: tests/test.linux/Res/Images/test_image.png deleted: tests/test.linux/Res/Images/test_image.pvr deleted: tests/test.linux/Res/Images/test_image.pvrraw deleted: tests/test.linux/Res/Images/test_image_a8.pvr deleted: tests/test.linux/Res/Images/test_image_ai88.pvr deleted: tests/test.linux/Res/Images/test_image_bgra8888.pvr deleted: tests/test.linux/Res/Images/test_image_i8.pvr deleted: tests/test.linux/Res/Images/test_image_pvrtc2bpp.pvr deleted: tests/test.linux/Res/Images/test_image_pvrtc4bpp.pvr deleted: tests/test.linux/Res/Images/test_image_rgb565.pvr deleted: tests/test.linux/Res/Images/test_image_rgba4444.pvr deleted: tests/test.linux/Res/Images/test_image_rgba4444.pvr.ccz deleted: tests/test.linux/Res/Images/test_image_rgba4444.pvr.gz deleted: tests/test.linux/Res/Images/test_image_rgba4444_mipmap.pvr deleted: tests/test.linux/Res/Images/test_image_rgba5551.pvr deleted: tests/test.linux/Res/Images/test_image_rgba8888.pvr deleted: tests/test.linux/Res/Images/texture1024x1024.png deleted: tests/test.linux/Res/Images/texture2048x2048.png deleted: tests/test.linux/Res/Images/texture512x512.png deleted: tests/test.linux/Res/TileMaps/fixed-ortho-test2.png deleted: tests/test.linux/Res/TileMaps/hexa-test.tmx deleted: tests/test.linux/Res/TileMaps/hexa-tiles.png deleted: tests/test.linux/Res/TileMaps/iso-test-bug787.tmx deleted: tests/test.linux/Res/TileMaps/iso-test-movelayer.tmx deleted: tests/test.linux/Res/TileMaps/iso-test-objectgroup.tmx deleted: tests/test.linux/Res/TileMaps/iso-test-vertexz.tmx deleted: tests/test.linux/Res/TileMaps/iso-test-zorder.tmx deleted: tests/test.linux/Res/TileMaps/iso-test.png deleted: tests/test.linux/Res/TileMaps/iso-test.tmx deleted: tests/test.linux/Res/TileMaps/iso-test1.tmx deleted: tests/test.linux/Res/TileMaps/iso-test2-uncompressed.tmx deleted: tests/test.linux/Res/TileMaps/iso-test2.png deleted: tests/test.linux/Res/TileMaps/iso-test2.tmx deleted: tests/test.linux/Res/TileMaps/iso.png deleted: tests/test.linux/Res/TileMaps/levelmap.tga deleted: tests/test.linux/Res/TileMaps/ortho-objects.tmx deleted: tests/test.linux/Res/TileMaps/ortho-test1.png deleted: tests/test.linux/Res/TileMaps/ortho-test1_bw.png deleted: tests/test.linux/Res/TileMaps/ortho-test2.png deleted: tests/test.linux/Res/TileMaps/orthogonal-test-movelayer.tmx deleted: tests/test.linux/Res/TileMaps/orthogonal-test-vertexz.tmx deleted: tests/test.linux/Res/TileMaps/orthogonal-test-zorder.tmx deleted: tests/test.linux/Res/TileMaps/orthogonal-test1.tmx deleted: tests/test.linux/Res/TileMaps/orthogonal-test1.tsx deleted: tests/test.linux/Res/TileMaps/orthogonal-test2.tmx deleted: tests/test.linux/Res/TileMaps/orthogonal-test3.tmx deleted: tests/test.linux/Res/TileMaps/orthogonal-test4-hd.tmx deleted: tests/test.linux/Res/TileMaps/orthogonal-test4.tmx deleted: tests/test.linux/Res/TileMaps/orthogonal-test5.tmx deleted: tests/test.linux/Res/TileMaps/orthogonal-test6-hd.tmx deleted: tests/test.linux/Res/TileMaps/orthogonal-test6.tmx deleted: tests/test.linux/Res/TileMaps/test-object-layer.tmx deleted: tests/test.linux/Res/TileMaps/tiles-hd.png deleted: tests/test.linux/Res/TileMaps/tiles.png deleted: tests/test.linux/Res/TileMaps/tmw_desert_spacing-hd.png deleted: tests/test.linux/Res/TileMaps/tmw_desert_spacing.png deleted: tests/test.linux/Res/animations/dragon_animation-hd.png deleted: tests/test.linux/Res/animations/dragon_animation.png deleted: tests/test.linux/Res/animations/ghosts.plist deleted: tests/test.linux/Res/animations/ghosts.png deleted: tests/test.linux/Res/animations/grossini-aliases.plist deleted: tests/test.linux/Res/animations/grossini-aliases.png deleted: tests/test.linux/Res/animations/grossini.plist deleted: tests/test.linux/Res/animations/grossini.plist.xml deleted: tests/test.linux/Res/animations/grossini.png deleted: tests/test.linux/Res/animations/grossini.ztp deleted: tests/test.linux/Res/animations/grossini_blue.plist deleted: tests/test.linux/Res/animations/grossini_blue.png deleted: tests/test.linux/Res/animations/grossini_family.plist deleted: tests/test.linux/Res/animations/grossini_family.png deleted: tests/test.linux/Res/animations/grossini_gray.plist deleted: tests/test.linux/Res/animations/grossini_gray.png deleted: tests/test.linux/Res/app.config.txt deleted: tests/test.linux/Res/background.mp3 deleted: tests/test.linux/Res/effect1.wav deleted: tests/test.linux/Res/effect2.ogg deleted: tests/test.linux/Res/fonts/A Damn Mess.ttf deleted: tests/test.linux/Res/fonts/Abberancy.ttf deleted: tests/test.linux/Res/fonts/Abduction.ttf deleted: tests/test.linux/Res/fonts/Paint Boy.ttf deleted: tests/test.linux/Res/fonts/Schwarzwald Regular.ttf deleted: tests/test.linux/Res/fonts/Scissor Cuts.ttf deleted: tests/test.linux/Res/fonts/arial16.fnt deleted: tests/test.linux/Res/fonts/arial16.png deleted: tests/test.linux/Res/fonts/bitmapFontTest.fnt deleted: tests/test.linux/Res/fonts/bitmapFontTest.png deleted: tests/test.linux/Res/fonts/bitmapFontTest2.fnt deleted: tests/test.linux/Res/fonts/bitmapFontTest2.png deleted: tests/test.linux/Res/fonts/bitmapFontTest3.fnt deleted: tests/test.linux/Res/fonts/bitmapFontTest3.png deleted: tests/test.linux/Res/fonts/bitmapFontTest4.fnt deleted: tests/test.linux/Res/fonts/bitmapFontTest4.png deleted: tests/test.linux/Res/fonts/bitmapFontTest5.fnt deleted: tests/test.linux/Res/fonts/bitmapFontTest5.png deleted: tests/test.linux/Res/fonts/fps_images-hd.png deleted: tests/test.linux/Res/fonts/fps_images.png deleted: tests/test.linux/Res/fonts/futura-48.fnt deleted: tests/test.linux/Res/fonts/futura-48.png deleted: tests/test.linux/Res/fonts/konqa32-hd.fnt deleted: tests/test.linux/Res/fonts/konqa32-hd.png deleted: tests/test.linux/Res/fonts/konqa32.fnt deleted: tests/test.linux/Res/fonts/konqa32.png deleted: tests/test.linux/Res/fonts/larabie-16-hd.png deleted: tests/test.linux/Res/fonts/larabie-16.png deleted: tests/test.linux/Res/fonts/tuffy_bold_italic-charmap-hd.png deleted: tests/test.linux/Res/fonts/tuffy_bold_italic-charmap.png deleted: tests/test.linux/Res/music.mid deleted: tests/test.linux/Res/zwoptex/grossini-generic.plist deleted: tests/test.linux/Res/zwoptex/grossini-generic.png deleted: tests/test.linux/Res/zwoptex/grossini.plist deleted: tests/test.linux/Res/zwoptex/grossini.png CocosDenshion/AndroidDebug/ CocosDenshion/AndroidRelease/ HelloCocos2dx/AndroidDebug/2 HelloCocos2dx/android/assets HelloCocos2dx/postCompiled.sh installLinuxLib.sh
2011-08-23 11:28:04 +08:00
/*=============================================================================
Programmer Selected Sound Definition Example
Copyright (c), Firelight Technologies Pty, Ltd 2007-2011.
Demonstrates how to use the "programmer selected sound definition" feature of
the FMOD event system
=============================================================================*/
#include "../../../examples/common/wincompat.h"
#include "../../api/inc/fmod_event.hpp"
#include "../../../api/inc/fmod_errors.h"
const char *MEDIA_PATH = "../media/";
static int g_sounddef_entry_index = 0;
void ERRCHECK(FMOD_RESULT result)
{
if (result != FMOD_OK)
{
printf("FMOD error! (%d) %s\n", result, FMOD_ErrorString(result));
exit(-1);
}
}
FMOD_RESULT F_CALLBACK eventcallback(FMOD_EVENT *event, FMOD_EVENT_CALLBACKTYPE type, void *param1, void *param2, void *userdata)
{
switch (type)
{
case FMOD_EVENT_CALLBACKTYPE_SOUNDDEF_SELECTINDEX :
{
char *name = (char *)param1; // [in] (char *) name of sound definition
int *index = (int *)param2; // [out] (int *) the sounddef entry index to use
*index = (g_sounddef_entry_index < *index) ? g_sounddef_entry_index : *index - 1;
printf("FMOD_EVENT_CALLBACKTYPE_SOUNDDEF_SELECTINDEX '%s': %d\n", name, *index);
break;
}
}
return FMOD_OK;
}
int main(int argc, char *argv[])
{
FMOD_RESULT result;
FMOD::EventSystem *eventsystem;
FMOD::EventGroup *eventgroup;
FMOD::Event *event;
int key;
ERRCHECK(result = FMOD::EventSystem_Create(&eventsystem));
ERRCHECK(result = eventsystem->init(64, FMOD_INIT_NORMAL, 0, FMOD_EVENT_INIT_NORMAL));
ERRCHECK(result = eventsystem->setMediaPath((char *)MEDIA_PATH));
ERRCHECK(result = eventsystem->load("examples.fev", 0, 0));
ERRCHECK(result = eventsystem->getGroup("examples/FeatureDemonstration/SequencingAndStitching", FMOD_EVENT_DEFAULT, &eventgroup));
printf("======================================================================\n");
printf("Programmer Selected Sound Definition.\n");
printf("Copyright (c) Firelight Technologies 2006-2011.\n");
printf("----------------------------------------------------------------------\n");
printf("Press 'Space' to start the 'Programmer Selected' event\n");
printf("Press '>' to increase sound definition entry index\n");
printf("Press '<' to decrease sound definition entry index\n");
printf("Press 'Esc' to quit\n");
printf("======================================================================\n");
printf("Sound definition entry index = %d\n", g_sounddef_entry_index);
key = 0;
do
{
if (_kbhit())
{
key = _getch();
switch(key)
{
case ' ' :
ERRCHECK(result = eventgroup->getEvent("ProgrammerSelected", FMOD_EVENT_DEFAULT, &event));
ERRCHECK(result = event->setCallback(eventcallback, 0));
ERRCHECK(result = event->start());
break;
case '>' :
++g_sounddef_entry_index;
printf("Sound definition entry index = %d\n", g_sounddef_entry_index);
break;
case '<' :
--g_sounddef_entry_index;
g_sounddef_entry_index = (g_sounddef_entry_index < 0) ? 0 : g_sounddef_entry_index;
printf("Sound definition entry index = %d\n", g_sounddef_entry_index);
break;
}
}
ERRCHECK(result = eventsystem->update());
fflush(stdout);
Sleep(10);
} while (key != 27);
ERRCHECK(result = eventsystem->unload());
ERRCHECK(result = eventsystem->release());
return 0;
}