今、aframeを使って簡単なテストアプリを作っているのですが、<a-sky>タグに指定したイメージファイルがアタッチされず表示ができません。
html
1!DOCTYPE HTML> 2<html> 3 <head> 4 <meta charset="utf-8"/> 5 <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script> 6 <script src="https://cdnjs.cloudflare.com/ajax/libs/aframe/0.3.2/aframe.js"></script> 7 <script type="text/javascript"> 8 function getPhoto () { 9 navigator.camera.getPicture(onSuccess, onFail, 10 { quality: 50,destinationType: Camera.DestinationType.FILE_URI, 11 sourceType: navigator.camera.PictureSourceType.SAVEDPHOTOALBUM }); 12 } 13 14 function onSuccess (imageURI) { 15 var largeImage = document.getElementById ('#image'); 16 largeImage.style.display = 'block'; 17 largeImage.src = imageURI; 18 } 19 20 function onFail (message) { 21 alert('An error Occured: ' + message); 22 } 23 24 </script> 25 26 </head> 27 28 <body> 29 <p>Choose a Picture</p> 30 <input type="file" id="image_file" name-"image_file" ng-click="getPhoto()" accept="image/*"><br> 31 <a-scene> 32 <a-camera position="0 0 0"></a-camera> 33 <a-sky id="image" src=""></a-sky> 34 </a-scene> 35 </body> 36 37 38</html>
何か記述におかしいところがあるのでしょうか?アドバイスをいただけるとありがたいです。
よろしくお願いします。
あなたの回答
tips
プレビュー