aframe

Looking for a way in aframe to rotate and scale a model via touch when rendered over a marker

耗尽温柔 提交于 2019-12-22 12:38:34
问题 I'm loading this Collada (DAE) model with aframe 0.8.2 and using aframe-ar to display it over a Hiro marker: <meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0"> <script src="https://aframe.io/releases/0.8.2/aframe.min.js"></script> <script src="https://cdn.rawgit.com/jeromeetienne/AR.js/1.5.5/aframe/build/aframe-ar.js"></script> <body style='margin : 0px; overflow: hidden;'> <a-scene embedded arjs='trackingMethod: best; debugUIEnabled:

Writing test specs for A-Frame

≡放荡痞女 提交于 2019-12-22 12:37:07
问题 I'm totally new to VR and am working on a Vr space shooter in AFrame for a class project and was wondering if there is any documentation/standards for TDD in AFrame. Could anyone point me in the right direction? 回答1: Build your application almost entirely in A-Frame components: https://aframe.io/docs/0.4.0/guides/writing-a-component.html Then test the components. Just about every component in the A-Frame codebase has unit tests: https://github.com/aframevr/aframe/tree/master/tests/components

How to integrate aframe to my project ANGULAR-CLI?

£可爱£侵袭症+ 提交于 2019-12-22 10:58:19
问题 Hello try integrating aframe in the following way: npm install aframe --save setup the angular-cli.json "scripts": ["../node_modules/aframe/dist/aframe-master.js"] Download the typings from https://github.com/devpaul/aframe-typings/blob/master/src/AFRAME.d.ts setup the tsconfig.json "files":["typings/AFRAME.d.ts"] And I get the following error: Cannot find namespace 'THREE' 回答1: In src/polyfills.ts you can import 'aframe'; before you import 'zone.js/dist/zone' 来源: https://stackoverflow.com

a-frame vr how to drag and drop assets / elements insight a picture?

风流意气都作罢 提交于 2019-12-22 09:47:58
问题 I am trying out a-frame and can't find anything about how to drag and drop elements and have been looking for it for hours! Is anyone familiar with a-frame? Thanks thats my code so far: <a-scene> <a-cursor></a-cursor> <a-assets> <img id="enemy-sprite" crossorigin="" src="mustache1.jpg"> </a-assets> <a-image look-at="#player" src="#enemy-sprite" transparent="true" position="0 1.8 -4"></a-image> <a-camera id="player" position="0 1.8 0"></a-camera> <a-sky src="street.jpg"></a-sky> EDIT: browser

A-Frame. Zoom on wheel scroll

穿精又带淫゛_ 提交于 2019-12-21 20:57:13
问题 I've come through the official docs but wasn't able to locate information about how possibility of zooming in/out panorama images, is it supported in the A-Frame or maybe there is a workaround to read about implementing some of three.js on top of it? 回答1: You could either: Scale an <a-sphere> up or down when detecting the mouse wheel event zoom in or out the camera, like documented here This article might be helpful, as it covers using the mousewheel event on multiple browsers. I think

How can I display text in A-Frame?

一曲冷凌霜 提交于 2019-12-21 10:38:38
问题 For http://aframe.io/, how can I render text without having to create an image? 回答1: EDIT: A text component has landed in A-Frame master branch. This will roll out in 0.5.0. The component will have support for fonts, alignments, anchors, baselines, shaders, etc. <a-entity text="value: HELLO"></a-entity> https://aframe.io/docs/master/components/text.html You can use some of the community components: https://github.com/bryik/aframe-bmfont-text-component - Text drawn using signed distance field

How to defer or load an A-Frame scene programmatically?

耗尽温柔 提交于 2019-12-21 06:19:18
问题 I have an A-Frame scene that I want to place on a page, but I want it to load only when I tell it to. That means it should not be rendering or running until I emit an event or call a method. <body> <!-- Don't play yet. --> <a-scene> </a-scene> </body> 回答1: There is currently no built-in + documented way, but there will be a feature for this later. However, there are a couple ways to do this manually: Create <a-node> Nodes (which every <a-entity> inherits from will block the scene from loading

How to defer or load an A-Frame scene programmatically?

时光总嘲笑我的痴心妄想 提交于 2019-12-21 06:19:12
问题 I have an A-Frame scene that I want to place on a page, but I want it to load only when I tell it to. That means it should not be rendering or running until I emit an event or call a method. <body> <!-- Don't play yet. --> <a-scene> </a-scene> </body> 回答1: There is currently no built-in + documented way, but there will be a feature for this later. However, there are a couple ways to do this manually: Create <a-node> Nodes (which every <a-entity> inherits from will block the scene from loading

Aframe video only plays muted on ios

我是研究僧i 提交于 2019-12-20 07:39:28
问题 i try playing a 360-video in aframe and it works fine on android and desktop but on ios it dont work. If i mute the video the starting of the video works but i need the sound. Some ideas how to fix that? Here my code: https://jsfiddle.net/237s96ka/1/ <!DOCTYPE html> <html> <head> <title>zoom-showreel</title> <meta charset="utf-8"> <meta author="" inhalt="vr-video"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"> <meta

Aframe video only plays muted on ios

烂漫一生 提交于 2019-12-20 07:39:11
问题 i try playing a 360-video in aframe and it works fine on android and desktop but on ios it dont work. If i mute the video the starting of the video works but i need the sound. Some ideas how to fix that? Here my code: https://jsfiddle.net/237s96ka/1/ <!DOCTYPE html> <html> <head> <title>zoom-showreel</title> <meta charset="utf-8"> <meta author="" inhalt="vr-video"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"> <meta