Questions tagged [axis]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0
votes
2answers
47 views

The camera goes up and down when following a rolling sphere

I have this CameraController script attached to my camera, to follow a sphere that moves using WSAD. ...
2
votes
1answer
114 views

Unity - X axis back to front

I'm using Unity 2018 and its really confusing me. I generate a plane mesh in code and when it comes to positioning (transform.position.x) it on the X axis I can't understand why moving it further to ...
0
votes
3answers
63 views

How to Make Snaky Inchworm Motion With Armature Staying Upright

I have a series of connected bones in a straight line. I want to be able to rotate each bone vertically and/or horizontally so that it can slither and arch randomly kinda like a snake mixed with an ...
0
votes
1answer
817 views

Can't set object's local rotation like rotating from gizmo in the scene

Here, I have a plane model with some sub parts(like aileron) can rotate: That red section is weight painted(rigged) vertices, and I need to control the rotation of this in Unity by script. So this ...
1
vote
0answers
1k views

How to make an object which position is not on the world origin rotate around the world orgin in threejs?

I've loaded an object and set its position on vector(5,2,-5) by threejs. And I wanted it to rotate around the origin point in the world coodinate system. I found a method in class Object3D called '...
1
vote
2answers
108 views

How to clip 3D object in projection (octants)?

In example we've wrote some code in Pascal (graph unit) which rotates 3D object in oblique frontal (dimetric) projection in all octants positioned in center of them. The projection's type: The code ...
0
votes
1answer
316 views

Unity - Inaccurate rotation if object is rotated on two axis at once

I have an object which i want to rotate relative to world space. I have three variables (one for every axis) which store the rotation. By pressing buttons on my controller I add or subtract 90 to ...
0
votes
1answer
62 views

Restrict the rotation of the camera using button

I've been trying to limit the Y-axis of the camera rotation but I'm out of depth until now. I'd looked up many tutorials and I found the clamping method, but I seem can't get it to work on my code, ...
0
votes
1answer
17 views

Issues with Toggle

hope you're all good.. I'm struggling with a simple toggle for inverting Y axis.. What i have works for my first scene but i'm trying to keep this setting through all scenes, hence why the script ...
0
votes
1answer
1k views

Unity Matrix4x4 to rotate a point around a pivot / axis

I need the Matrix4x4 to rotate around a given axis that does not go through (0,0,0). Is there some built in straightforward way to do this in the Unity libraries, or do I need to build and maintain my ...
2
votes
1answer
643 views

Converting Euler rotation angles from Z up to Y up (Max to OpenGL)

I'm working on pulling geometry and it's transformation from a 3DS Max exported FBX (Z-up) to an OpenGL model format (Y-up). The main problem is I intend to keep the transformations as Translation and ...
1
vote
0answers
30 views

Transform arbitrary axes to world axes

I'm in the case I need to transform a Quaternion coordinate system to a concrete one, let me explain. I'm implementing an orientation tracker for VR headsets, I have the orientation of the device and ...
3
votes
3answers
3k views

Why is OpenGL point (0,0) not in top-left corner of the screen?

Most of computer graphics systems use screen's top-left corner as staring point, but OpenGL uses bottom-to-top direction, why?
3
votes
2answers
7k views

Unity / Rotate a point around an arbitrary axis and anchor

I'm trying to find out the point which is already rotated. To solve this I did a Rotation, save the position, set the previous position and return my position, like this: ...
1
vote
1answer
531 views

Get device rotation in Y axis

So using LibGDX accelerometer methods, I'm able to get the rotation of the device in the X and Z axes in degrees with this code: ...
1
vote
2answers
973 views

how to handle the virtual Z axis in 2D games?

I'm using this paper 2d framework of UE4 where a plane mapped with sprite texture is put in 3d world and therefore appears as 2D when viewed from sideways. Its all good for games like NES mario where ...
0
votes
1answer
396 views

Getting vector relative to other vector in rotating object

So I have a rotating object a. It is rotating at non-constant speed around it's local x axis. It is parented to object b. When the object a rotates, it's ...
0
votes
1answer
494 views

Z - Axis value is changing if I move the Game Object in X - Axis in Unity

I am on a small game project . Everything was just fine , but now I have some wired problem . That is Game Object movement . If I move the game object in X - Axis using the gizmo , the value of Z - ...
1
vote
0answers
194 views

How to find or compute or look for overall/max RPM by simply checking for rotation?

I find it hard to determine the wheel RPM since I'm only making a simple 2D game of rotating object via Z-axis. I wanna try this solution but I got no change since I'm trying to find the RPM from a ...
1
vote
1answer
146 views

3D Planetary gravity

so i am making a thing in javascript and i want to have planetary gravity in my "universe". But when i use an equation to calculate the acceleration by gravity i get one number. That is how fast the ...
0
votes
1answer
657 views

Gamepad default trigger identification in Windows

I'm currently writing an interface driver for my Moga Power Pro controller on Windows. I'd like to release it for others to use, but first I have some questions on expected default mappings for the ...
2
votes
1answer
165 views

How to change XNA coordinates directions?

Usually XNA increases X coordinate to right and Y to down. Like this: But in my project i have 2D map. Drawing tile with bigger Y coodinate below OX looking strange (usually people imagines these ...
1
vote
2answers
2k views

Can't set up a PS3 controller in Unity

So I connected a ps3 controller to my computer via USB cable, when I press play I am able to move by using arrows on the left of the ps3 controller and also I am able to shoot and aim by triangle and ...
1
vote
2answers
855 views

Unity 3D - Confine a gun rotation within certain degrees

I am having troubles making my gun rotate up and down, and have limits, for example, I want the down limit to be 0 degrees, and the up limit to be 90 degrees. Currently I can't figure out how to ...
1
vote
1answer
1k views

How to modify the Unity sprite renderer (or create a custom one) that can display the sprites on the X-Z plane?

Prefix: I am NOT trying to rotate a sprite 90 degrees by it's transform, this changes what is up/down and forward/backwards for the object. I need the sprite displayed on the X-Z plane in comparison ...
0
votes
1answer
51 views

Matrix Rotation Only Works On one Axis At A Time

I have this function in my vertex shader. It makes a transformation matix out of a transformation matrix, a rotation and an intensity. It works just fine when setting the rotation of one of the axis (...
1
vote
1answer
929 views

How to constrain axis-angle rotation?

I have a problem where I'm performing an axis-angle rotation and am trying to constrain my rotations. Specifically I have a skeleton (model/mesh with rig, transforms are hierarchy parented to pelvis ...
-3
votes
1answer
809 views

Move the Object in y-axis when the timer increases [closed]

I have a model(.Fbx object),I have placed a timer.When the timer starts increasing the model/object should move down(along y axis).
1
vote
2answers
243 views

Standard key bindings for movement along three axes?

I understand that the WASD keys are standard for moving a character along two axes (left/right, up/down) because in the QWERTY layout, they are arranged like the arrow keys. I want to make a game ...
1
vote
0answers
310 views

PhysX - Revolute joint around unit vector

I'm using a right-handed coordinate system with (0,0,-1) = forward, (1,0,0) = right and ...
1
vote
1answer
418 views

3D model editor manipulators

I'm trying to make my own 3D model editor to better learn 3D programming. I have my translate manipulators and I'm trying to calculate the Vector2 that the mouse would have to move in order to move an ...
1
vote
0answers
540 views

Separating Axis Theorem Issue

I am trying to create a 2d top down shooter using DirectX 11 (Windows 8 Store) and I am trying to implement OOBB collision using the Separating Axis Theorem. However I appear to have run into an ...
2
votes
2answers
4k views

“Align” a rotation to a direction

Good day all. I have a 3d object with a random rotation. I can express that object's rotation both through a quaternion or through an euler rotation. Then I have a vector3 normal that I get from a ...
0
votes
2answers
1k views

How to properly translate a point by a matrix?

I wrote a simple Matrix class and it has methods like rotate, translate, etc. They all seem to be working, but whenever I try to translate a rectangle using the matrix, the translation axis seem to be ...
1
vote
0answers
1k views

Move parent according to child axis in Unity?

Can I ask my parent to move according to the child axis? This means if I turn right, then right again, the parent has to be at 180° from its original position, and not only at 90° (because "Right" ...
3
votes
1answer
561 views

How do I determine a device's default orientation?

I am developing a game with accelerometer controls. This works well on all the mobile phones I've tested it on. However, when testing on a tablet, the y and x axes are reversed, presumably because the ...
8
votes
2answers
1k views

How do I convert a 2D movement (from mouse) to a displacement along a 3d axis?

I'm making a small 3D scene editor (that only allow to modify objects positions). Each object is draw with a 3d X/Y/Z axis : How it works : user choose an axis (X, Y or Z) by left clicking on it, ...
19
votes
4answers
11k views

Why is Y up in many Games?

I learned at school that the z-axis is up. It is the same in modeling software like Blender. However in many games the y-axis is up. What is the reason?