Small changes to SUD in PAMGuard

This commit is contained in:
Douglas Gillespie 2022-11-10 17:21:37 +00:00
parent 87cd2cd41f
commit ee24c0ab6b
2 changed files with 4 additions and 4 deletions

View File

@ -109,7 +109,7 @@ public class PamAudioFileManager {
AudioInputStream stream = null; AudioInputStream stream = null;
for (int i = 0; i < pamAudioFileTypes.size(); i++) { for (int i = 0; i < pamAudioFileTypes.size(); i++) {
System.out.println(file.getName() + " " + pamAudioFileTypes.get(i).getName()); // System.out.println(file.getName() + " " + pamAudioFileTypes.get(i).getName());
if (isExtension(file, pamAudioFileTypes.get(i))) { if (isExtension(file, pamAudioFileTypes.get(i))) {
//System.out.println("Get stream for: " +pamAudioFileTypes.get(i).getName()); //System.out.println("Get stream for: " +pamAudioFileTypes.get(i).getName());
stream = pamAudioFileTypes.get(i).getAudioStream(file); stream = pamAudioFileTypes.get(i).getAudioStream(file);

View File

@ -34,7 +34,7 @@ public class SUDFileTime {
* Open the sud file and read it until the first chunk arrive, get the time * Open the sud file and read it until the first chunk arrive, get the time
* from there and close it again. I don't really see another way. * from there and close it again. I don't really see another way.
*/ */
long t1 = System.currentTimeMillis(); // long t1 = System.currentTimeMillis();
sudTime = Long.MIN_VALUE; sudTime = Long.MIN_VALUE;
SudParams sudParams = new SudParams(); SudParams sudParams = new SudParams();
sudParams.saveMeta = false; sudParams.saveMeta = false;
@ -71,8 +71,8 @@ public class SUDFileTime {
// } // }
// //
sudAudioInputStream.close(); sudAudioInputStream.close();
long t2 = System.currentTimeMillis(); // long t2 = System.currentTimeMillis();
System.out.printf("SUD file time %s extracted in %d milliseconds\n", PamCalendar.formatDBDateTime(sudTime), t2-t1); // System.out.printf("SUD file time %s extracted in %d milliseconds\n", PamCalendar.formatDBDateTime(sudTime), t2-t1);
} catch (Exception e) { } catch (Exception e) {
System.err.println("Error getting time from SUD file: " + e.getMessage()); System.err.println("Error getting time from SUD file: " + e.getMessage());