separate IBL from skybox and add setBackgroundImage method

This commit is contained in:
Nick Fisher
2022-08-09 09:52:07 +08:00
parent 12edd1f0b2
commit 2cb0d57eed
16 changed files with 1066 additions and 85 deletions

View File

@@ -47,14 +47,27 @@ static void freeResource(ResourceBuffer rb) {
extern "C" {
void load_skybox(void* viewer, const char* skyboxPath, const char* iblPath) {
((FilamentViewer*)viewer)->loadSkybox(skyboxPath, iblPath);
void set_background_image(void* viewer, const char* path) {
((FilamentViewer*)viewer)->setBackgroundImage(path);
}
void load_skybox(void* viewer, const char* skyboxPath) {
((FilamentViewer*)viewer)->loadSkybox(skyboxPath);
}
void load_ibl(void* viewer, const char* iblPath) {
((FilamentViewer*)viewer)->loadIbl(iblPath);
}
void remove_skybox(void* viewer) {
((FilamentViewer*)viewer)->removeSkybox();
}
void remove_ibl(void* viewer) {
((FilamentViewer*)viewer)->removeIbl();
}
void load_glb(void* viewer, const char* assetPath) {
((FilamentViewer*)viewer)->loadGlb(assetPath);
}