Comments (1)
I also am struggling with this but probably because I stink at coding in JavaScript.
In the code base I use - there is a class just before a function that I'm not sure about. But within what appears to be an initialization function using a GLTF loader doing something with a '=>' thing that enables us to set parameters about the gltf model.
` loadGLTF('https://cdn.glitch.com/f485dc5e-a1b5-4091-8408-6411aea91377%2Ftext_1%20(1).glb?1555527607936').then(gltf => {
gltf.scene.scale.set(.03, .03, .03)
gltf.scene.rotation.set(90, 0, 180)
gltf.scene.position.set(4, 0, -9)
gltf.scene.quaternion.setFromAxisAngle(new THREE.Vector3(0, 0, 0), Math.PI)
gltf.scene.traverse(node => {
if (node.material && (node.material.isMeshStandardMaterial || (node.material.isShaderMaterial && node.material.envMap !== undefined))){
node.material.envMap = this.envMap
node.material.needsUpdate = true
}
})
this.floorGroup.add(gltf.scene)
this.floorGroup.add( axesHelper );
}).catch((...params) =>{
console.error('could not load gltf', ...params)
})
`
I took three approaches here:
- Just copy paste the system from https://threejs.org/docs/index.html#manual/en/introduction/Animation-system
- refactor the bottom portion to play nice
// Play all animations
clips.forEach( function ( clip ) {
mixer.clipAction( clip ).play();
} );
so...
gltf.scene.animationClip.mixer.clipAction.set( play();
- Just use A-frame and hope to the heavens it is that simple.....
None of this worked, obviously. So...if anyone has any spare time to give me a clue it would be much appreciated.
from webxr-polyfill.
Related Issues (20)
- floor anchor in common.js in examples won't work in general
- Can I use OrbitControls or TrackballControls? HOT 2
- XRPointCloud from rawFeaturePoints HOT 3
- CODE_OF_CONDUCT.md file missing
- Make the XR Store code available HOT 1
- [Bug] this._videoFrameCanvas is undefined HOT 1
- why does some examples don't work ? HOT 2
- Finish the WebRTC case for AR
- Make sure we display as much information about errors and failures as we can
- Poor render quality on WebARonARCore viewer HOT 4
- Clarify Anchor vs AnchorOffset in the API HOT 3
- Simplify application logic by exposing XRAnchor-related methods in Reality HOT 1
- Argon browser support, Vuforia image/model tracking & XRAnchor States HOT 7
- The RequestFrame function doesn't pass the delta time information HOT 1
- need a method to remove/destroy anchors HOT 2
- need a listener to subscript to to get notified when new anchors are created
- Undeclared variable _this in XRpolyfill.js HOT 4
- Raycasting is incorrect in mobile AR HOT 1
- Should I use XRDevice or XRDisplay? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from webxr-polyfill.