Sound don`t working in Heaps engine

Sound don`t working (format wav).
Example:
var res = hxd.Res.sound;
var sound = res.play(true);

I heard sound some seconds and after don`t heard.
In function update (extends hxd.App) I logging in console sound.position;
trace(sound.position);
But this log return 0;

Sintax and file right, becose I testing many files with format wav.

Have you tried mp3 and ogg? Wav is a bit of a strange format - maybe your files are unsupported type of wav?

I tried wav and ogg. Format mp3 my app don’t see, but hxd.res.Sound.supportedFormat(Mp3) return true.

Same problem:
heaps.io(1.9.1) doesn’t see .mp3 files, so i renamed it and loaded using hxd.Res.load, ogg files is fine. Didn’t test wav.
Sound.supportedFormat(Mp3) and Sound.supportedFormat(OggVorbis) both returns true.
As Pasha said in both cases i hear only first second of audio. play().position always 0. After that the audio doesn’t work at all even if i use play() again.
If i am playing sound with delay:

haxe.Timer.delay(() -> {
	trace("play");
	audio.play();
}, 5000);

I getting same result.
hlopenal is 1.5.0
hashlink version is 1.12.0

1 Like

Yes thank you. Didn’t notice it.