Bonjour,
j'ai un problème de chargement d'un fichier .obj avec Java3d.
Le chargement ce fait nickel avec applet viewer mais des que j'essaye dans une page html il ne veux plus charger.
ma fonction de chargement
et voici l'erreur :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13 String nomObjet = "bozo.obj"; int typeObjet = ObjectFile.RESIZE; ObjectFile fichierObj = new ObjectFile(typeObjet); Scene scene = null; try { scene = fichierObj.load(nomObjet); } catch (Exception e) { System.err.println("Impossible de charger le fichier .obj : " + e); } return scene.getSceneGroup();
Si quelqu'un a une idée ?
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13 java.security.AccessControlException: access denied (java.io.FilePermission bozo.obj read) java.lang.NullPointerException at main3d.loadWavefrontObject(main3d.java:269) at main3d.createSceneTree(main3d.java:85) at main3d.init(main3d.java:35) at sun.applet.AppletPanel.run(Unknown Source) at java.lang.Thread.run(Unknown Source) Exception in thread "thread applet-main3d.class" java.lang.NullPointerException at sun.plugin.util.GrayBoxPainter.showLoadingError(Unknown Source) at sun.plugin.AppletViewer.showAppletException(Unknown Source) at sun.applet.AppletPanel.run(Unknown Source) at java.lang.Thread.run(Unknown Source)
Partager