[med-svn] [praat] 01/05: Imported Upstream version 5.3.85

Rafael Laboissière rlaboiss-guest at moszumanska.debian.org
Sat Sep 27 07:53:47 UTC 2014


This is an automated email from the git hooks/post-receive script.

rlaboiss-guest pushed a commit to branch master
in repository praat.

commit fffaf74379907689f6c255f55a1f032f8c279489
Author: Rafael Laboissiere <rafael at laboissiere.net>
Date:   Mon Sep 22 03:56:11 2014 -0300

    Imported Upstream version 5.3.85
---
 LPC/LPC_and_Tube.cpp                               |   8 +-
 LPC/praat_LPC_init.cpp                             |   9 +-
 ...st_onewayAnova.praat => test_OnewayAnova.praat} |   4 +-
 dwtest/test_TextGrid_extensions.praat              |  25 ++--
 dwtools/DataModeler.cpp                            |  14 +--
 dwtools/DataModeler.h                              |   4 +-
 dwtools/Sound_extensions.cpp                       |  21 +++-
 dwtools/TextGrid_extensions.cpp                    |  29 ++++-
 dwtools/manual_Permutation.cpp                     |  33 ++++--
 dwtools/praat_DataModeler_init.cpp                 |  55 +++------
 fon/RunnerMFC.cpp                                  |   2 +-
 fon/TextGrid.cpp                                   |   3 +-
 fon/manual_tutorials.cpp                           |   6 +-
 fon/praat_TextGrid_init.cpp                        |   2 +-
 num/NUMrandom.cpp                                  | 126 ++++++++++-----------
 sys/Editor.cpp                                     |   4 +-
 sys/Graphics_image.cpp                             |   6 +-
 sys/GuiFileSelect.cpp                              |   8 +-
 sys/melder_audio.cpp                               |   2 +-
 sys/praat_version.h                                |   8 +-
 20 files changed, 196 insertions(+), 173 deletions(-)

diff --git a/LPC/LPC_and_Tube.cpp b/LPC/LPC_and_Tube.cpp
index f3db194..dc14776 100644
--- a/LPC/LPC_and_Tube.cpp
+++ b/LPC/LPC_and_Tube.cpp
@@ -1,6 +1,6 @@
 /* LPC_and_Tube.cpp
  *
- * Copyright (C) 1993-2012 David Weenink
+ * Copyright (C) 1993-2012, 2014 David Weenink
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -79,10 +79,8 @@ double VocalTract_and_LPC_Frame_getMatchingLength (VocalTract me, LPC_Frame thee
 		LPC_Frame_into_Spectrum (thee, lps.peek(), 0, 50);
 		autoSpectrumTier vtst = Spectrum_to_SpectrumTier_peaks (vts.peek());
 		autoSpectrumTier lpst = Spectrum_to_SpectrumTier_peaks (lps.peek());
-		RealPoint point = vtst -> point (1); double vt_f1 = point -> number;
-		point = vtst -> point (2); double vt_f2 = point -> number;
-		point = lpst -> point (1); double lp_f1 = point -> number;
-		point = lpst -> point (2); double lp_f2 = point -> number;
+		double vt_f1 = vtst -> point(1) -> number, vt_f2 = vtst -> point(2) -> number;
+		double lp_f1 = lpst -> point(1) -> number, lp_f2 = lpst -> point(2) -> number;
 		double df1 = lp_f1 - vt_f1, df2 =  lp_f2 - vt_f2, df = 0.5 * (df1 + df2);
 		double dl = - df / lp_f2;
 		return my dx * my nx * (1 + dl);
diff --git a/LPC/praat_LPC_init.cpp b/LPC/praat_LPC_init.cpp
index 0d609c2..643dabd 100644
--- a/LPC/praat_LPC_init.cpp
+++ b/LPC/praat_LPC_init.cpp
@@ -1,6 +1,6 @@
 /* praat_LPC_init.cpp
  *
- * Copyright (C) 1994-2013 David Weenink
+ * Copyright (C) 1994-2014 David Weenink
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -1067,11 +1067,7 @@ END
 DIRECT (VocalTract_getLength)
 	LOOP {
 		iam (VocalTract);
-		double length = my xmax - my xmin;
-		if (length <= 0.02) {
-			length = NUMundefined;
-		}
-		Melder_information (Melder_double (length), L" m");
+		Melder_information (Melder_double (my xmax - my xmin), L" m");
 	}
 END
 
@@ -1324,6 +1320,7 @@ void praat_uvafon_LPC_init (void) {
 	praat_addAction1 (classVocalTractTier, 0, L"To LPC...", 0, 0, DO_VocalTractTier_to_LPC);
 	praat_addAction1 (classVocalTractTier, 0, L"To VocalTract...", 0, 0, DO_VocalTractTier_to_VocalTract);
 	praat_addAction2 (classVocalTractTier, 1, classVocalTract, 1, L"Add VocalTract...", 0, 0, DO_VocalTractTier_addVocalTract);
+
 	INCLUDE_MANPAGES (manual_LPC)
 	INCLUDE_MANPAGES (manual_DataModeler)
 
diff --git a/dwtest/test_onewayAnova.praat b/dwtest/test_OnewayAnova.praat
similarity index 93%
rename from dwtest/test_onewayAnova.praat
rename to dwtest/test_OnewayAnova.praat
index e5ff87d..2868063 100644
--- a/dwtest/test_onewayAnova.praat
+++ b/dwtest/test_OnewayAnova.praat
@@ -1,4 +1,4 @@
-# test_onewayAnova.praat
+# test_OnewayAnova.praat
 # djmw 20120625
 
 printline One-way Anova test
@@ -14,7 +14,7 @@ total = extractNumber (report$, "Total")
 assert abs (between-22.57) < 0.01
 assert abs (within - 878.93) < 0.01
 assert abs (total - 901.5) < 0.1
-Remove
+
 printline One-way Anova test OK
 
 
diff --git a/dwtest/test_TextGrid_extensions.praat b/dwtest/test_TextGrid_extensions.praat
index efb4ff9..c62c4b0 100644
--- a/dwtest/test_TextGrid_extensions.praat
+++ b/dwtest/test_TextGrid_extensions.praat
@@ -1,31 +1,30 @@
 # test_TextGrid_extensions.praat
-# djmw 20110523
+# djmw 20110523, 20140904
 
-printline test_TextGrid_extensions
+appendInfoLine: "test_TextGrid_extensions"
 
-s = Read Strings from raw text file... TIMIT_train_dr1_fcjf0_sa1.phn
+s = Read Strings from raw text file: "TIMIT_train_dr1_fcjf0_sa1.phn"
 ns = Get number of strings
-tg = Read from file... TIMIT_train_dr1_fcjf0_sa1.phn
+tg = Read from file: "TIMIT_train_dr1_fcjf0_sa1.phn"
 
 ntiers = Get number of tiers
 assert ntiers = 2
 
-nints = Get number of intervals... 1
+nints = Get number of intervals: 1
 
 
 assert nints = ns
 
 for i to ns
-	select s
-	string$ = Get string... i
+	selectObject: s
+	string$ = Get string: i
 	slabel$ = replace_regex$ (string$, "[0-9\s]", "", 0)
-	select tg
-	tglabel$ = Get label of interval... 1 i
+	selectObject: tg
+	tglabel$ = Get label of interval: 1, i
 	assert slabel$ = tglabel$
 endfor
-select s
-plus tg
-Remove
+removeObject: s, tg
 
-printline test_TextGrid_extensions OK
+
+appendInfoLine: "test_TextGrid_extensions OK"
 
diff --git a/dwtools/DataModeler.cpp b/dwtools/DataModeler.cpp
index 11f65fc..1b8b4c8 100644
--- a/dwtools/DataModeler.cpp
+++ b/dwtools/DataModeler.cpp
@@ -1563,7 +1563,7 @@ double FormantModeler_getSmoothnessValue (FormantModeler me, long fromFormant, l
 		double ndof, var = FormantModeler_getVarianceOfParameters (me, fromFormant, toFormant, 1, numberOfParametersPerTrack, &nofp);
 		double chisq = FormantModeler_getChiSquaredQ (me, fromFormant, toFormant, TRUE, NULL, &ndof);
 		if (NUMdefined (var) && NUMdefined (chisq) && nofp > 0) {
-			smoothness = sqrt (pow (var / nofp, power) * chisq / ndof);
+			smoothness = log10 (pow (var / nofp, power) * (chisq / ndof));
 		}
 	}
 	return smoothness;
@@ -1773,7 +1773,7 @@ void PitchModeler_draw (PitchModeler me, Graphics g, double tmin, double tmax, d
 	}
 }
 
-Formant Sound_to_Formant_interval (Sound me, double startTime, double endTime, double windowLength, double timeStep, double minFreq, double maxFreq, long numberOfFrequencySteps, double preemphasisFrequency, long numberOfFormantTracks, long numberOfParametersPerTrack, int weighData, double numberOfSigmas, double power, bool useConstraints, double minF1, double maxF1, double minF2, double maxF2, double minF3, double *ceiling) {
+Formant Sound_to_Formant_interval (Sound me, double startTime, double endTime, double windowLength, double timeStep, double minFreq, double maxFreq, long numberOfFrequencySteps, double preemphasisFrequency, long numberOfFormantTracks, long numberOfParametersPerTrack, int weighData, double numberOfSigmas, double power, bool useConstraints, double minF1, double maxF1, double minF2, double maxF2, double minF3, double *optimalCeiling) {
 	try {
 		// parameter check
 		if (endTime <= startTime) {
@@ -1818,8 +1818,8 @@ Formant Sound_to_Formant_interval (Sound me, double startTime, double endTime, d
 		}
 		autoFormant thee = Formant_extractPart ((Formant) formants -> item[i_best], startTime, endTime);
 		Melder_progressOn ();
-		if (ceiling) {
-			*ceiling = ceiling_best;
+		if (optimalCeiling) {
+			*optimalCeiling = ceiling_best;
 		}
 		return thee.transfer();
 	} catch (MelderError) {
@@ -1827,7 +1827,7 @@ Formant Sound_to_Formant_interval (Sound me, double startTime, double endTime, d
 	}
 }
 
-Formant Sound_to_Formant_interval_robust (Sound me, double startTime, double endTime, double windowLength, double timeStep, double minFreq, double maxFreq, long numberOfFrequencySteps, double preemphasisFrequency, long numberOfFormantTracks, long numberOfParametersPerTrack, int weighData, double numberOfSigmas, double power, bool useConstraints, double minF1, double maxF1, double minF2, double maxF2, double minF3, double *ceiling) {
+Formant Sound_to_Formant_interval_robust (Sound me, double startTime, double endTime, double windowLength, double timeStep, double minFreq, double maxFreq, long numberOfFrequencySteps, double preemphasisFrequency, long numberOfFormantTracks, long numberOfParametersPerTrack, int weighData, double numberOfSigmas, double power, bool useConstraints, double minF1, double maxF1, double minF2, double maxF2, double minF3, double *optimalCeiling) {
 	try {
 		// parameter check
 		if (endTime <= startTime) {
@@ -1872,8 +1872,8 @@ Formant Sound_to_Formant_interval_robust (Sound me, double startTime, double end
 		}
 		autoFormant thee = Formant_extractPart ((Formant) formants -> item[i_best], startTime, endTime);
 		Melder_progressOn ();
-		if (ceiling) {
-			*ceiling = ceiling_best;
+		if (optimalCeiling) {
+			*optimalCeiling = ceiling_best;
 		}
 		return thee.transfer();
 	} catch (MelderError) {
diff --git a/dwtools/DataModeler.h b/dwtools/DataModeler.h
index 36a82ac..7d326e1 100644
--- a/dwtools/DataModeler.h
+++ b/dwtools/DataModeler.h
@@ -203,7 +203,7 @@ void PitchModeler_draw (PitchModeler me, Graphics g, double tmin, double tmax, d
 
 DataModeler Table_to_DataModeler (Table me, double xmin, double xmax, long xcolumn, long ycolumn, long scolumn, long numberOfParameters, int type);
 
-Formant Sound_to_Formant_interval (Sound me, double startTime, double endTime, double windowLength, double timeStep, double minFreq, double maxFreq, long numberOfFrequencySteps, double preemphasisFrequency, long numberOfFormantTracks, long numberOfParametersPerTrack, int weighData, double numberOfSigmas, double power, bool useConstraints, double minF1, double maxF1, double minF2, double maxF2, double minF3, double *ceiling);
+Formant Sound_to_Formant_interval (Sound me, double startTime, double endTime, double windowLength, double timeStep, double minFreq, double maxFreq, long numberOfFrequencySteps, double preemphasisFrequency, long numberOfFormantTracks, long numberOfParametersPerTrack, int weighData, double numberOfSigmas, double power, bool useConstraints, double minF1, double maxF1, double minF2, double maxF2, double minF3, double *optimalCeiling);
 
-Formant Sound_to_Formant_interval_robust (Sound me, double startTime, double endTime, double windowLength, double timeStep, double minFreq, double maxFreq, long numberOfFrequencySteps, double preemphasisFrequency, long numberOfFormantTracks, long numberOfParametersPerTrack, int weighData, double numberOfSigmas, double power, bool useConstraints, double minF1, double maxF1, double minF2, double maxF2, double minF3, double *ceiling);
+Formant Sound_to_Formant_interval_robust (Sound me, double startTime, double endTime, double windowLength, double timeStep, double minFreq, double maxFreq, long numberOfFrequencySteps, double preemphasisFrequency, long numberOfFormantTracks, long numberOfParametersPerTrack, int weighData, double numberOfSigmas, double power, bool useConstraints, double minF1, double maxF1, double minF2, double maxF2, double minF3, double *optimalCeiling);
 #endif /* _DataModeler_h_ */
diff --git a/dwtools/Sound_extensions.cpp b/dwtools/Sound_extensions.cpp
index 94576b3..2426aa4 100644
--- a/dwtools/Sound_extensions.cpp
+++ b/dwtools/Sound_extensions.cpp
@@ -69,10 +69,8 @@
 #include "Manipulation.h"
 #include "NUM2.h"
 
-#ifdef linux
 //#include <pulse/simple.h>
 //#include <pulse/error.h>
-#endif
 
 #define MAX_T  0.02000000001   /* Maximum interval between two voice pulses (otherwise voiceless). */
 
@@ -2277,5 +2275,24 @@ void Sound_playAsFrequencyShifted (Sound me, double shiftBy, double newSamplingF
 	}
 }
 
+/*
+void Sound_playAsPulse (Sound me, long fromTime, long toTime)  {
+	 static const pa_sample_spec ss = {
+		.format = PA_SAMPLE_S16LE,
+		.rate = 44100,
+		.channels = 2
+	};
+	long ixmin, ixmax, numberOfChannels = my ny > 2 ? 2 : my ny;
+	long numberOfSamples = Sampled_getWindowSamples (me, fromTime, toTime, &ixmin, &ixmax);
+	if (numberOfSamples < 1) {
+		return;
+	}
+	long playBufferSize = 1000 * numberOfChannels, indexInPlaybuffer = 1;
+	autoNUMvector<float> buffer (1, numberOfChannels * playBufferSize);
+	pa_simple *s = NULL;
+	int ret = 1;
+	int error;
 
+}
+*/
 /* End of file Sound_extensions.cpp */
diff --git a/dwtools/TextGrid_extensions.cpp b/dwtools/TextGrid_extensions.cpp
index 4c74644..b435fa4 100644
--- a/dwtools/TextGrid_extensions.cpp
+++ b/dwtools/TextGrid_extensions.cpp
@@ -656,10 +656,23 @@ void TextGrid_changeLabels (TextGrid me, int tier, long from, long to, const wch
 	}
 }
 
+static void IntervalTier_checkStartAndEndTime (IntervalTier me) {
+	TextInterval ti = (TextInterval) my intervals -> item[1];
+	if (my xmin != ti -> xmin) {
+		Melder_throw (me, ": start time of first interval doesn't match start time of the tier.");
+	}
+	ti = (TextInterval) my intervals -> item[my intervals -> size];
+	if (my xmax != ti -> xmax) {
+		Melder_throw (me, ": end time of last interval doesn't match end time of the tier.");
+	}
+}
+
 // Precondition: if (preserveTimes) { my xmax <= thy xmin }
 // Postcondition: my xmin preserved
 void IntervalTiers_append_inline (IntervalTier me, IntervalTier thee, bool preserveTimes) {
 	try {
+		IntervalTier_checkStartAndEndTime (me); // start/end time of first/last interval should match with tier
+		IntervalTier_checkStartAndEndTime (thee);
         double xmax_previous = my xmax, time_shift = my xmax - thy xmin;
 		if (preserveTimes && my xmax < thy xmin) {
 			autoTextInterval connection = TextInterval_create (my xmax, thy xmin, L"");
@@ -709,6 +722,17 @@ void TextTiers_append_inline (TextTier me, TextTier thee, bool preserveTimes) {
 	}
 }
 
+static void TextGrid_checkStartAndEndTimesOfTiers (TextGrid me) {
+	for (long itier = 1; itier <= my tiers -> size; itier++) {
+		Function tier = (Function) my tiers -> item[itier];
+		if (tier -> xmin != my xmin) {
+			Melder_throw (me, ": the start time of tier ", Melder_integer (itier), " does not match the start time of its TextGrid.");
+		} else if (tier -> xmax != my xmax) {
+			Melder_throw (me, ": the end time of tier ", Melder_integer (itier), " does not match the end time of its TextGrid.");
+		}
+	}
+}
+
 void TextGrids_append_inline (TextGrid me, TextGrid thee, bool preserveTimes)
 {
 	try {
@@ -718,11 +742,14 @@ void TextGrids_append_inline (TextGrid me, TextGrid thee, bool preserveTimes)
 		if (preserveTimes && thy xmin < my xmax) {
 			Melder_throw ("The start time of the second TextGrid can't be earlier than the end time of the first one if you want to preserve times.");
 		}
-		// all tiers must have the same end time
+		
+		TextGrid_checkStartAndEndTimesOfTiers (me); // all tiers must have the same start/end time as textgrid
+		TextGrid_checkStartAndEndTimesOfTiers (thee);
 		// last intervals must have the same end time
 		double xmax = preserveTimes ? thy xmax : my xmax + (thy xmax - thy xmin);
 		for (long itier = 1; itier <= my tiers -> size; itier++) {
 			Function myTier = (Function) my tiers -> item[itier], thyTier = (Function) thy tiers -> item[itier];
+			
 			if (myTier -> classInfo == classIntervalTier && thyTier -> classInfo == classIntervalTier) {
                 IntervalTier ti = (IntervalTier) myTier;
 				IntervalTiers_append_inline (ti, (IntervalTier) thy tiers -> item[itier], preserveTimes);
diff --git a/dwtools/manual_Permutation.cpp b/dwtools/manual_Permutation.cpp
index 4682fc8..119b436 100644
--- a/dwtools/manual_Permutation.cpp
+++ b/dwtools/manual_Permutation.cpp
@@ -1,6 +1,6 @@
 /* manual_Permutation.cpp
  *
- * Copyright (C) 2005-2013 David Weenink
+ * Copyright (C) 2005-2014 David Weenink
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -218,18 +218,29 @@ NORMAL (L"3. With ##Index range# = [0,0], ##Block size# = 3, and ##Offset# = 2,
 NORMAL (L"4. With ##Index range# = [0,0], ##Block size# = 4, and ##Offset# = 1, the permutation ((1,2,3,4),(5,6,7,8)) is turned into (1,6,3,8,2,7,4,5).")
 MAN_END
 
-MAN_BEGIN (L"Permutation: Next", L"djmw", 20100521)
-NORMAL (L"Get the next @@Permutation|permutation@ in lexicographic order. Starting with the identity permutation and "
+MAN_BEGIN (L"lexicographic permutation order", L"djmw", 20140131)
+INTRO (L"We can order the %n numbers 1, 2, 3,..., n in %n! different ways. Each of these n! orderings represents a different permutation of "
+	"the numbers 1, 2, 3,..., n. For example, if %n equals 3 we have 6 (=3\\.c2\\.c1) possible orderings: (1,2,3), (1,3,2), (2,1,3), (2,3,1), (3,1,2) and (3,2,1). "
+	"The %%lexicographic permutation order% starts from the identity permutation (1,2,..., n). By successively swapping only two numbers one "
+	"obtains all possible permutations. The last permutation in lexicographic order will be the permutation with all numbers in reversed order, "
+	"i.e. (n,n-1,...,2,1). The example given above has all 6 permutations in lexicographic permutation order.")
+MAN_END
+
+MAN_BEGIN (L"Permutation: Next", L"djmw", 20140131)
+INTRO (L"Get the next @@Permutation|permutation@ in @@lexicographic permutation order at . ")
+NORMAL (L"The next permutation is obtained from the selected permutation "
+	"by swapping values %%at only two positions%. Starting with the identity permutation and "
 	"repeatedly applying this function will iterate through all possible permutations. If no further permutation "
-	"is available the current permutation will not change. ")
+	"is available, i.e. the selected permutation is at the lexicographic end position (n, n-1, ..., 3, 2, 1), the current permutation will not change anymore. ")
 ENTRY (L"Examples")
-NORMAL (L"If we start with (1,2,3,4) successively applying Next will generate the following sequence (1,2,4,3), (1,3,2,4), (1,3,4,2), (1,4,2,3), (1,4,3,2), etc.")
+NORMAL (L"If we start with (1,2,3,4) successively applying ##Next# will generate the following sequence (1,2,4,3), (1,3,2,4), (1,3,4,2), (1,4,2,3), (1,4,3,2), etc.")
 MAN_END
 
-MAN_BEGIN (L"Permutation: Previous", L"djmw", 20100521)
-NORMAL (L"Get the previous @@Permutation|permutation@ in lexicographic order. If no further permutation "
-	"is available the current permutation will not change. ")
-NORMAL (L"This Previous operation follows the opposite order of @@Permutation: Next at .")
+MAN_BEGIN (L"Permutation: Previous", L"djmw", 20140131)
+NORMAL (L"Get the previous @@Permutation|permutation@ in @@lexicographic permutation order at . The previous permutation is obtained "
+	"from the selected permutation by swapping values %%at only two positions%. If no further permutation "
+	"is available, i.e. the current permutation is at the lexicographic start position (1, 2, 3, ..., n-1, n), the current permutation will not change anymore. ")
+NORMAL (L"The ##Previous# operation follows the opposite order of @@Permutation: Next at .")
 MAN_END
 
 MAN_BEGIN (L"Permutation: Rotate...", L"djmw", 20110105)
@@ -267,7 +278,7 @@ ENTRY (L"Example")
 NORMAL (L"If the selected TableOfReal has 5 rows and the permutation is (5,4,3,2,1) the first row of the new TableOfReal equals the fifth row of the selected, the second row of new equals the fourth row of the selected and so on.")
 MAN_END
 
-MAN_BEGIN (L"Strings & Permutation: Permute strings", L"djmw", 20050721)
+MAN_BEGIN (L"Strings & Permutation: Permute strings", L"djmw", 20140130)
 INTRO (L"Generate a new @Strings with a strings ordering determined by the @Permutation.")
 NORMAL (L"The number of strings in the #Strings and the number of elements in the #Permutation have to be equal.")
 ENTRY (L"Examples")
@@ -278,7 +289,7 @@ NORMAL (L"2. In the example that is discussed in the @@ExperimentMFC|listening e
 	"randomization strategy, i.e. stimuli presented in blocks of four, randomized, and no two successive stimuli equal. "
 	"This type of randomization can easily be accomplished with a Permutation object and a Strings." )
 LIST_ITEM (L"1. Fill the Strings object with 12 strings, i.e. three repetitions of the four stimuli. ")
-LIST_ITEM (L"2. Create a Permutation object with 12 elements and perform  ##@@Permutation: Permute randomly (blocks)...|Permute randomly (blocks)...@ 0 0 4 yes yes#. We randomly permute blocks of size 4 and permute randomly within these blocks and make sure that on the transition from on block to the other no two stimuli are equal. (Of course, the random permutation of the blocks makes no difference here since all the blocks have the same content.)")
+LIST_ITEM (L"2. Create a Permutation object with 12 elements and perform  ##@@Permutation: Permute randomly (blocks)...|Permute randomly (blocks):@ 0, 0, 4, \"yes\", \"yes\"#. We randomly permute blocks of size 4 and permute randomly within these blocks and make sure that on the transition from on block to the other no two stimuli are equal. (Of course, the random permutation of the blocks makes no difference here since all the blocks have the same content.)")
 LIST_ITEM (L"3. Select the Strings and the Permutation together and choose ##Permute strings#. "
 	"Now the new Strings will contain the new ordering of the stimuli.")
 MAN_END
diff --git a/dwtools/praat_DataModeler_init.cpp b/dwtools/praat_DataModeler_init.cpp
index 13765de..93c85db 100644
--- a/dwtools/praat_DataModeler_init.cpp
+++ b/dwtools/praat_DataModeler_init.cpp
@@ -17,8 +17,8 @@
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 
-#include "praatP.h"
 #include <math.h>
+#include "praatP.h"
 #include "DataModeler.h"
 #include "Formant_extensions.h"
 #include "Pitch.h"
@@ -395,36 +395,6 @@ DO
 	}
 END
 
-FORM (Formants_getSmoothestInInterval, L"Formant: Get smoothest in interval", 0)
-	REAL (L"left Time range (s)", L"0.0")
-	REAL (L"right Time range (s)", L"0.0")
-	NATURAL (L"Number of formant tracks", L"4")
-	INTEGER (L"Order of polynomials", L"3")
-	LABEL (L"", L"Use bandwidths to model the formant tracks")
-	OPTIONMENU (L"Weigh data", 2)
-		OPTION (L"Equally")
-		OPTION (L"Bandwidth")
-		OPTION (L"Bandwidth / frequency")
-		OPTION (L"Sqrt bandwidth")
-	LABEL (L"", L"Zero parameter values whose range include zero.")
-	REAL (L"Number of sigmas", L"1.0")
-	POSITIVE (L"Parameter variance power", L"2.5")
-	OK
-DO
-	autoCollection set = praat_getSelectedObjects ();
-	double tmin = GET_REAL (L"left Time range"), tmax = GET_REAL (L"right Time range");
-	long index = Formants_getSmoothestInInterval (set.peek(), tmin, tmax, GET_INTEGER (L"Number of formant tracks"),
-		GET_INTEGER (L"Order of polynomials") + 1, 
-		GET_INTEGER (L"Weigh data") - 1, GET_REAL (L"Number of sigmas"), GET_REAL (L"Parameter variance power"), 0, 1, 1, 1, 1, 1);
-	long iselected = 0;
-	LOOP {
-		iselected ++;
-		if (iselected != index) {
-			praat_deselect (IOBJECT);
-		}
-	}
-END
-
 FORM (Formants_extractSmoothestPart, L"Formants: Extract smoothest part", L"Formants: Extract smoothest part")
 	REAL (L"left Time range (s)", L"0.0")
 	REAL (L"right Time range (s)", L"0.0")
@@ -438,7 +408,7 @@ FORM (Formants_extractSmoothestPart, L"Formants: Extract smoothest part", L"Form
 		OPTION (L"Sqrt bandwidth")
 	LABEL (L"", L"Zero parameter values whose range include zero.")
 	REAL (L"Number of sigmas", L"1.0")
-	POSITIVE (L"Parameter variance power", L"2.5")
+	POSITIVE (L"Parameter variance power", L"1.5")
 	OK
 DO
 	autoCollection set = praat_getSelectedObjects ();
@@ -476,7 +446,7 @@ FORM (Formants_extractSmoothestPart_constrained, L"Formants: Extract smoothest p
 		OPTION (L"Sqrt bandwidth")
 	LABEL (L"", L"Zero parameter values whose range include zero.")
 	REAL (L"Number of sigmas", L"1.0")
-	POSITIVE (L"Parameter variance power", L"2.5")
+	POSITIVE (L"Parameter variance power", L"1.5")
 	LABEL (L"", L"The constraints on the formants")
 	REAL (L"Minimum F1 (Hz)", L"100.0")
 	REAL (L"Maximum F1 (Hz)", L"1200.0")
@@ -904,7 +874,7 @@ FORM (FormantModeler_getSmoothnessValue, L"FormantModeler: Get smoothness value"
 	INTEGER (L"left Formant range", L"0")
 	INTEGER (L"right Formant range", L"0")
 	INTEGER (L"Order of polynomials", L"3")
-	POSITIVE (L"Parameter variance power", L"2.5")
+	POSITIVE (L"Parameter variance power", L"1.5")
 	OK
 DO
 	LOOP {
@@ -1161,7 +1131,7 @@ FORM (Sound_to_Formant_interval, L"Sound: To Formant (interval)", 0)
 		OPTION (L"Sqrt bandwidth")
 	LABEL (L"", L"Make parameters that include zero in their confidence region zero")
 	REAL (L"Number of sigmas", L"1.0")
-	POSITIVE (L"Parameter variance power", L"2.5")
+	POSITIVE (L"Parameter variance power", L"1.5")
 	OK
 DO
 	LOOP {
@@ -1196,7 +1166,7 @@ FORM (Sound_to_Formant_interval_constrained, L"Sound: To Formant (interval, cons
 		OPTION (L"Sqrt bandwidth")
 	LABEL (L"", L"Make parameters that include zero in their confidence region zero")
 	REAL (L"Number of sigmas", L"1.0")
-	POSITIVE (L"Parameter variance power", L"2.5")
+	POSITIVE (L"Parameter variance power", L"1.5")
 	LABEL (L"", L"Formant frequency constraints")
 	REAL (L"Minimum F1 (Hz)", L"100.0")
 	REAL (L"Maximum F1 (Hz)", L"1200.0")
@@ -1238,7 +1208,7 @@ FORM (Sound_to_Formant_interval_constrained_robust, L"Sound: To Formant (interva
 		OPTION (L"Sqrt bandwidth")
 	LABEL (L"", L"Make parameters that include zero in their confidence region zero")
 	REAL (L"Number of sigmas", L"1.0")
-	POSITIVE (L"Parameter variance power", L"2.5")
+	POSITIVE (L"Parameter variance power", L"1.5")
 	LABEL (L"", L"Formant frequency constraints")
 	REAL (L"Minimum F1 (Hz)", L"100.0")
 	REAL (L"Maximum F1 (Hz)", L"1200.0")
@@ -1331,7 +1301,6 @@ void praat_DataModeler_init (void) {
 	praat_addAction1 (classDataModeler, 0, L"To Table (z-scores)...", 0, 0, DO_DataModeler_to_Table_zscores);
 
 	praat_addAction1 (classFormant, 0, L"To FormantModeler...", L"To LPC...", 0, DO_Formant_to_FormantModeler);
-	praat_addAction1 (classFormant, 0, L"Select smoothest...", L"To LPC...", 0, DO_Formants_getSmoothestInInterval);
 	praat_addAction1 (classFormant, 0, L"Extract smoothest part...", 0, 0, DO_Formants_extractSmoothestPart);
 	praat_addAction1 (classFormant, 0, L"Extract smoothest part (constrained)...", 0, 0, DO_Formants_extractSmoothestPart_constrained);
 
@@ -1392,10 +1361,12 @@ void praat_DataModeler_init (void) {
 
 	praat_addAction1 (classPitchModeler, 0, L"Draw...", 0, 0, DO_PitchModeler_draw);
 
-	praat_addAction1 (classSound, 0, L"To Formant (interval)...", L"To Formant (burg)...", 1, DO_Sound_to_Formant_interval);
-	praat_addAction1 (classSound, 0, L"To Formant (interval, constrained)...", L"To Formant (interval)...", 1, DO_Sound_to_Formant_interval_constrained);
-	praat_addAction1 (classSound, 0, L"To Formant (interval, constrained, robust)...", L"To Formant (interval, constrained)...", 1, DO_Sound_to_Formant_interval_constrained_robust);
-	praat_addAction1 (classTable, 0, L"To DataModeler...", L"To logistic regression...", 1, DO_Table_to_DataModeler);
+	praat_addAction1 (classSound, 0, L"To Formant (interval)...", L"To Formant (robust)...", praat_DEPTH_2 | praat_HIDDEN, DO_Sound_to_Formant_interval);
+	praat_addAction1 (classSound, 0, L"To Formant (interval, constrained)...", L"To Formant (interval)...",
+		praat_DEPTH_2 | praat_HIDDEN, DO_Sound_to_Formant_interval_constrained);
+	praat_addAction1 (classSound, 0, L"To Formant (interval, constrained, robust)...", L"To Formant (interval, constrained)...", 
+		praat_DEPTH_2 | praat_HIDDEN, DO_Sound_to_Formant_interval_constrained_robust);
+	praat_addAction1 (classTable, 0, L"To DataModeler...", L"To logistic regression...", praat_DEPTH_1 + praat_HIDDEN, DO_Table_to_DataModeler);
 }
 
 /* End of file praat_DataModeler_init.c */
diff --git a/fon/RunnerMFC.cpp b/fon/RunnerMFC.cpp
index e533cca..8f2f1f4 100644
--- a/fon/RunnerMFC.cpp
+++ b/fon/RunnerMFC.cpp
@@ -121,7 +121,7 @@ static void gui_drawingarea_cb_expose (I, GuiDrawingAreaExposeEvent event) {
 				if (visibleText_q) visibleText_p = visibleText_q + 1; else visibleText_p += wcslen (visibleText_p);
 			}
 			if (wcsnequ (textToDraw, L"\\FI", 3)) {
-				structMelderFile file;
+				structMelderFile file = { 0 };
 				MelderDir_relativePathToFile (& experiment -> rootDirectory, textToDraw + 3, & file);
 				Graphics_imageFromFile (my graphics, Melder_fileToPath (& file), response -> left, response -> right, response -> bottom, response -> top);
 			} else {
diff --git a/fon/TextGrid.cpp b/fon/TextGrid.cpp
index 36ac7f2..d1e98c4 100644
--- a/fon/TextGrid.cpp
+++ b/fon/TextGrid.cpp
@@ -1728,10 +1728,11 @@ void TextGrid_correctRoundingErrors (TextGrid me) {
 				TextInterval left = (TextInterval) tier -> intervals -> item [iinterval];
 				TextInterval right = (TextInterval) tier -> intervals -> item [iinterval + 1];
 				right -> xmin = left -> xmax;
-				trace ("tier %ld, interval %ld, %17g %17g", itier, iinterval, right -> xmin, right -> xmax);
+				trace ("tier %ld, interval %ld, %.17g %.17g", itier, iinterval, right -> xmin, right -> xmax);
 				Melder_assert (right -> xmin < right -> xmax);
 			}
 			TextInterval last = (TextInterval) tier -> intervals -> item [tier -> intervals -> size];
+			trace ("%ld %.17g %.17g", tier -> intervals -> size, last -> xmax, my xmax);
 			last -> xmax = my xmax;
 			Melder_assert (last -> xmax > last -> xmin);
 		}
diff --git a/fon/manual_tutorials.cpp b/fon/manual_tutorials.cpp
index 4afcce9..603aa3b 100644
--- a/fon/manual_tutorials.cpp
+++ b/fon/manual_tutorials.cpp
@@ -23,12 +23,14 @@
 void manual_tutorials_init (ManPages me);
 void manual_tutorials_init (ManPages me) {
 
-MAN_BEGIN (L"What's new?", L"ppgb", 20140826)
+MAN_BEGIN (L"What's new?", L"ppgb", 20140919)
 INTRO (L"Latest changes in Praat.")
 /*LIST_ITEM (L"\\bu Manual page about @@drawing a vowel triangle at .")*/
+NORMAL (L"##5.3.85# (19 September 2014)")
+LIST_ITEM (L"\\bu Mac audio: circumvented a bug in PortAudio by which playback of sounds with sampling frequencies "
+	"below 44100 Hz could be distorted on some USB headsets.")
 NORMAL (L"##5.3.84# (26 August 2014)")
 LIST_ITEM (L"\\bu Manipulation: repaired a bug that could cause Praat to crash when playing a manipulation of a Sound created by the SpeechSynthesizer.")
-LIST_ITEM (L"\\bu Mac: repaired a bug that could cause poor sound quality on some USB headphones when playing a sound with a low sampling frequency.")
 NORMAL (L"##5.3.83# (16 August 2014)")
 LIST_ITEM (L"\\bu TextGrid window: repaired a bug with automatic alignment that could cause an analysis tier to go out of order.")
 LIST_ITEM (L"\\bu Linux audio: created a second workaround that reduces even more the chances of a freeze that is due to a potential deadlock "
diff --git a/fon/praat_TextGrid_init.cpp b/fon/praat_TextGrid_init.cpp
index d910247..609b413 100644
--- a/fon/praat_TextGrid_init.cpp
+++ b/fon/praat_TextGrid_init.cpp
@@ -1820,7 +1820,7 @@ praat_addAction1 (classTextGrid, 0, L"Synthesize", 0, 0, 0);
 	praat_addAction2 (classPitch, 1, classTextGrid, 1, L"Speckle separately (erb)...", 0, 1, DO_TextGrid_Pitch_speckleSeparatelyErb);
 	praat_addAction2 (classPitch, 1, classTextTier, 1, L"To PitchTier...", 0, 0, DO_Pitch_TextTier_to_PitchTier);
 	praat_addAction2 (classSound, 1, classTextGrid, 1, L"View & Edit", 0, praat_ATTRACTIVE, DO_TextGrid_edit);
-	praat_addAction2 (classSound, 1, classTextGrid, 1, L"View & Edit with callback", 0, praat_HIDDEN, DO_TextGrid_editWithCallback);
+	praat_addAction2 (classSound, 1, classTextGrid, 1, L"View & Edit with callback...", 0, praat_HIDDEN, DO_TextGrid_editWithCallback);
 	praat_addAction2 (classSound, 1, classTextGrid, 1, L"Edit", 0, praat_HIDDEN, DO_TextGrid_edit);
 	praat_addAction2 (classSound, 1, classTextGrid, 1, L"Draw...", 0, 0, DO_TextGrid_Sound_draw);
 	praat_addAction2 (classSound, 1, classTextGrid, 1, L"Extract -", 0, 0, 0);
diff --git a/num/NUMrandom.cpp b/num/NUMrandom.cpp
index 7f57dba..12932ba 100644
--- a/num/NUMrandom.cpp
+++ b/num/NUMrandom.cpp
@@ -135,25 +135,25 @@ class NUMrandom_State { public:
 /* initialize the array with a number of seeds */
 void NUMrandom_State :: init_by_array64 (uint64_t init_key [], unsigned int key_length)
 {
-    init_genrand64 (UINT64_C (19650218));   // warm it up
-
-    unsigned int i = 1, j = 0;
-    unsigned int k = ( NN > key_length ? NN : key_length );
-    for (; k; k --) {
-        array [i] = (array [i] ^ ((array [i - 1] ^ (array [i - 1] >> 62)) * UINT64_C (3935559000370003845)))
-          + init_key [j] + (uint64_t) j;   /* non linear */
-        i ++, j ++;
-        if (i >= NN) { array [0] = array [NN - 1]; i = 1; }
-        if (j >= key_length) j = 0;
-    }
-    for (k = NN - 1; k; k --) {
-        array [i] = (array [i] ^ ((array [i - 1] ^ (array [i - 1] >> 62)) * UINT64_C (2862933555777941757)))
-          - (uint64_t) i;   /* non linear */
-        i ++;
-        if (i >= NN) { array [0] = array [NN - 1]; i = 1; }
-    }
-
-    array [0] = UINT64_C (1) << 63; /* MSB is 1; assuring non-zero initial array */
+	init_genrand64 (UINT64_C (19650218));   // warm it up
+
+	unsigned int i = 1, j = 0;
+	unsigned int k = ( NN > key_length ? NN : key_length );
+	for (; k; k --) {
+		array [i] = (array [i] ^ ((array [i - 1] ^ (array [i - 1] >> 62)) * UINT64_C (3935559000370003845)))
+		  + init_key [j] + (uint64_t) j;   /* non linear */
+		i ++, j ++;
+		if (i >= NN) { array [0] = array [NN - 1]; i = 1; }
+		if (j >= key_length) j = 0;
+	}
+	for (k = NN - 1; k; k --) {
+		array [i] = (array [i] ^ ((array [i - 1] ^ (array [i - 1] >> 62)) * UINT64_C (2862933555777941757)))
+		  - (uint64_t) i;   /* non linear */
+		i ++;
+		if (i >= NN) { array [0] = array [NN - 1]; i = 1; }
+	}
+
+	array [0] = UINT64_C (1) << 63; /* MSB is 1; assuring non-zero initial array */
 }
 
 static bool theInited = false;
@@ -207,66 +207,66 @@ void NUMrandom_init () {
 
 double NUMrandomFraction () {
 	NUMrandom_State *me = & states [0];
-    uint64_t x;
+	uint64_t x;
 
-    if (my index >= NN) { /* generate NN words at a time */
+	if (my index >= NN) { /* generate NN words at a time */
 
 		Melder_assert (theInited);   // if NUMrandom_init() hasn't been called, we'll detect that here, probably in the first call
 
 		int i;
-        for (i = 0; i < NN - MM; i ++) {
-            x = (my array [i] & UM) | (my array [i + 1] & LM);
-            my array [i] = my array [i + MM] ^ (x >> 1) ^ ZERO_OR_MAGIC;
-        }
-        for (; i < NN - 1; i ++) {
-            x = (my array [i] & UM) | (my array [i + 1] & LM);
-            my array [i] = my array [i + (MM - NN)] ^ (x >> 1) ^ ZERO_OR_MAGIC;
-        }
-        x = (my array [NN - 1] & UM) | (my array [0] & LM);
-        my array [NN - 1] = my array [MM - 1] ^ (x >> 1) ^ ZERO_OR_MAGIC;
-
-        my index = 0;
-    }
-
-    x = my array [my index ++];
-
-    x ^= (x >> 29) & UINT64_C (0x5555555555555555);
-    x ^= (x << 17) & UINT64_C (0x71D67FFFEDA60000);
-    x ^= (x << 37) & UINT64_C (0xFFF7EEE000000000);
-    x ^= (x >> 43);
+		for (i = 0; i < NN - MM; i ++) {
+			x = (my array [i] & UM) | (my array [i + 1] & LM);
+			my array [i] = my array [i + MM] ^ (x >> 1) ^ ZERO_OR_MAGIC;
+		}
+		for (; i < NN - 1; i ++) {
+			x = (my array [i] & UM) | (my array [i + 1] & LM);
+			my array [i] = my array [i + (MM - NN)] ^ (x >> 1) ^ ZERO_OR_MAGIC;
+		}
+		x = (my array [NN - 1] & UM) | (my array [0] & LM);
+		my array [NN - 1] = my array [MM - 1] ^ (x >> 1) ^ ZERO_OR_MAGIC;
+
+		my index = 0;
+	}
+
+	x = my array [my index ++];
+
+	x ^= (x >> 29) & UINT64_C (0x5555555555555555);
+	x ^= (x << 17) & UINT64_C (0x71D67FFFEDA60000);
+	x ^= (x << 37) & UINT64_C (0xFFF7EEE000000000);
+	x ^= (x >> 43);
 
 	return (x >> 11) * (1.0/9007199254740992.0);
 }
 
 double NUMrandomFraction_mt (int threadNumber) {
 	NUMrandom_State *me = & states [threadNumber];
-    uint64_t x;
+	uint64_t x;
 
-    if (my index >= NN) { /* generate NN words at a time */
+	if (my index >= NN) { /* generate NN words at a time */
 
 		Melder_assert (theInited);
 
 		int i;
-        for (i = 0; i < NN - MM; i ++) {
-            x = (my array [i] & UM) | (my array [i + 1] & LM);
-            my array [i] = my array [i + MM] ^ (x >> 1) ^ ZERO_OR_MAGIC;
-        }
-        for (; i < NN - 1; i ++) {
-            x = (my array [i] & UM) | (my array [i + 1] & LM);
-            my array [i] = my array [i + (MM - NN)] ^ (x >> 1) ^ ZERO_OR_MAGIC;
-        }
-        x = (my array [NN - 1] & UM) | (my array [0] & LM);
-        my array [NN - 1] = my array [MM - 1] ^ (x >> 1) ^ ZERO_OR_MAGIC;
-
-        my index = 0;
-    }
-
-    x = my array [my index ++];
-
-    x ^= (x >> 29) & UINT64_C (0x5555555555555555);
-    x ^= (x << 17) & UINT64_C (0x71D67FFFEDA60000);
-    x ^= (x << 37) & UINT64_C (0xFFF7EEE000000000);
-    x ^= (x >> 43);
+		for (i = 0; i < NN - MM; i ++) {
+			x = (my array [i] & UM) | (my array [i + 1] & LM);
+			my array [i] = my array [i + MM] ^ (x >> 1) ^ ZERO_OR_MAGIC;
+		}
+		for (; i < NN - 1; i ++) {
+			x = (my array [i] & UM) | (my array [i + 1] & LM);
+			my array [i] = my array [i + (MM - NN)] ^ (x >> 1) ^ ZERO_OR_MAGIC;
+		}
+		x = (my array [NN - 1] & UM) | (my array [0] & LM);
+		my array [NN - 1] = my array [MM - 1] ^ (x >> 1) ^ ZERO_OR_MAGIC;
+
+		my index = 0;
+	}
+
+	x = my array [my index ++];
+
+	x ^= (x >> 29) & UINT64_C (0x5555555555555555);
+	x ^= (x << 17) & UINT64_C (0x71D67FFFEDA60000);
+	x ^= (x << 37) & UINT64_C (0xFFF7EEE000000000);
+	x ^= (x >> 43);
 
 	return (x >> 11) * (1.0/9007199254740992.0);
 }
diff --git a/sys/Editor.cpp b/sys/Editor.cpp
index 000e5ee..85e50a8 100644
--- a/sys/Editor.cpp
+++ b/sys/Editor.cpp
@@ -277,9 +277,9 @@ static void menu_cb_sendBackToCallingProgram (EDITOR_ARGS) {
 	EDITOR_IAM (Editor);
 	if (my data) {
 		extern structMelderDir praatDir;
-		structMelderFile file;
+		structMelderFile file = { 0 };
 		MelderDir_getFile (& praatDir, L"praat_backToCaller.Data", & file);
-		Data_writeToBinaryFile (my data, & file);
+		Data_writeToTextFile (my data, & file);
 		sendsocket (my callbackSocket, Melder_peekWcsToUtf8 (my data -> name));
 	}
 	my v_goAway ();
diff --git a/sys/Graphics_image.cpp b/sys/Graphics_image.cpp
index 046fecf..2e4cc47 100644
--- a/sys/Graphics_image.cpp
+++ b/sys/Graphics_image.cpp
@@ -709,7 +709,7 @@ static void _GraphicsScreen_imageFromFile (GraphicsScreen me, const wchar_t *rel
 	long x1DC = wdx (x1), x2DC = wdx (x2), y1DC = wdy (y1), y2DC = wdy (y2);
 	long width = x2DC - x1DC, height = my yIsZeroAtTheTop ? y1DC - y2DC : y2DC - y1DC;
 	#if 0
-		structMelderFile file;
+		structMelderFile file = { 0 };
 		Melder_relativePathToFile (relativeFileName, & file);
 		try {
 			autoPhoto photo = Photo_readFromImageFile (& file);
@@ -743,7 +743,7 @@ static void _GraphicsScreen_imageFromFile (GraphicsScreen me, const wchar_t *rel
 		}
 	#elif win
 		if (my d_useGdiplus) {
-			structMelderFile file;
+			structMelderFile file = { 0 };
 			Melder_relativePathToFile (relativeFileName, & file);
 			Gdiplus::Bitmap image (file. path);
 			if (x1 == x2 && y1 == y2) {
@@ -761,7 +761,7 @@ static void _GraphicsScreen_imageFromFile (GraphicsScreen me, const wchar_t *rel
 			dcplus. DrawImage (& image, rect);
 		}
 	#elif mac
-		structMelderFile file;
+		structMelderFile file = { 0 };
 		Melder_relativePathToFile (relativeFileName, & file);
 		char utf8 [500];
 		Melder_wcsTo8bitFileRepresentation_inline (file. path, utf8);
diff --git a/sys/GuiFileSelect.cpp b/sys/GuiFileSelect.cpp
index 6b4fda4..66c3ead 100644
--- a/sys/GuiFileSelect.cpp
+++ b/sys/GuiFileSelect.cpp
@@ -88,7 +88,7 @@ SortedSetOfString GuiFileSelect_getInfileNames (GuiWindow parent, const wchar_t
 					DescType typeCode;
 					Size actualSize = 0;
 					FSRef machFile;
-					structMelderFile file;
+					structMelderFile file = { 0 };
 					if ((err = AEGetNthPtr (& reply. selection, ifile, typeFSRef, & keyWord, & typeCode, & machFile, sizeof (FSRef), & actualSize)) == noErr)
 						Melder_machToFile (& machFile, & file);
 					my addString (Melder_fileToPath (& file));
@@ -142,7 +142,7 @@ SortedSetOfString GuiFileSelect_getInfileNames (GuiWindow parent, const wchar_t
 				structMelderDir dir;
 				Melder_pathToDir (fullFileName, & dir);
 				for (const wchar_t *p = & fullFileName [firstFileNameLength + 1]; *p != '\0'; p += wcslen (p) + 1) {
-					structMelderFile file;
+					structMelderFile file = { 0 };
 					MelderDir_getFile (& dir, p, & file);
 					my addString (Melder_fileToPath (& file));
 				}
@@ -221,7 +221,7 @@ wchar_t * GuiFileSelect_getOutfileName (GuiWindow parent, const wchar_t *title,
 					FSRefMakePath (& machFile, (unsigned char *) directoryPath_utf8, 999);
 					if (! (directoryPath_utf8 [0] == '/' && directoryPath_utf8 [1] == '\0'))
 						strcat (directoryPath_utf8, "/");
-					structMelderFile file;
+					structMelderFile file = { 0 };
 					Melder_8bitToWcs_inline (directoryPath_utf8, file. path, kMelder_textInputEncoding_UTF8); // BUG throwable
 					int dirLength = wcslen (file. path);
 					int n = CFStringGetLength (outfileName_cf);
@@ -321,7 +321,7 @@ wchar_t * GuiFileSelect_getDirectoryName (GuiWindow parent, const wchar_t *title
 				DescType typeCode;
 				Size actualSize = 0;
 				FSRef machFile;
-				structMelderFile file;
+				structMelderFile file = { 0 };
 				if ((err = AEGetNthPtr (& reply. selection, 1, typeFSRef, & keyWord, & typeCode, & machFile, sizeof (FSRef), & actualSize)) == noErr) {
 					Melder_machToFile (& machFile, & file);
 					directoryName = Melder_wcsdup_f (Melder_fileToPath (& file));
diff --git a/sys/melder_audio.cpp b/sys/melder_audio.cpp
index ec376f9..d4f770a 100644
--- a/sys/melder_audio.cpp
+++ b/sys/melder_audio.cpp
@@ -125,7 +125,7 @@ double MelderAudio_getOutputSilenceAfter (void) { return preferences. silenceAft
 
 long MelderAudio_getOutputBestSampleRate (long fsamp) {
 	#if defined (macintosh)
-		return fsamp == 44100 || fsamp == 96000 ? fsamp : fsamp;
+		return fsamp == 44100 || fsamp == 96000 ? fsamp : 44100;
 	#elif defined (_WIN32)
 		return fsamp == 8000 || fsamp == 11025 || fsamp == 16000 || fsamp == 22050 ||
 			fsamp == 32000 || fsamp == 44100 || fsamp == 48000 || fsamp == 96000 ? fsamp : 44100;
diff --git a/sys/praat_version.h b/sys/praat_version.h
index 0ba955e..e159d94 100644
--- a/sys/praat_version.h
+++ b/sys/praat_version.h
@@ -1,5 +1,5 @@
-#define PRAAT_VERSION_STR 5.3.84
-#define PRAAT_VERSION_NUM 5384
+#define PRAAT_VERSION_STR 5.3.85
+#define PRAAT_VERSION_NUM 5385
 #define PRAAT_YEAR 2014
-#define PRAAT_MONTH August
-#define PRAAT_DAY 26
+#define PRAAT_MONTH September
+#define PRAAT_DAY 19

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/praat.git



More information about the debian-med-commit mailing list