Browse Source

Fix packed sound datablocks producing invalid SoundBuffers.

pull/162/head
Adam Johnson 5 years ago
parent
commit
cd0b703cc1
Signed by: Hoikas
GPG Key ID: 0B6515D6FF6F271E
  1. 3
      korman/properties/modifiers/sound.py

3
korman/properties/modifiers/sound.py

@ -17,7 +17,6 @@ import bpy
from bpy.props import * from bpy.props import *
from bpy.app.handlers import persistent from bpy.app.handlers import persistent
import math import math
from pathlib import Path
from PyHSPlasma import * from PyHSPlasma import *
from ... import korlib from ... import korlib
@ -303,7 +302,7 @@ class PlasmaSound(idprops.IDPropMixin, bpy.types.PropertyGroup):
def _find_sound_buffer(self, exporter, so, wavHeader, dataSize, channel): def _find_sound_buffer(self, exporter, so, wavHeader, dataSize, channel):
# First, cleanup the file path to not have directories # First, cleanup the file path to not have directories
filename = Path(self._sound.filepath).name filename = bpy.path.basename(self._sound.filepath)
if channel is None: if channel is None:
key_name = filename key_name = filename
else: else:

Loading…
Cancel
Save