Giter Club home page Giter Club logo

hello-tiny-box's Introduction

hello-tiny-box's People

Contributors

mithi avatar rohanj-02 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

arjita-mitra

hello-tiny-box's Issues

Arcball References to Read

Camera Control in Three Dimensions with a TwoDimensional Input Device
Mark A Livingston
Arthur Gregory
and Bruce Culbertson
Hewlett�Packard Laboratories
Department of Computer Science University of North Carolina at Chapel
http://www.cs.unc.edu/~livingst/navigate.pdf

Arcball controller
https://pixeladventuresweb.wordpress.com/2016/10/04/arcball-controller/

Tutorial of Arcball without quaternions
https://braintrekking.wordpress.com/2012/08/21/tutorial-of-arcball-without-quaternions/

learn opengl camera
https://learnopengl.com/Getting-started/Camera

OpenGL - Camera Keyboard Controls
https://www.youtube.com/watch?v=v6RZRPo0O3k
W A S D
Move forward, move backward, strafe left, strafe right
left, right, forward and backward is WRT the camera coordinate frame NOT the world coordinate frame

ARCBALL:
A User Interface for Specifying
Three-Dimensional Orientation Using a Mouse
https://www.talisman.org/~erlkonig/misc/shoemake92-arcball.pdf

3d controls
http://www.cabiatl.com/mricro/obsolete/graphics/3d.html

ArcBall / Quaternions
Elevation and Azimuth

http://www.ece.northwestern.edu/local-apps/matlabhelp/techdoc/visualize/chview2.html

ArcBall / Quaternions

http://rainwarrior.ca/dragon/arcball.html

API for 3D plot

API for 3D plotting

const props = { data, viewSettings, sceneSettings, sceneOptions }

// data is an array with elements of type "points", "lines", "polygon", or "ellipse"

const sceneSettings = {
    cubeRange = 800,
    cubeZoffset = 1 // between -1 and 1
    dataZoffset = 0 // between -1 and 1
    paperXrange = 600,
    paperYrange = 600,
}

const viewSettings = {
    canvasToViewRatio // 
    defaultCamOrientation = "z-forward-x-left"
    defaultCamDistance,  // distance of camera from scene cube  (0, 0, 0)
    camTx,
    camTy,
    camTz,
    camZoom, //
    cubeRx,
    cubeRy,
    cubeRz,
}

/*

      z
     /
x---*   "z-forward-x-left"
    |
    y

    z   "z-up-y-left"   
    |
 x--*
     \
      y
  z
  |      "z-up-x-forward"
  *-- y
 /
x

  y
  |      "z-forward-x-right"
  *-- x
 /
z

*/

const sceneOptions = {
    paper,
    axisEdges,
    xyPlane,
    cubeOutline,
    crossSections,
}

const paper = {
    color: "#FFFFFF",
    opacity: 0.8,
}

const xyPlane = {
    show: true,
    color: "#FFFFFF",
    opacity: 0.8
}

const axisEdges = {
    show: true
    opacity: 1.0,
    intersectionPointColor: "#FFFFFF"
    intersectionPointSize: 5
    edgeSize: 5
    xEdgeColor: "#FF0000" // red
    yEdgeColor: "#0000FF" // blue
    zEdgeColor: "#00FF00" // green
}
const cubeOutline = {
    show: true,
    color: "#FFFF00",
    opacity: 1.0,
    size: 5,
}

const crossSection = {
    show: true,
    color: "#FFFFFF",
    opacity: 1.0,
    size: 5
}

const cubeCenter = {
  show: true,
  color: "#FFFFFF",
  opacity: 1.0,
  size: 5
}

const worldCenter = {
  show: true,
  color: "#FFFFFF",
  opacity: 1.0,
  size: 5
}

const worldAxes = {}
const cubeAxes = {}
/*
These are the lines that make up the cross
section

      |
 |    |
 | *--*--*
 |/ _/_ /
 /  /  /
*--*--*
*/

Use painter's algorithm and/or back-face culling algorithm to know which lines, points and planes should be rendered at which order

Use painter's algorithm and/or back-face culling algorithm to know which lines, points and planes should be rendered at which order

A first solution to this issue is known as the Painter’s Algorithm. Real-life painters first draw the backgrounds and then cover parts of them with foreground objects. We could achieve the same effect by taking every triangle in the scene, applying the model and camera transforms, sorting them back to front, and drawing them in that order.

Filling a cube (back-face culling algorithm)? [closed]
https://stackoverflow.com/questions/45689732/filling-a-cube-back-face-culling-algorithm

Hidden Surface Removal
https://gabrielgambetta.com/computer-graphics-from-scratch/hidden-surface-removal.html

Back Face Culling
http://glasnost.itcarlow.ie/~powerk/GeneralGraphicsNotes/HSR/backfaceculling.html

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.