Jump to content

Touch Camera limitations?


webGLmmk
 Share

Recommended Posts

I have been trying to figure out which camera to use for a first person navigation through a funky space sim. I"m confused about how Touch Camera controls work.

I've simplified the scene  because it was just too much to load.

the live page is  http://3dwebgs.github.io/miscWebGLpages/starfield.html

Simplified playground: http://www.babylonjs-playground.com/#2BYAZP#2

As far as I understand touchCamera controls, its swipe right and left to pan camera view, ...up and down moves you forward and backward......but there's no way to point up, then MOVE up. Or to point down ,then move down. I can pan right or left, then move that way. But I can't move the camera up or down, because swiping up and down moves forward/backward.   You really can't go up or down from a first person perspective on a touchscreen unless i put an object in there and use followCamera, which I may do in a more advanced version of this scene...doesn't help what I want to do now.

I'd rather use virtualJoysticksCamera but as far as I've seen its out of commission? No circles?

Even better would be to somehow use Canvas2D along with FreeCamera to make simple camera controls..buttons to move in all directions...dont know how to do that quite yet...   <<  wouldn't that be a good camera addition :-D  :-D

 

Link to comment
Share on other sites

Hello

you can use two fingers and swipe up/down to look up/down and then you can simply go forward.

This may not work for you so here is the code, if you want to create another input manager: https://github.com/BabylonJS/Babylon.js/blob/master/src/Cameras/Inputs/babylon.freecamera.input.touch.ts

Link to comment
Share on other sites

On 9/8/2016 at 9:38 AM, Deltakosh said:

Hello

you can use two fingers and swipe up/down to look up/down and then you can simply go forward.

This may not work for you so here is the code, if you want to create another input manager: https://github.com/BabylonJS/Babylon.js/blob/master/src/Cameras/Inputs/babylon.freecamera.input.touch.ts

This may be the layman's solution, but I'm running with it!  http://www.babylonjs-playground.com/#1RRGPI#1

It'll be like remotely operating a space probe  -

input manager creation is on my list...

Friday accomplished.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...