README
The Viewer3D project is a C++ based 3D viewer application that enables users to load 3D models and perform various transformations and rendering operations on them. This README file contains important information about the project, including installation instructions, usage, development, and licensing.
To build the project, follow these steps:
- Ensure that CMake version 3.15 or higher is installed on your system.
- Clone the project repository to your local machine.
- Open a terminal window and navigate to the project directory.
- Create a new build directory within the project directory.
- Navigate to the build directory and run the command
cmake ..
to generate the makefile. - Run the command
make
to build the project.
The Viewer3D project has the following dependencies:
- CMake version 3.15 or higher
- C++ (CXX) and C languages
- CMake_INCLUDE_CURRENT_DIR variable set to ON
- CMake_AUTOUIC, CMake_AUTOMOC, and CMake_AUTORCC variables set to ON
- C standard version 11
- C++ standard version 17
- assimp library
- Qt libraries (version 5 or 6), specifically the Widgets and Gui components
- OpenGL, Qt5Core, Qt5Widgets, Qt5Gui, and Qt5OpenGL libraries (for Windows systems)
- QtOpenGL and OpenGLWidgets components (for non-Windows systems)
The Viewer3D application provides the following functionalities:
-
Model Loading: The application allows loading 3D models from different file formats such as obj, stl, fbx, dae, etc. These models can include vertices, surfaces, normals, textures, and other attributes.
-
Transformations: Translation, rotation, and scaling of models are essential features in the application. Users can move, rotate or scale models to create animations or position them in the desired location in the scene.
-
User Interface: The application provides a graphical user interface (GUI) for easy interaction with the software. The GUI allows users to select different tools and options, and to modify various properties of the models, such as lighting, materials, textures, and rendering options.
To use the Viewer3D application, follow these steps:
- Launch the application.
- Load a 3D model by selecting the "File" menu and choosing "Open Model."
- Use the transformation tools to move, rotate or scale the loaded model.
- Modify the rendering options as desired using the options available in the GUI.
- Save the modified model if needed by selecting the "File" menu and choosing "Save Model."
Development:
If you would like to contribute to the development of the 3DViewer project, please follow these steps:
- Fork the project on GitHub.
- Clone your forked repository to your local machine.
- Make changes to the code and test them locally.
- Commit your changes and push them to your forked repository.
- Create a pull request on the main repository.
Please note that all contributions must be made under the project's license, which is described below.
License:
The Viewer3D project is licensed under the MIT License. This means that the project can be used for both commercial and non-commercial purposes, and that anyone is free to modify and distribute the source code. However, the project is provided "as is", without warranty of any kind, and the authors of the project will not be held liable for any damages arising from the use of the project.
- Object display area
- Basic application settings
- Object/scene control area
- Light control area
- Texture control area
With the three areas described above, it is possible to perform various manipulations (display over the object display area, close/open, resize and reposition), for example:
- Load the model from a file (obj format)
- Take a snapshot of the current state of the display area, which opens an additional window (screenshot below) for choosing the image format and resolution that the user can set manually or select from corresponding presets.
- Edges
- Display mode (default is none)
- none - do not display edges on the object
- line - display edges as lines
- Size - change the thickness of lines
- Color - change the color of lines
- Display mode (default is none)
- Vertices
- Display mode (default is none)
- none - do not display vertices on the object
- Circle - display vertices as circles
- Square - display vertices as squares
- Size - change the radius of points
- Color - change the color of points
- Display mode (default is none)
- Textures
- Display mode (default is surface)
- none - do not display textures
- Wireframe - display a wireframe model of the object
- Surface - display the object as surfaces
- Display mode (default is surface)
When changing the line thickness, an auxiliary window is displayed with a visual representation of the thickness and the ability to change it:
Edge display method | Fin thickness | Rib color | |||
---|---|---|---|---|---|
none |
defaut |
defaut |
|||
Линия |
default++ |
pink |
Way of displaying vertices | Vertex Radius | Vertex color | |||
---|---|---|---|---|---|
none |
defaut |
defaut |
|||
Круг |
default++ |
pink |
|||
Квадрат |
Texture rendering method | none |
Frame |
Surface |
---|---|---|---|
- Color - Change the color of the scene (displayed correctly only when environment is disabled)
- Lighting
- Flat shading - even shading across the entire polygon
- Smooth shading - uses a gradient to change the color of the polygon
- Projection type
- Central
- Parallel
- Grid (coordinate axes and squares in space)
- none
- Display
- Smoothing
- Hard edges
- Soft edges
- Environment (landscape around the object)
- none
- Display
Stage yellow |
Stage green |
---|---|
Flat shading |
Soft shading |
---|---|
Central projection |
Parallel Projection |
---|---|
Show grid |
Grid none |
---|---|
Display environment |
Environment none |
---|---|
Оригинал |
Смещение по X |
Смещение по Y |
Смещение по Z |
---|---|---|---|
Поворот по X |
Поворот по Y (по Z 45) |
Поворот по Z |
Total scale |
Scale X |
Scale Y |
Scale Z |
Normalize |
Specular Highlight |
Reflection |
Transparency |
---|---|---|