Code Monkey home page Code Monkey logo

3d-scene-editor's Introduction

3D-Scene-Editor

project website: https://zilixie.github.io/3D-Scene-Editor/

A 3D scene editor implemented in C++ combined with OpenGL. It supports the functionalities of insert, tranlate, colorize, rotate, scale, animate, delete for triangle mesh objects in .OFF file format and it allows users to export scene into .svg files.

How To Use

O: Start Translation mode.
P: Start Deletion mode.
U: Start Animation mode.
SPACE: Start/Stop the rotation of camera (by default the camera rotates arounf Y axis).
<, >: Change color for selected object.
/: Change projection (perspective or orthogonal)</br> [,]: change the shading method (vertex normal or face normal)
↑,↓,←,→: Move the camera on trackball up, down, left, right respectively by 2 degree.
+,-: Zoom in or out by 3%.
J,M: Rotate the selected Object by 2 degree clockwise or counter-clockwise around the Y axis.
H,N: Rotate the selected Object by 2 degree clockwise or counter-clockwise around the Z axis.
G,B: Rotate the selected Object by 2 degree clockwise or counter-clockwise around the X axis.
K,L: Scale the selected object up or down by 5% respectively.
W,S: Move the camera on Y axis.
E,D: Move the camera on X axis.
R,F: Move the camera on Z axis.
Z: Start the animation if the bezier curve for an object was constructed.
X: Take a screenshot and export scene to .svg file.
Q: Quit the program.

Operations

The following section will introduce all the operations supported by this application.

Object Insert

Instruction:
press '1' on keyboard will insert a unit cube;
press '2' on keyboard will insert a bunny;
press '3' on keyboard will insert a bumpy cube;

Object Control

Instruction:
press 'O' on keyboard;
click on an object;
release the mouse;
press J,M to rotation on Y axis;
press H,N to rotation on Z axis;
press G,B to rotation on X axis;
press K,L to scale;
Rotate, Scale, Translate

Camera & View Control

Instruction: press ↑,↓,←,→ to move position of camera (in a trackball);
scroll up or down to change the distance from camera to origin;
move camera

Animation

Instruction:
press 'U' on keyboard;
click on an object;
click on a place where you want to place the first control point;
click on a place where you want to place the second control point;
click on a place where you want to place the third control point;
click on a place where you want to place the forth control point;
press 'Z' to start or pause animation;
click on control point and don't release, drag the control point will edit the bezier curve;
click on other object to make animation for other object or see the control points if bezier curve has been contructed;

Export SVG

Instruction: press 'X' anytime when you want to capture the scene;

image image

How To Run?

Within the zx979 folder:

cd Assignment_3
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release ../
make
./Assignment3_bin

3d-scene-editor's People

Contributors

zilixie avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

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.