Skip to content

Instantly share code, notes, and snippets.

@Lachee
Created July 5, 2020 09:58
Show Gist options
  • Save Lachee/3fcbb312b4d7c73f8fc28d551741fa40 to your computer and use it in GitHub Desktop.
Save Lachee/3fcbb312b4d7c73f8fc28d551741fa40 to your computer and use it in GitHub Desktop.
Backwards Stuff
https://i.lu.je/2020/J3Up2se5qE.mp4 Here is a mp4 of my current issue. The blue is 0,0,1 (left), and the red is 1,0,0 (right). It is spinning clockwise. Here is a topdown representation: https://i.lu.je/2020/mspaint_60BodePItv.png
Why is the right actually on the left? I can fix this by flipping the perspective, but then everything else is flipped and it rotates counter clockwise?
```golang
var rotCubeVerts = []Vector3{
//Vector3{-1, -1, -1}, Vector3{1, -1, -1}, Vector3{1, 1, -1}, Vector3{-1, 1, -1}, // Back Face
Vector3{-1, -1, 1}, Vector3{1, -1, 1}, Vector3{1, 1, 1}, Vector3{-1, 1, 1}, // Front Face
//Vector3{-1, -1, -1}, Vector3{-1, 1, -1}, Vector3{-1, 1, 1}, Vector3{-1, -1, 1}, // Left Face
Vector3{1, -1, -1}, Vector3{1, 1, -1}, Vector3{1, 1, 1}, Vector3{1, -1, 1}, // Right Face
//Vector3{-1, -1, -1}, Vector3{-1, -1, 1}, Vector3{1, -1, 1}, Vector3{1, -1, -1}, // Bottom Face
Vector3{-1, 1, -1}, Vector3{-1, 1, 1}, Vector3{1, 1, 1}, Vector3{1, 1, -1}, //Top Face
}
```
As you can see, only the correct faces are enabled.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment