mirror of
https://github.com/whoahq/whoa.git
synced 2026-03-18 13:41:06 +03:00
Adds the platform layer for building whoa as a WebAssembly application: Working: - CMake configuration for WHOA_SYSTEM_WEB with pthreads and ASYNCIFY - Web entry point and HTML shell template - Event loop adapted for emscripten_set_main_loop callback model - WebSocket-based networking (WowConnection over JS WebSocket API) - Sound system stubs (audio not yet implemented) - FetchFS for async file loading from web server - Freetype fixes for WASM compatibility (type mismatches) - Input handling for web canvas Missing (in separate commits): - WebGPU graphics backend (CGxDeviceWebGPU) - WGSL shaders - API selection in Device.cpp
38 lines
788 B
C++
38 lines
788 B
C++
#ifndef SOUND_SOUND_KIT_DEF_HPP
|
|
#define SOUND_SOUND_KIT_DEF_HPP
|
|
|
|
#include "db/Db.hpp"
|
|
#include <cstdint>
|
|
|
|
#if !defined(WHOA_SYSTEM_WEB)
|
|
namespace FMOD {
|
|
class SoundGroup;
|
|
}
|
|
#endif
|
|
|
|
class SOUNDKITDEF {
|
|
public:
|
|
const char* name;
|
|
const char* files[10] = {};
|
|
float minDistance;
|
|
float distanceCutoff;
|
|
float volume;
|
|
int32_t ID;
|
|
uint32_t flags;
|
|
int32_t fileCount = 0;
|
|
int32_t selectedIndex = -1;
|
|
// TODO: 0x48 - 0x94
|
|
#if !defined(WHOA_SYSTEM_WEB)
|
|
FMOD::SoundGroup* soundGroup1;
|
|
FMOD::SoundGroup* soundGroup2;
|
|
#else
|
|
void* soundGroup1;
|
|
void* soundGroup2;
|
|
#endif
|
|
// TODO: 0xA0 - 0xA4
|
|
int32_t advancedID = 0;
|
|
SoundEntriesAdvancedRec* advanced;
|
|
};
|
|
|
|
#endif
|