diff --git a/README.md b/README.md
index a8c6b913..64de2005 100644
--- a/README.md
+++ b/README.md
@@ -19,7 +19,7 @@ Listening tests are widely used to assess the quality of audio systems. In the l
We provide two version of webMUSHRA.
-* __webMUSHRA__ provides the version targeted for normale usage and experimenters. The javascript files are compressed which makes it faster to load/serve. The documentation is provided as PDFs.
+* __webMUSHRA__ provides the version targeted for normal usage and experimenters. The javascript files are compressed which makes it faster to load/serve. The documentation is provided as PDFs.
* __webMUSHRA-dev__ is targeted to developers and experienced users who want to customize experiments. This version is comparable to cloning the git repository
@@ -31,6 +31,7 @@ We provide two version of webMUSHRA.
* MUSHRA (ITU-R BS.1534)
* AB (ITU-R BS.1116)
* Likert scale questionaires
+ * Ranking by elimination
* training/introduction
* spatial attributes, such as ASW, LEV, and localization (experimental)
* compliant to ITU recommendations (looping, fade-in/out, sample accurate switching)
diff --git a/configs/ranking_noloop.yaml b/configs/ranking_noloop.yaml
new file mode 100644
index 00000000..df3d8eb2
--- /dev/null
+++ b/configs/ranking_noloop.yaml
@@ -0,0 +1,60 @@
+# test config ranking page, waveform, 11 conditions, no looping
+
+
+testname: Rank order Elimination-by-Aspects
+testId: ranking_noloop
+bufferSize: 2048
+stopOnErrors: true
+showButtonPreviousPage: true
+remoteService: service/write.php
+
+# Ranking test does not support showing the waveform of the samples currently
+
+pages:
+ - type: generic
+ id: first_page
+ name: Welcome
+ content:
Welcome to the rank order elimination-by-aspects test. The goal of this test is to rank the presented conditions on personal preference of quality. The test is conducted as described below: [1] Listen to all the conditions one after the other using the "Play" button. [2] Eliminate the worst condition using the "X" button below it. [3] Repeat steps [1] and [2] until you are left with one condition or if you don't have a preference over remaining conditions. [4] You can reset the rankings by pressing "Reset" at any time, and all rankings done till that point will be reset. [5] Proceed to the next test using "next" button.
NOTE.1: You can only eliminate an "active" condition, i.e. a condition whose button is currently higlighted. NOTE.2: You cannot play again an already eliminated condition. ("Reset" re-enables all conditions). NOTE.3: Once a condition is eliminated, its rank will appear on its button. Lower rank (1-5) indicate worse quality. So the worst condition will have rank 1, the second worst 2, ... NOTE.4: If you press the "previous" button, the rankings of the previous test are lost and you can repeat the previous test.
+
+ - type: ranking
+ id: trial1
+ name: Mono Trial
+ content: test description
+ enableLooping: false
+ randomize: true
+ showConditionNames: true
+ showResetButton: true
+ stimuli:
+ C1: configs/resources/audio/mono_c1.wav
+ C2: configs/resources/audio/mono_c2.wav
+ C3: configs/resources/audio/mono_c3.wav
+
+ - type: ranking
+ id: trial2
+ name: Mono Trial
+ content: test description
+ enableLooping: false
+ randomize: true
+ showConditionNames: true
+ showResetButton: true
+
+ stimuli:
+ C1: configs/resources/audio/mono_c1.wav
+ C2: configs/resources/audio/mono_c2.wav
+ C3: configs/resources/audio/mono_c3.wav
+
+ - type: finish
+ name: Thank you
+ content: Thank you for attending!
+ showResults: true
+ writeResults: true
+ questionnaire:
+ - type: text
+ label: Nickname
+ name: id
+ - type: number
+ label: Age
+ name: age
+ min: 0
+ max: 100
+ default: 30
diff --git a/design/images/techfak.svg b/design/images/techfak.svg
index 89e46b15..da23fdc8 100644
--- a/design/images/techfak.svg
+++ b/design/images/techfak.svg
@@ -1,281 +1,165 @@
-
-
-
-
\ No newline at end of file
+
+
+
diff --git a/doc/experimenter.md b/doc/experimenter.md
index 5206b38b..3a136319 100644
--- a/doc/experimenter.md
+++ b/doc/experimenter.md
@@ -76,6 +76,22 @@ A mushra page shows a trial according to ITU-R Recommendation BS.1534.
* **stimuli** A map of stimuli representing three conditions. The key is the name of the condition. The value is the filepath to the stimulus (WAV file).
* **switchBack** If set to true, the time position is set back to the beginning (sample 0) when switching between test conditions and/or the reference. By default, this option is false.
+#### `ranking` page
+
+A ranking-by-elimination test trial page
+
+* **type** must be ranking.
+* **id** Identifier of the page.
+* **name** Name of the page (is shown as title)
+* **content** Content (HTML) of the page. The content is shown on the upper part of the page.
+* **showWaveform** If set to true, the waveform of the reference is shown.
+* **enableLooping** If set to true, the participant can set loops.
+* **randomize** If set to true, the conditions are randomized.
+* **showConditionNames** If set to true, the names of the conditions are shown.
+* **stimuli** A map of stimuli representing three conditions. The key is the name of the condition. The value is the filepath to the stimulus (WAV file).
+* **switchBack** If set to true, the time position is set back to the beginning (sample 0) when switching between test conditions and/or the reference. By default, this option is false.
+* **forceRankAll** If set to true, the "next" button will only be enabled if all items are ranked.
+
#### `bs1116` page
A bs1116 page shows a trial according to ITU-R Recommendation BS.1116.
diff --git a/index.html b/index.html
index dab46eb0..f8e97c1d 100644
--- a/index.html
+++ b/index.html
@@ -111,6 +111,7 @@
+
diff --git a/lib/webmushra/audio/MushraAudioControl.js b/lib/webmushra/audio/MushraAudioControl.js
index 6c988492..be9e5123 100644
--- a/lib/webmushra/audio/MushraAudioControl.js
+++ b/lib/webmushra/audio/MushraAudioControl.js
@@ -5,7 +5,7 @@ This source code is protected by copyright law and international treaties. This
**************************************************************************/
-function MushraAudioControl(_audioContext, _bufferSize, _reference, _conditions, _errorHandler, _createAnchor35, _createAnchor70, _randomize, _switchBack) {
+function MushraAudioControl(_audioContext, _bufferSize, _reference, _conditions, _errorHandler, _createAnchor35, _createAnchor70, _randomize, _switchBack, add_ref_to_conditions=true) {
this.audioContext = _audioContext;
this.bufferSize = parseInt(_bufferSize);
this.reference = _reference;
@@ -41,7 +41,9 @@ function MushraAudioControl(_audioContext, _bufferSize, _reference, _conditions,
//listeners
this.eventListeners = [];
- this.conditions[this.conditions.length] = this.reference;
+ if (add_ref_to_conditions) {
+ this.conditions[this.conditions.length] = this.reference;
+ }
// add anchors
if (this.createAnchor35) {
diff --git a/lib/webmushra/nls/nls.js b/lib/webmushra/nls/nls.js
index dd4436bf..68cea613 100644
--- a/lib/webmushra/nls/nls.js
+++ b/lib/webmushra/nls/nls.js
@@ -1,20 +1,25 @@
nls['en'] = new Object();
nls['de'] = new Object();
nls['fr'] = new Object();
+nls['es'] = new Object();
// Buttons
nls['en']['nextButton'] = "Next";
-nls['en']['previousButton'] = "Previous";
+nls['en']['previousButton'] = "Previous";
nls['en']['playButton'] = "Play";
-nls['en']['stopButton'] = "Stop";
+nls['en']['stopButton'] = "Stop";
nls['en']['pauseButton'] = "Pause";
+nls['en']['eliminateButton'] = "X";
+nls['en']['resetButton'] = "Reset";
nls['en']['sendButton'] = "Send Results";
nls['de']['nextButton'] = "Nächste Seite";
-nls['de']['previousButton'] = "Vorherige Seite";
+nls['de']['previousButton'] = "Vorherige Seite";
nls['de']['playButton'] = "Start";
-nls['de']['stopButton'] = "Stopp";
+nls['de']['stopButton'] = "Stopp";
nls['de']['pauseButton'] = "Pause";
+nls['de']['eliminateButton'] = "X";
+nls['de']['resetButton'] = "Reset";
nls['de']['sendButton'] = "Ergebnisse senden";
nls['fr']['nextButton'] = "Suivant";
@@ -22,26 +27,37 @@ nls['fr']['previousButton'] = "Précédent";
nls['fr']['playButton'] = "Play";
nls['fr']['stopButton'] = "Stop";
nls['fr']['pauseButton'] = "Pause";
+nls['fr']['eliminateButton'] = "X";
+nls['fr']['resetButton'] = "Reset";
nls['fr']['sendButton'] = "Envoyer les résultats";
+nls['es']['nextButton'] = "Siguiente";
+nls['es']['previousButton'] = "Anterior";
+nls['es']['playButton'] = "Reproducir";
+nls['es']['stopButton'] = "Detener";
+nls['es']['pauseButton'] = "Pausa";
+nls['es']['sendButton'] = "Enviar resultados";
+
// captions MUSHRA
nls['en']['excellent'] = "Excellent";
-nls['en']['good'] = "Good";
+nls['en']['good'] = "Good";
nls['en']['fair'] = "Fair";
-nls['en']['poor'] = "Poor";
+nls['en']['poor'] = "Poor";
nls['en']['bad'] = "Bad";
nls['en']['reference'] = "Reference";
+nls['en']['conditions'] = "Conditions:";
nls['en']['cond'] = "Cond.";
nls['en']['35'] = "Anchor35";
nls['en']['75'] = "Anchor75";
nls['de']['excellent'] = "Excellent";
-nls['de']['good'] = "Good";
+nls['de']['good'] = "Good";
nls['de']['fair'] = "Fair";
-nls['de']['poor'] = "Poor";
+nls['de']['poor'] = "Poor";
nls['de']['bad'] = "Bad";
nls['de']['reference'] = "Reference";
+nls['de']['conditions'] = "Conditions:";
nls['de']['cond'] = "Cond.";
nls['de']['35'] = "Anchor35";
nls['de']['75'] = "Anchor75";
@@ -52,22 +68,33 @@ nls['fr']['fair'] = "Correct";
nls['fr']['poor'] = "Faible";
nls['fr']['bad'] = "Mauvais";
nls['fr']['reference'] = "Référence";
+nls['fr']['conditions'] = "Conditions:";
nls['fr']['cond'] = "Cond.";
nls['fr']['35'] = "Ancre35";
nls['fr']['75'] = "Ancre75";
+nls['es']['excellent'] = "Excelente";
+nls['es']['good'] = "Bien";
+nls['es']['fair'] = "Regular";
+nls['es']['poor'] = "Pobre";
+nls['es']['bad'] = "Malo";
+nls['es']['reference'] = "Referencia";
+nls['es']['cond'] = "Estado";
+nls['es']['35'] = "Ancla35";
+nls['es']['75'] = "Ancla75";
+
// captions BS1116
nls['en']['imperceptible'] = "Imperceptible";
-nls['en']['perceptible'] = "Perceptible, but not annoying";
+nls['en']['perceptible'] = "Perceptible, but not annoying";
nls['en']['slightly'] = "Slightly annoying";
-nls['en']['annoying'] = "Annoying";
+nls['en']['annoying'] = "Annoying";
nls['en']['very'] = "Very annoying";
nls['de']['imperceptible'] = "Imperceptible";
-nls['de']['perceptible'] = "Perceptible, but not annoying";
+nls['de']['perceptible'] = "Perceptible, but not annoying";
nls['de']['slightly'] = "Slightly annoying";
-nls['de']['annoying'] = "Annoying";
+nls['de']['annoying'] = "Annoying";
nls['de']['very'] = "Very annoying";
nls['fr']['imperceptible'] = "Dégradation imperceptible";
@@ -76,17 +103,25 @@ nls['fr']['slightly'] = "Légèrement gênante";
nls['fr']['annoying'] = "Dégradation gênante";
nls['fr']['very'] = "Dégradation très gênante";
+nls['es']['imperceptible'] = "Imperceptible";
+nls['es']['perceptible'] = "Perceptible, pero no molesto";
+nls['es']['slightly'] = "Ligeramente molesto";
+nls['es']['annoying'] = "Molesto";
+nls['es']['very'] = "Muy molesto";
// captions Paired Comparison AB/ABN
nls['en']['quest'] = "Which item is the reference?";
nls['de']['quest'] = "Welches Stück ist die Referenz?";
nls['fr']['quest'] = "Quel item est la référence?";
+nls['es']['quest'] = "¿Cuál es la referencia?";
// captions finishPage
nls['en']['results'] = "Your results:";
nls['de']['results'] = "Die Ergebnisse:";
nls['fr']['results'] = "Vos résultats:";
+nls['es']['results'] = "Sus resultados:";
nls['en']['attending'] = "Thank you for your participation!";
nls['de']['attending'] = "Vielen Dank für die Teilnahme!";
nls['fr']['attending'] = "Merci pour votre participation!";
+nls['es']['attending'] = "Gracias por participar!";
diff --git a/lib/webmushra/pages/FinishPage.js b/lib/webmushra/pages/FinishPage.js
index fd1e3ce1..ed534d9f 100644
--- a/lib/webmushra/pages/FinishPage.js
+++ b/lib/webmushra/pages/FinishPage.js
@@ -138,6 +138,33 @@ FinishPage.prototype.render = function (_parent) {
$(trRatings).append(tdRatingScore);
$(table).append(trRatings);
+ }
+ trEmpty = $("
");
+ $(table).append(trEmpty);
+ }else if (trial.type === "ranking") {
+ trT = document.createElement("tr");
+ thT = $("
");
+ trLoop.append(tdRight);
+
+
+ var trMushra = $("
");
+ tableDown.append(trMushra);
+ var tdMushra = $("
");
+ trMushra.append(tdMushra);
+
+ var tableMushra = $("
");
+ tdMushra.append(tableMushra);
+
+ var trConditionNames = $("
");
+ tableMushra.append(trConditionNames);
+
+ /* Unable to remove the below string without affecting the buttons */
+ var tdConditionNamesReference = $("