Browse Source

First_commit

Joao Conceicao Nunes 3 years ago
commit
f4a3d52e06
55 changed files with 796 additions and 0 deletions
  1. 7
    0
      .classpath
  2. 17
    0
      .project
  3. 11
    0
      .settings/org.eclipse.jdt.core.prefs
  4. BIN
      Capture.PNG
  5. BIN
      Images/Install_Trinus/1.PNG
  6. BIN
      Images/Install_Trinus/2.PNG
  7. BIN
      Images/Install_Trinus/3.PNG
  8. BIN
      Images/Install_Trinus/4.PNG
  9. BIN
      Images/Install_Trinus/5.PNG
  10. BIN
      Images/Install_Trinus/6.PNG
  11. BIN
      Images/Install_Trinus/7.PNG
  12. BIN
      Images/Install_Wiimote/1.PNG
  13. BIN
      Images/Install_Wiimote/2.PNG
  14. BIN
      Images/Install_Wiimote/3.PNG
  15. BIN
      Images/Install_Wiimote/4.PNG
  16. BIN
      Images/Install_Wiimote/5.PNG
  17. BIN
      Logo_ISDAT.PNG
  18. BIN
      Nom_Cours.PNG
  19. 4
    0
      README.txt
  20. 7
    0
      bin/.classpath
  21. 17
    0
      bin/.project
  22. 11
    0
      bin/.settings/org.eclipse.jdt.core.prefs
  23. BIN
      bin/Application1/Fenetre$1.class
  24. BIN
      bin/Application1/Fenetre$2.class
  25. BIN
      bin/Application1/Fenetre$3.class
  26. BIN
      bin/Application1/Fenetre.class
  27. BIN
      bin/Application1/ImagePanel.class
  28. BIN
      bin/Application1/Main.class
  29. BIN
      bin/Application1/TextPanel.class
  30. BIN
      bin/Application1/carte.class
  31. BIN
      bin/Application1/titre.class
  32. BIN
      bin/Capture.PNG
  33. BIN
      bin/Images/Install_Trinus/1.PNG
  34. BIN
      bin/Images/Install_Trinus/2.PNG
  35. BIN
      bin/Images/Install_Trinus/3.PNG
  36. BIN
      bin/Images/Install_Trinus/4.PNG
  37. BIN
      bin/Images/Install_Trinus/5.PNG
  38. BIN
      bin/Images/Install_Trinus/6.PNG
  39. BIN
      bin/Images/Install_Trinus/7.PNG
  40. BIN
      bin/Images/Install_Wiimote/1.PNG
  41. BIN
      bin/Images/Install_Wiimote/2.PNG
  42. BIN
      bin/Images/Install_Wiimote/3.PNG
  43. BIN
      bin/Images/Install_Wiimote/4.PNG
  44. BIN
      bin/Images/Install_Wiimote/5.PNG
  45. BIN
      bin/Logo_ISDAT.PNG
  46. BIN
      bin/Nom_Cours.PNG
  47. 4
    0
      bin/README.txt
  48. BIN
      bin/test.png
  49. 176
    0
      src/Application1/Fenetre.java
  50. 42
    0
      src/Application1/ImagePanel.java
  51. 35
    0
      src/Application1/Main.java
  52. 33
    0
      src/Application1/TextPanel.java
  53. 377
    0
      src/Application1/carte.java
  54. 55
    0
      src/Application1/titre.java
  55. BIN
      test.png

+ 7
- 0
.classpath View File

@@ -0,0 +1,7 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<classpath>
3
+	<classpathentry kind="src" path="src"/>
4
+	<classpathentry excluding="src/" kind="src" path=""/>
5
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
6
+	<classpathentry kind="output" path="bin"/>
7
+</classpath>

+ 17
- 0
.project View File

@@ -0,0 +1,17 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<projectDescription>
3
+	<name>App1</name>
4
+	<comment></comment>
5
+	<projects>
6
+	</projects>
7
+	<buildSpec>
8
+		<buildCommand>
9
+			<name>org.eclipse.jdt.core.javabuilder</name>
10
+			<arguments>
11
+			</arguments>
12
+		</buildCommand>
13
+	</buildSpec>
14
+	<natures>
15
+		<nature>org.eclipse.jdt.core.javanature</nature>
16
+	</natures>
17
+</projectDescription>

+ 11
- 0
.settings/org.eclipse.jdt.core.prefs View File

@@ -0,0 +1,11 @@
1
+eclipse.preferences.version=1
2
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
3
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
4
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
5
+org.eclipse.jdt.core.compiler.compliance=1.8
6
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
7
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
8
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
9
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
10
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
11
+org.eclipse.jdt.core.compiler.source=1.8

BIN
Capture.PNG View File


BIN
Images/Install_Trinus/1.PNG View File


BIN
Images/Install_Trinus/2.PNG View File


BIN
Images/Install_Trinus/3.PNG View File


BIN
Images/Install_Trinus/4.PNG View File


BIN
Images/Install_Trinus/5.PNG View File


BIN
Images/Install_Trinus/6.PNG View File


BIN
Images/Install_Trinus/7.PNG View File


BIN
Images/Install_Wiimote/1.PNG View File


BIN
Images/Install_Wiimote/2.PNG View File


BIN
Images/Install_Wiimote/3.PNG View File


BIN
Images/Install_Wiimote/4.PNG View File


BIN
Images/Install_Wiimote/5.PNG View File


BIN
Logo_ISDAT.PNG View File


BIN
Nom_Cours.PNG View File


+ 4
- 0
README.txt View File

@@ -0,0 +1,4 @@
1
+Readme to be completeds
2
+Pauline
3
+Joao
4
+Laura

+ 7
- 0
bin/.classpath View File

@@ -0,0 +1,7 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<classpath>
3
+	<classpathentry kind="src" path="src"/>
4
+	<classpathentry excluding="src/" kind="src" path=""/>
5
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
6
+	<classpathentry kind="output" path="bin"/>
7
+</classpath>

+ 17
- 0
bin/.project View File

@@ -0,0 +1,17 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<projectDescription>
3
+	<name>App1</name>
4
+	<comment></comment>
5
+	<projects>
6
+	</projects>
7
+	<buildSpec>
8
+		<buildCommand>
9
+			<name>org.eclipse.jdt.core.javabuilder</name>
10
+			<arguments>
11
+			</arguments>
12
+		</buildCommand>
13
+	</buildSpec>
14
+	<natures>
15
+		<nature>org.eclipse.jdt.core.javanature</nature>
16
+	</natures>
17
+</projectDescription>

+ 11
- 0
bin/.settings/org.eclipse.jdt.core.prefs View File

@@ -0,0 +1,11 @@
1
+eclipse.preferences.version=1
2
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
3
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
4
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
5
+org.eclipse.jdt.core.compiler.compliance=1.8
6
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
7
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
8
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
9
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
10
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
11
+org.eclipse.jdt.core.compiler.source=1.8

BIN
bin/Application1/Fenetre$1.class View File


BIN
bin/Application1/Fenetre$2.class View File


BIN
bin/Application1/Fenetre$3.class View File


BIN
bin/Application1/Fenetre.class View File


BIN
bin/Application1/ImagePanel.class View File


BIN
bin/Application1/Main.class View File


BIN
bin/Application1/TextPanel.class View File


BIN
bin/Application1/carte.class View File


BIN
bin/Application1/titre.class View File


BIN
bin/Capture.PNG View File


BIN
bin/Images/Install_Trinus/1.PNG View File


BIN
bin/Images/Install_Trinus/2.PNG View File


BIN
bin/Images/Install_Trinus/3.PNG View File


BIN
bin/Images/Install_Trinus/4.PNG View File


BIN
bin/Images/Install_Trinus/5.PNG View File


BIN
bin/Images/Install_Trinus/6.PNG View File


BIN
bin/Images/Install_Trinus/7.PNG View File


BIN
bin/Images/Install_Wiimote/1.PNG View File


BIN
bin/Images/Install_Wiimote/2.PNG View File


BIN
bin/Images/Install_Wiimote/3.PNG View File


BIN
bin/Images/Install_Wiimote/4.PNG View File


BIN
bin/Images/Install_Wiimote/5.PNG View File


BIN
bin/Logo_ISDAT.PNG View File


BIN
bin/Nom_Cours.PNG View File


+ 4
- 0
bin/README.txt View File

@@ -0,0 +1,4 @@
1
+Readme to be completeds
2
+Pauline
3
+Joao
4
+Laura

BIN
bin/test.png View File


+ 176
- 0
src/Application1/Fenetre.java View File

@@ -0,0 +1,176 @@
1
+package Application1;
2
+import java.awt.BorderLayout;
3
+import java.awt.CardLayout;
4
+import java.awt.Color;
5
+import java.awt.ComponentOrientation;
6
+import java.awt.Dimension;
7
+import java.awt.FlowLayout;
8
+import java.awt.Font;
9
+import java.awt.Graphics;
10
+import java.awt.GridBagConstraints;
11
+import java.awt.GridLayout;
12
+import java.awt.Image;
13
+import java.awt.event.ActionEvent;
14
+import java.awt.event.ActionListener;
15
+import java.io.File;
16
+import java.io.IOException;
17
+
18
+import javax.imageio.ImageIO;
19
+import javax.swing.BorderFactory;
20
+import javax.swing.JButton;
21
+import javax.swing.JFrame;
22
+import javax.swing.JLabel;
23
+import javax.swing.JPanel;
24
+import javax.swing.JTextArea;
25
+import javax.swing.JTextField;
26
+import javax.swing.border.Border;
27
+import javax.swing.border.EmptyBorder;
28
+
29
+public class Fenetre  extends JFrame implements ActionListener{
30
+	
31
+	
32
+	
33
+	
34
+	//Initialisation des objets
35
+	 private JPanel conteneur;
36
+	 private titre conteneurTitre;
37
+	 private JPanel conteneurBouton; 
38
+	 private JButton boutonrev;
39
+	 private JButton boutonsuiv;
40
+	 private JButton boutonfininstall;
41
+	 private CardLayout cl;
42
+	 private FlowLayout fl;
43
+	 String[] listContent = {"CARD_1","CARD_2","CARD_3","CARD_4","CARD_5","CARD_6","CARD_7"};
44
+	 
45
+	 public int Indice = 0;
46
+	 public Graphics g ;
47
+	 
48
+	 
49
+	 
50
+	 
51
+	 
52
+	 
53
+	 
54
+	 public Fenetre() {
55
+		 //Création des objets
56
+		 conteneur = new JPanel();
57
+		 conteneurTitre = new titre();
58
+		 conteneurBouton = new JPanel();
59
+		 boutonrev = new JButton("Revenir");
60
+		 boutonsuiv = new JButton("Suivant");
61
+		 boutonfininstall = new JButton("Lancer VR");
62
+		 cl = new CardLayout();
63
+		 
64
+		
65
+		 g=getGraphics();
66
+		 
67
+		 //SetUp de la fenetre
68
+		 this.setSize(1200,900);
69
+		 this.setLocationRelativeTo(null); //On le garde centrée
70
+		 this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); //Pour réellement fermer la fenetre
71
+		 this.dispose();
72
+		 this.setUndecorated(false);
73
+		 conteneur.setPreferredSize(new Dimension(1100,640));
74
+		 conteneurBouton.setPreferredSize(new Dimension(1200,50));
75
+		 
76
+		 
77
+		 
78
+			
79
+		 //Création des pages
80
+		 ImagePanel card1 = new ImagePanel("test.png");
81
+		 carte card2 = new carte(2,1);
82
+		 carte card3 = new carte(3,1);
83
+		 carte card4 = new carte(4,1);
84
+		 carte card5 = new carte (5,1);
85
+		 carte card6 = new carte (6,1);
86
+		 carte card7 = new carte (7,1);
87
+		 
88
+		
89
+		
90
+		cl.setHgap(10);
91
+		cl.setVgap(10);
92
+		
93
+		
94
+		 
95
+		//SetUp des conteneurs
96
+		
97
+		 conteneurBouton.setBackground(Color.BLACK);
98
+		 conteneurBouton.add(boutonrev);
99
+		 conteneurBouton.add(boutonsuiv);
100
+		 conteneurBouton.add(boutonfininstall);
101
+		 
102
+		 
103
+		 
104
+		 
105
+		 conteneur.setLayout(cl);
106
+		 conteneur.add(card1,listContent[0]);
107
+		 conteneur.add(card2,listContent[1]);
108
+		 conteneur.add(card3,listContent[2]);
109
+		 conteneur.add(card4,listContent[3]);
110
+		 conteneur.add(card5,listContent[4]);
111
+		 conteneur.add(card6,listContent[5]);
112
+		 conteneur.add(card7,listContent[6]);
113
+		
114
+		
115
+	
116
+		
117
+		
118
+		
119
+	
120
+		 
121
+	    
122
+		
123
+		
124
+		// Gestion de l'action des Boutons
125
+		
126
+	    boutonsuiv.addActionListener(new ActionListener() {
127
+	    	public void actionPerformed(ActionEvent event) {
128
+	    		cl.next(conteneur);
129
+	    		
130
+	    	}
131
+	    });
132
+	    boutonrev.addActionListener(new ActionListener() {
133
+	    	public void actionPerformed(ActionEvent event) {
134
+	    		cl.previous(conteneur);
135
+	    		
136
+	    		
137
+	    	}
138
+	    });
139
+	    
140
+	    boutonfininstall.addActionListener(new ActionListener() {
141
+	    	public void actionPerformed(ActionEvent event) {
142
+	    		cl.show(conteneur,"CARD_7");
143
+	    		
144
+	    		
145
+	    		
146
+	    	}
147
+	    });
148
+		
149
+		
150
+		//Affichage 
151
+		this.getContentPane().add(conteneurBouton, BorderLayout.SOUTH);
152
+		this.getContentPane().add(conteneur, BorderLayout.CENTER);
153
+		this.getContentPane().add(conteneurTitre,BorderLayout.NORTH);
154
+		this.setVisible(true);
155
+		conteneurTitre.setBorder(new EmptyBorder(10,10,10,10));
156
+		
157
+		
158
+		
159
+		
160
+		
161
+		
162
+		
163
+		
164
+	
165
+		
166
+	}
167
+
168
+
169
+	
170
+	public void actionPerformed(ActionEvent arg0) {
171
+		// TODO Auto-generated method stub
172
+		
173
+	}
174
+
175
+
176
+}

+ 42
- 0
src/Application1/ImagePanel.java View File

@@ -0,0 +1,42 @@
1
+package Application1;
2
+
3
+import java.awt.Graphics;
4
+import java.awt.Image;
5
+import java.io.File;
6
+import java.io.IOException;
7
+
8
+import javax.imageio.ImageIO;
9
+import javax.swing.JPanel;
10
+
11
+public class ImagePanel extends  JPanel {
12
+	private String chemin;
13
+	private int TailleImageX;
14
+	private int TailleImageY;
15
+	private int TailleEspaceDestX;
16
+	private int TailleEspaceDestY;
17
+	private Image Img;
18
+	private int type; // Il s'agit du type de pannel. 1=> 1 cadran, 2 = > 4 cadrans
19
+
20
+	public ImagePanel( String path) {
21
+		
22
+		try {
23
+			
24
+			Img = ImageIO.read(new File(path));
25
+			TailleImageY = Img.getHeight(null);
26
+			TailleImageX = Img.getWidth(null);
27
+			
28
+			
29
+		}			
30
+		 catch (IOException e) {
31
+			// TODO Auto-generated catch block
32
+			e.printStackTrace();
33
+		}
34
+	}
35
+	
36
+	public void paintComponent(Graphics g) {
37
+		g.drawImage(this.Img, 0, 0,this.getWidth(),this.getHeight(),0,0,TailleImageX,TailleImageY, null);
38
+		
39
+	}
40
+		
41
+
42
+}

+ 35
- 0
src/Application1/Main.java View File

@@ -0,0 +1,35 @@
1
+package Application1;
2
+
3
+import java.awt.Desktop;
4
+import java.io.File;
5
+import java.io.IOException;
6
+
7
+public class Main {
8
+	public static void main(String[] args) {
9
+		Fenetre fenetre = new Fenetre();
10
+		Desktop Starter = Desktop.getDesktop();
11
+		
12
+		
13
+		File file = new File("C:\\Users\\nunes\\Desktop\\Travail\\PIR\\Software\\Glovepie\\WiimoteScripts\\Test.PIE");
14
+		
15
+		
16
+		
17
+		
18
+		/*try {
19
+			//Starter.open(file);
20
+		} catch (IOException e) {
21
+			// TODO Auto-generated catch block
22
+			e.printStackTrace();
23
+		}
24
+		*/
25
+		
26
+		
27
+	
28
+	
29
+	
30
+	
31
+	
32
+	
33
+	
34
+	}
35
+}

+ 33
- 0
src/Application1/TextPanel.java View File

@@ -0,0 +1,33 @@
1
+package Application1;
2
+
3
+import java.awt.Font;
4
+
5
+import javax.swing.JTextArea;
6
+
7
+public class TextPanel extends JTextArea {
8
+	
9
+	public TextPanel() {
10
+		super();
11
+		Font police = new Font(Font.MONOSPACED, Font.BOLD, 25);
12
+		this.setFont(police);
13
+
14
+	}
15
+	
16
+	public TextPanel(int taille) {
17
+		super();
18
+		Font police = new Font(Font.MONOSPACED, Font.PLAIN, taille);
19
+		this.setFont(police);	
20
+		this.setLineWrap(true);
21
+		this.setWrapStyleWord(true);
22
+		
23
+	}
24
+	
25
+	public void AjouterParagraph(String txt) {
26
+		this.append(txt);
27
+		
28
+	}
29
+	
30
+	
31
+	
32
+
33
+}

+ 377
- 0
src/Application1/carte.java View File

@@ -0,0 +1,377 @@
1
+package Application1;
2
+
3
+import java.awt.Color;
4
+import java.awt.Graphics;
5
+import java.awt.GridLayout;
6
+import java.awt.Image;
7
+import java.io.File;
8
+import java.io.IOException;
9
+import java.util.concurrent.TimeUnit;
10
+
11
+import javax.imageio.ImageIO;
12
+import javax.swing.BorderFactory;
13
+import javax.swing.JButton;
14
+import javax.swing.JLabel;
15
+import javax.swing.JPanel;
16
+import javax.swing.JTextArea;
17
+import javax.swing.border.Border;
18
+import javax.swing.border.EtchedBorder;
19
+
20
+public class carte extends JPanel{
21
+	private int numero;
22
+	private Color couleur; // Background Color
23
+	
24
+	private int type; 
25
+	// type:= 1 => Installation
26
+	// type:= 2 => Fonctionnement
27
+	
28
+	
29
+	
30
+	
31
+	
32
+	public carte (int i, int t) {
33
+		
34
+		numero = i;
35
+		//couleur = Color.WHITE; //Default
36
+		type = t;
37
+		int taille; //taille police
38
+		
39
+		Border border = BorderFactory.createEtchedBorder(EtchedBorder.RAISED);
40
+		Border blackline = BorderFactory.createLineBorder(Color.black);
41
+		Border compound;
42
+		compound = BorderFactory.createCompoundBorder(border, blackline);
43
+		JButton boutontest = new JButton("Test");
44
+		
45
+		if (i==2) {
46
+			
47
+			
48
+			//Initialitsation
49
+			TextPanel cadran1;
50
+			TextPanel cadran2;
51
+			TextPanel cadran3;
52
+			TextPanel cadran4;
53
+			GridLayout g= new GridLayout(2,2);
54
+			g.setHgap(10);
55
+			g.setVgap(10);
56
+			setLayout(g);
57
+			
58
+			
59
+			//Cadran 1 
60
+			taille = 15; //taille police
61
+			cadran1 = new TextPanel(taille);
62
+			
63
+			
64
+			
65
+			cadran1.setBorder(compound);
66
+			cadran1.AjouterParagraph("       \n");
67
+			cadran1.AjouterParagraph("                Du BIM à la Réalité Virtuelle!   \n");
68
+			cadran1.AjouterParagraph("       \n");
69
+			cadran1.AjouterParagraph("  Projet issu d'une collaboration entre l'INSA et l'ISDAT. \n");
70
+			cadran1.AjouterParagraph(" \n");
71
+			cadran1.AjouterParagraph("  A partir d'une simulation BIM réalisée par les élèves de l'ISDAT, \n");
72
+			cadran1.AjouterParagraph("  ceux de l'INSA ont mis au point une application permettant \n");
73
+			cadran1.AjouterParagraph("  de visualiser un environnement virtuel dépendant \n");
74
+			cadran1.AjouterParagraph("  de la maquette BIM, afin d'intéragir avec \n");
75
+			cadran1.AjouterParagraph("  lui au sein de cette réalité virtuelle. \n");
76
+			cadran1.setEditable(false);
77
+			
78
+			
79
+			//Cadran 2
80
+			taille = 15; //taille police
81
+			cadran2 = new TextPanel(taille);	
82
+			
83
+			cadran2.AjouterParagraph("       \n");
84
+			cadran2.AjouterParagraph("  Participants à la réalisation du projet : \n");
85
+			cadran2.AjouterParagraph("       \n");
86
+			cadran2.AjouterParagraph("  Elèves de l'INSA :   Elèves de l'ISDAT :   Tuteurs : \n");
87
+			cadran2.AjouterParagraph(" \n");
88
+			cadran2.AjouterParagraph("  AMOUR Chadi                                 BRUYERE Nathalie \n");
89
+			cadran2.AjouterParagraph("  BERRADA El Ghali                            MONTEIL Thierry \n");
90
+			cadran2.AjouterParagraph("  BERTA Pauline \n");
91
+			cadran2.AjouterParagraph("  BOUOULID Ilias \n");
92
+			cadran2.AjouterParagraph("  NUNES Joao \n");
93
+			cadran2.AjouterParagraph("  POLONI Laura \n");
94
+			cadran2.AjouterParagraph("       \n");
95
+			cadran2.setEditable(false);
96
+			cadran2.setBorder(compound);
97
+			
98
+			
99
+			//Cadran 3 
100
+			taille = 15; //taille police
101
+			cadran3 = new TextPanel(taille);
102
+			
103
+			cadran3.AjouterParagraph("       \n");
104
+			cadran3.AjouterParagraph("  Logiciels nécessaires à la bonne réalisation du projet : \n");
105
+			cadran3.AjouterParagraph("       \n");
106
+			cadran3.AjouterParagraph("  Revit \n");
107
+			cadran3.AjouterParagraph("  GrassHopper (avec son plugin) \n");
108
+			cadran3.AjouterParagraph("  Trinus \n");
109
+			cadran3.AjouterParagraph("  GlovePie \n");
110
+			cadran3.AjouterParagraph("       \n");
111
+			cadran3.AjouterParagraph("  Nous vous expliquerons par la suite quels sont les logiciels \n");
112
+			cadran3.AjouterParagraph("  prérequis, et quels sont ceux dont nous allons guider l'installation. \n");
113
+			cadran3.setEditable(false);
114
+			cadran3.setBorder(compound);
115
+			
116
+			
117
+			//Cadran 4
118
+			taille = 15; //taille police
119
+			cadran4 = new TextPanel(taille);
120
+			
121
+			cadran4.AjouterParagraph("       \n");
122
+			cadran4.AjouterParagraph("  Matériel nécessaire à la bonne réalisation du projet : \n");
123
+			cadran4.AjouterParagraph("       \n");
124
+			cadran4.AjouterParagraph("  Wiimote \n");
125
+			cadran4.AjouterParagraph("  Sensor bar \n");
126
+			cadran4.AjouterParagraph("  Masque \n");
127
+			cadran4.AjouterParagraph("  Smartphone \n");
128
+			cadran4.AjouterParagraph("       \n");
129
+			cadran4.AjouterParagraph("  Nous vous expliquerons par la suite quel sera l'utilisation \n");
130
+			cadran4.AjouterParagraph("  de chaque matériel et comment les mettre en place. \n");
131
+			cadran4.setEditable(false);
132
+			cadran4.setBorder(compound);
133
+			
134
+			//Ajouter les cadrans
135
+			add(cadran1);
136
+			add(cadran2);
137
+			add(cadran3);
138
+			add(cadran4);			
139
+			
140
+			
141
+		}
142
+		else if (i==3) {
143
+			//Initialitsation
144
+			TextPanel cadran1;
145
+			ImagePanel cadran2;
146
+			TextPanel cadran3;
147
+			TextPanel cadran4;
148
+			GridLayout g= new GridLayout(2,2);
149
+			g.setHgap(10);
150
+			g.setVgap(10);
151
+			setLayout(g);
152
+			
153
+			
154
+			
155
+		}
156
+		else if (i==4) {
157
+			
158
+			//Initialitsation
159
+			TextPanel cadran1;
160
+			ImagePanel cadran2;
161
+			ImagePanel cadran3;
162
+			ImagePanel cadran4;
163
+			GridLayout g= new GridLayout(2,2);
164
+			g.setHgap(10);
165
+			g.setVgap(10);
166
+			setLayout(g);
167
+			
168
+			//Cadran 1 
169
+			taille = 15; //taille police
170
+			cadran1 = new TextPanel(taille);
171
+			
172
+			
173
+			
174
+			cadran1.setBorder(compound);
175
+			cadran1.AjouterParagraph("       \n");
176
+			cadran1.AjouterParagraph(" L'installation du logiciel Trinus est nécessaire pour le bon fonctionnement"
177
+					+ "de notre système.");
178
+			cadran1.AjouterParagraph("L'installation va se lancer automatiquement. "
179
+					+ "Vous devez accepter et suivre les étapes décrites sur les images suivantes.");
180
+			cadran1.setEditable(false);
181
+			
182
+			
183
+			//Cadran 2
184
+			cadran2 = new ImagePanel("Images/Install_Trinus/1.png");
185
+			cadran2.setBorder(compound);
186
+			
187
+			//Cadran3 
188
+			cadran3 = new ImagePanel("Images/Install_Trinus/2.png");
189
+			cadran3.setBorder(compound);
190
+			
191
+			cadran4 = new ImagePanel("Images/Install_Trinus/3.png");
192
+			cadran4.setBorder(compound);
193
+			
194
+			//Ajouter les cadrans
195
+			add(cadran1);
196
+			add(cadran2);
197
+			add(cadran3);
198
+			add(cadran4);
199
+			
200
+			
201
+			
202
+				
203
+			
204
+			
205
+		}
206
+		else if (i==5) {
207
+
208
+			//Initialitsation
209
+			ImagePanel cadran1;
210
+			ImagePanel cadran2;
211
+			ImagePanel cadran3;
212
+			ImagePanel cadran4;
213
+			GridLayout g= new GridLayout(2,2);
214
+			g.setHgap(10);
215
+			g.setVgap(10);
216
+			setLayout(g);
217
+			
218
+			
219
+			cadran1 = new ImagePanel("Images/Install_Trinus/4.png");
220
+			cadran1.setBorder(border);
221
+			cadran2 = new ImagePanel("Images/Install_Trinus/5.png");
222
+			cadran2.setBorder(compound);
223
+			cadran3 = new ImagePanel("Images/Install_Trinus/6.png");
224
+			cadran3.setBorder(compound);
225
+			cadran4 = new ImagePanel("Images/Install_Trinus/7.png");
226
+			cadran4.setBorder(compound);
227
+			
228
+			
229
+			
230
+			
231
+			//Ajout des cadrans
232
+			add(cadran1);
233
+			add(cadran2);
234
+			add(cadran3);
235
+			add(cadran4);
236
+		}
237
+		else if (i==6) {
238
+			
239
+			
240
+			
241
+			
242
+			//Initialitsation
243
+			TextPanel cadran1;
244
+			ImagePanel cadran2;
245
+			ImagePanel cadran3;
246
+			ImagePanel cadran4;
247
+			GridLayout g= new GridLayout(2,2);
248
+			g.setHgap(10);
249
+			g.setVgap(10);
250
+			setLayout(g);
251
+			
252
+			//Cadran 1 
253
+			taille = 15; //taille police
254
+			cadran1 = new TextPanel(taille);
255
+			
256
+			cadran1.setBorder(compound);
257
+			cadran1.AjouterParagraph("       \n");
258
+			cadran1.AjouterParagraph("Maintenant nous devons installer la manette Wiimote.");;
259
+			cadran1.AjouterParagraph("Pour ça nous allons l'ajouter en tant que périphérique bluetooth."
260
+					+ "Le panneau de configuration va apparaitre. Suivez les étapes d'installation avec les images suivantes.");
261
+			cadran1.setEditable(false);
262
+			
263
+			
264
+			//Cadran 2
265
+			cadran2 = new ImagePanel("Images/Install_Wiimote/1.png");
266
+			cadran2.setBorder(compound);
267
+			
268
+			
269
+			//Cadran 3 
270
+			cadran3 = new ImagePanel("Images/Install_Wiimote/2.png");
271
+			cadran3.setBorder(compound);
272
+			
273
+			
274
+			//Cadran 4 
275
+			cadran4 = new ImagePanel("Images/Install_Wiimote/3.png");
276
+			cadran4.setBorder(compound);
277
+			
278
+			
279
+			//Ajout des cadrans
280
+			add(cadran1);
281
+			add(cadran2);
282
+			add(cadran3);
283
+			add(cadran4);
284
+			
285
+			//Lancement du panneau de configuration
286
+			
287
+			Runtime rt = Runtime.getRuntime();
288
+			try {
289
+				rt.exec(new String[] {"cmd.exe","/c","start","control"});
290
+				
291
+			}catch (IOException e) {
292
+				e.printStackTrace();
293
+			}
294
+			
295
+		
296
+	}
297
+		
298
+		else if (i==7) {
299
+			//Initialitsation
300
+			ImagePanel cadran1;
301
+			ImagePanel cadran2;
302
+			TextPanel cadran3;
303
+			JPanel cadran4;
304
+			GridLayout g= new GridLayout(2,2);
305
+			g.setHgap(10);
306
+			g.setVgap(10);
307
+			setLayout(g);
308
+			
309
+			
310
+			//Cadran 1 
311
+			cadran1 = new ImagePanel("Images/Install_Wiimote/4.png");
312
+			
313
+			//Cadran 2
314
+			
315
+			cadran2 = new ImagePanel("Images/Install_Wiimote/5.png");
316
+			
317
+			
318
+			
319
+			//Cadran 3
320
+			taille = 15; //taille police
321
+			cadran3 = new TextPanel(taille);
322
+			cadran3.setBorder(compound);
323
+			cadran3.AjouterParagraph("       \n");
324
+			cadran3.AjouterParagraph("Maintenant nous sommes prets pour utiliser notre système.");
325
+			cadran3.AjouterParagraph("Nous avons installé les logiciels : \n "
326
+					+ "- Trinus. \n "
327
+					+ "- GlovePie.\n"
328
+					+ "-Wiimote controller");
329
+			cadran3.setEditable(false);
330
+			
331
+			
332
+			//Cadran 4 
333
+			
334
+			TextPanel te = new TextPanel(taille);
335
+			te.AjouterParagraph("jddzjz$ zd qzdjqz dqzjd qj zdq zdq zdjq zdjqzjdqjz dq jzd jq"
336
+					+ " zdq zdqz dqz dq zd"
337
+					+ "q zdqzd qzd qzdqzdzqdqzdqzd"
338
+					+ "qzd qzdqz dqzdqzdqz dz");
339
+			te.setEditable(false);
340
+			
341
+			cadran4 = new JPanel();
342
+			GridLayout f = new GridLayout(1,2);
343
+			cadran4.setLayout(f);
344
+			cadran4.add(boutontest);
345
+			cadran4.add(te);
346
+			
347
+			
348
+			
349
+			
350
+			
351
+			
352
+			
353
+			
354
+			
355
+			
356
+			//Ajout Cadran
357
+			add(cadran1);
358
+			add(cadran2);
359
+			add(cadran3);
360
+			add(cadran4);
361
+			
362
+			
363
+			
364
+			
365
+			
366
+		}
367
+	}
368
+	
369
+	public void ColorChange(Color couleur) {
370
+		
371
+		this.setBackground(couleur);
372
+				
373
+	}
374
+	
375
+	
376
+
377
+}

+ 55
- 0
src/Application1/titre.java View File

@@ -0,0 +1,55 @@
1
+package Application1;
2
+
3
+import java.awt.BorderLayout;
4
+import java.awt.Color;
5
+import java.awt.Dimension;
6
+import java.awt.Font;
7
+import java.awt.Graphics;
8
+import java.awt.Image;
9
+import java.io.File;
10
+import java.io.IOException;
11
+
12
+import javax.imageio.ImageIO;
13
+import javax.swing.JLabel;
14
+import javax.swing.JPanel;
15
+import javax.swing.border.EmptyBorder;
16
+
17
+public class titre extends JPanel{
18
+	public titre() {
19
+		
20
+		JLabel Titre = new JLabel("Charpente 2.0");// ???????????????
21
+		Font police = new Font("Arial", Font.BOLD, 24); 
22
+		Titre.setFont(police);  
23
+	    Titre.setForeground(Color.black);
24
+	    this.setBackground(Color.WHITE);
25
+	    Titre.setHorizontalAlignment(JLabel.CENTER);
26
+	    this.add(Titre, BorderLayout.CENTER);
27
+	    this.setPreferredSize(new Dimension(1200,100));
28
+	    this.setBorder(new EmptyBorder(50,50,50,50));
29
+	    
30
+		
31
+	}
32
+
33
+	public void paintComponent(Graphics g) {
34
+		try {
35
+			Image img1 = ImageIO.read(new File("test.png"));
36
+			Image img2 = ImageIO.read(new File("Logo_ISDAT.png"));
37
+			Image img3 = ImageIO.read(new File("Nom_cours.png"));
38
+			g.drawImage(img1, 20, 10,260,130,0,0,354,142, this);
39
+			g.drawImage(img2, 200, 10,370,100,0,0,711,352, this);
40
+			g.drawImage(img3, this.getWidth() - 300, 10, this.getWidth() - 12, 100, 0, 0, 260, 63, this);
41
+			
42
+			
43
+			
44
+			
45
+		} catch (IOException e) {
46
+			// TODO Auto-generated catch block
47
+			e.printStackTrace();
48
+		}
49
+		
50
+		
51
+		
52
+	}
53
+	
54
+
55
+}

BIN
test.png View File


Loading…
Cancel
Save