<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;background-color:#FFFFFF;font-family:Calibri,Arial,Helvetica,sans-serif;">
<p>So due to complications with a required OS/HW migration, I have been forced to write a JNI that allows a Java UI to play sounds thru pulse audio. Seems to work pretty well.</p>
<p><br>
</p>
<p>So I open a stream, write the sound to the stream. When the user acknowledges the sound I destroy the stream, or the sound is to be interrupted by a more important sound, I destroy the stream and create a new stream for the new sound.</p>
<p><br>
</p>
<p>1. Would it be improper to leave the stream open (for the entire length of time that my user interface is running) and not destroy it? I would just write the new data to the existing stream.</p>
<p>2. I only have a couple of sounds. Ideally I would much prefer to upload my sounds as samples, but my sounds need to be looped if possible. I don't think a sample cache will work for me because I don't see the ability to set a callback to let me know
when a sample cache is done playing so that I can tell it to restart. Please let me know if there is a way?</p>
<p><br>
</p>
<p>Thanks.</p>
</div>
</body>
</html>