From 5af1de60bbd4a677ea40b4e90f9c06494d4d84d8 Mon Sep 17 00:00:00 2001 From: mpelissi Date: Tue, 14 Mar 2023 11:20:00 +0100 Subject: [PATCH] update contexte - inscription ok sur firefox --- static/MAIN.js | 2 +- static/fonctions_clavier.js | 2 +- static/fonctions_contexte.js | 36 ++++++++++++++++++--------------- static/fonctions_inscription.js | 2 +- 4 files changed, 23 insertions(+), 19 deletions(-) diff --git a/static/MAIN.js b/static/MAIN.js index fc4eb22..64637df 100644 --- a/static/MAIN.js +++ b/static/MAIN.js @@ -85,7 +85,7 @@ function init_variable(premier_appel){ // Enchainement des pages if (premier_appel){ page_contexte = false - page_inscription = true // true + page_inscription = true page_explication = false page_warning = false page_explication_bis = false diff --git a/static/fonctions_clavier.js b/static/fonctions_clavier.js index b6fc02f..4fd565f 100644 --- a/static/fonctions_clavier.js +++ b/static/fonctions_clavier.js @@ -10,7 +10,7 @@ function action_clavier_contexte(event){ // break; // valider case 'Enter': - if (num_texte < ((textes_page_1.length + textes_page_2.length + textes_page_3.length +textes_page_4.length))-1){ + if (num_texte < ((textes_page_1.length + textes_page_2.length + textes_page_3.length +textes_page_4.length))-2){ action_bouton_suivant_contexte()} else{ action_bouton_commencer_contexte() diff --git a/static/fonctions_contexte.js b/static/fonctions_contexte.js index 29218d6..002a9d9 100644 --- a/static/fonctions_contexte.js +++ b/static/fonctions_contexte.js @@ -105,6 +105,7 @@ function afficher_bouton_avant_contexte(){ ///// MAIN function traitement_contexte(){ + console.log(num_texte) ctx.clearRect(0, 0, canvas.width, canvas.height) // variable position x_texte = window.innerWidth*(1/8) @@ -116,11 +117,12 @@ function traitement_contexte(){ for(let p=0; p The viewpoint of an object is the position from which we observe the object.", "y": window.innerHeight*0.2, "c": color_blanc}, -//"texte5":{"t":"Depending on this position, we can observe different parts of this object. However, from any position, it is often not possible to observe all the parts of this object.", "y": window.innerHeight*0.32, "c": color_blanc}, "texte5":{"t":"A viewpoint will always highlight some parts and obscure other parts of an object.", "y": window.innerHeight*0.3, "c": color_blanc}, "texte6":{"t":"For example, this is wolf. This perspective highlights the tail and the hind legs, but obscures the head and face.", "y": window.innerHeight*0.45, "c": color_blanc}, "texte7":{"t":"This viewpoint reveal the head, face, and front legs but hides the tail and barely shows the hind legs.", "y": window.innerHeight*0.6, "c": color_blanc}, "texte8":{"t":"What is a good viewpoint?", "y": window.innerHeight*0.15, "c": color_rouge}, -"texte9":{"t":"> A good point of view corresponds to a position from which we can observe representative parts of an object that allow us to identify it. And also to observe the most salient elements. The more characteristic elements a viewpoint contains, the better the viewpoint will be considered.", "y": window.innerHeight*0.2, "c": color_blanc}, -"texte10":{"t":"The purpose of this study is to ask you, for a given object, which are for you the best viewpoints and why. The answers will of course be subjective because everyone has their own opinion. This subjective information is what I am interested in.", "y": window.innerHeight*0.45, "c": color_blanc}, -"texte11":{"t":"Now that you are up to speed, here are the instructions of the study:", "y": window.innerHeight*0.15, "c": color_blanc}, -"texte12":{"t":"- You will be presented "+nb_mesh+" different objects.", "y": window.innerHeight*0.25, "c": color_blanc}, -"texte13":{"t":"- For each of them, you will chose "+nb_choix_demande+" viewpoints you find most representative of the given object.", "y": window.innerHeight*0.35, "c": color_blanc}, -"texte14":{"t":"- Afterward, you will answer a few questions to justify your choices.", "y": window.innerHeight*0.5, "c": color_blanc}, -"texte15":{"t":"As a mean for you to get familiar with the interface, and make your selection easier, we have set up a quick tutorial.", "y": window.innerHeight*0.6, "c": color_blanc}, -"texte16":{"t":"But before anything, we need you to register in order to save your answers.", "y": window.innerHeight*0.7, "c": color_blanc}, +"texte9":{"t":"> A good viewpoint is one that offers a pleasant view of the object. A more geometrical definition: a good viewpoint is a position from which most representative characteristics of an object (i.e. the parts that make the object the most identifiable), are visible.", "y": window.innerHeight*0.2, "c": color_blanc}, +"texte10":{"t":"Let's imagine that you have to create an advertising display to promote the movie Dances with Wolves.", "y": window.innerHeight*0.45, "c": color_blanc}, +"texte11":{"t":"The purpose of this study is to ask you, for a given object, which are for you the best viewpoints and why. The answers will of course be subjective because everyone has their own opinion. This subjective information is what I am interested in.", "y": window.innerHeight*0.7, "c": color_blanc}, +"texte12":{"t":"Now that you are up to speed, here are the instructions of the study:", "y": window.innerHeight*0.15, "c": color_blanc}, +"texte13":{"t":"- You will be presented "+nb_mesh+" different objects.", "y": window.innerHeight*0.25, "c": color_blanc}, +"texte14":{"t":"- For each of them, you will chose "+nb_choix_demande+" viewpoints you find most representative of the given object.", "y": window.innerHeight*0.35, "c": color_blanc}, +"texte15":{"t":"- Afterward, you will answer a few questions to justify your choices.", "y": window.innerHeight*0.5, "c": color_blanc}, +"texte16":{"t":"As a mean for you to get familiar with the interface, and make your selection easier, we have set up a quick tutorial.", "y": window.innerHeight*0.6, "c": color_blanc}, +"texte17":{"t":"But before anything, we need you to register in order to save your answers.", "y": window.innerHeight*0.7, "c": color_blanc}, } textes_page_1 = [textes["texte0"], textes["texte1"], textes["texte2"]] textes_page_2 = [textes["texte3"], textes["texte4"], textes["texte5"], textes["texte6"], textes["texte7"]] -textes_page_3 = [textes["texte8"], textes["texte9"], textes["texte10"]] -textes_page_4 = [textes["texte11"], textes["texte12"], textes["texte13"], textes["texte14"], textes["texte15"], textes["texte16"]] +textes_page_3 = [textes["texte8"], textes["texte9"], textes["texte10"], textes["texte11"]] +textes_page_4 = [textes["texte12"], textes["texte13"], textes["texte14"], textes["texte15"], textes["texte16"], , textes["texte17"]] texte_a_afficher = [textes["texte0"]] } diff --git a/static/fonctions_inscription.js b/static/fonctions_inscription.js index 7955945..d2fc358 100644 --- a/static/fonctions_inscription.js +++ b/static/fonctions_inscription.js @@ -138,7 +138,7 @@ function afficher_champs_inscription() { nb_caract_max = 30 x_texte_zone = (window.innerWidth/3) y_texte_zone = 200 - ecart_texte_zone = 160 + ecart_texte_zone = 120 // Zone de texte : Firstname var input = document.createElement('input');