Skip to content

Commit

Permalink
Merge branch 'SArpnt-master'
Browse files Browse the repository at this point in the history
This is the aproval of pull request created by @SArpnt (#6).
  • Loading branch information
Tumble committed Feb 18, 2021
2 parents c09b6cc + 1d464f2 commit 73a5bdc
Show file tree
Hide file tree
Showing 23 changed files with 275 additions and 154 deletions.
84 changes: 71 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ sudo apt install build-essential cmake libsdl2-dev libglew-dev libglm-dev libass
```
### Arch
```bash
sudo pacman -S base-devel cmake sdl2 glew glm
sudo pacman -S base-devel cmake sdl2 glew glm assimp
```
### Redhat/Fedora
```bash
sudo dnf install kernel-devel cmake sdl
sudo dnf install kernel-devel cmake sdl // TODO
```
## Build Instructions
```bash
Expand Down Expand Up @@ -78,24 +78,82 @@ Pull requests are welcome. For major changes, please open an issue first to disc
- [ ] Mesh Importing
- [ ] Full UV mapping support
- [ ] Full vertex color support
- [ ] Multiple texture materials
- [ ] Multi-texture materials
- [ ] Normals
- [ ] Normal maps
- [ ] Matcaps (SArpnt will do this)
- [ ] Simple object classes (combine assets and automatically manage render commands)
- [ ] Depth manipulation
- [ ] Skybox
- [x] Render triangle strips
- [ ] GL lines
- [ ] Sprites (i think you can do GL_POINTS and draw the images in a frag shader)
- [ ] Supersampling and subsampling
- [ ] Antialiasing
- [ ] MSAA
- [ ] FXAA
- [ ] MSAA with FXAA
- [ ] Mipmaps
- [ ] Anisotropic filtering
- [ ] Texture filtering
- [ ] Nearest
- [ ] Linear
- [ ] Bilinear
- [ ] Trilinear
- [ ] Supersampling / subsampling Interpolation
- [ ] Nearest
- [ ] Bilinear
- [ ] Bicubic
- [ ] Trilinear
- [ ] Lanczos
- [ ] Lights
- [ ] Input System
- [ ] Events System
- [ ] Collision
- [ ] Gravity
- [ ] Text
- [ ] Layers
- [ ] GUI
- [ ] Portals
- [ ] VR Support
- [ ] Test on Windowsbetter
- [ ] Port to Emscripten

### Physics engine (make a seperate project)

- [ ] Shapes
- [ ] Point
- [ ] Line segment
- [ ] Rectangular prism
- [ ] Sphere
- [ ] Cylinder
- [ ] Capsule
- [ ] Cone
- [ ] Ngon prism
- [ ] Elipsoid
- [ ] Mesh
- [ ] Shape collision
- [ ] Shape advanced collision (Get information like position, speeds, collision normals, etc. so that physics can be done)
- [ ] Physics
- [ ] Air resistance
- [ ] Friction
- [ ] Bounciness
- [ ] Buoyancy
- [ ] Fake fluid (fluid in small comtainers like bottles, get water level)
- [ ] Soft body
- [ ] Fluid
- [ ] Portals
- [ ] Test on Windows
- [ ] Port to Emscripten

- [ ] VR Support
- [ ] Input System

SceneGraph (make a seperate project)
- [ ] States
- [ ] Scene Graph
- [ ] Map management
- [ ] XML based scene graph import
### Misc
- [ ] Events System
- [ ] Make an Actual Game
# Networking (make a seperate project)
- [ ] Networking
- [ ] VR Support
- [ ] Scene Graph
- [ ] XML based scene graph import
- [ ] Test ON Windows
- [ ] Port to Emscripten
# Platforms
- [ ] Test on Windows
- [ ] Port to Emscripten
6 changes: 3 additions & 3 deletions dep/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ find_package(glm REQUIRED)
include_directories(${GLM_INCLUDE_DIRS})
message(NOTICE "GLM_INCLUDE_DIRS " ${GLM_INCLUDE_DIRS})

# ASIMP
# ASSIMP
find_package(assimp REQUIRED)
message(NOTICE "ASSIMP_LIBRARY " ${OPENGL_LIBRARY})
message(NOTICE "ASSIMP_LIBRARIES " ${OPENGL_LIBRARIES})
Expand All @@ -54,12 +54,12 @@ set(CE_LIBS
PARENT_SCOPE
)

#Include
# Include
set(CE_INCLUDES
${OPENGL_INCLUDE_DIR}
${GLEW_INCLUDE_DIRS}
${SDL2_INCLUDE_DIRS}
${GLM_INCLUDE_DIRS}
${ASSIMP_INCLUDE_DIR}
PARENT_SCOPE
)
)
10 changes: 4 additions & 6 deletions engine/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -38,17 +38,15 @@ add_test(


set(LIBNAME ce_module)

add_library(${LIBNAME}
SHARED
"./ce_module_api.cpp"
SHARED
"./ce_module_api.cpp"
)

target_link_libraries(${LIBNAME}
${CE_LIBS}
)

include_directories(${LIBNAME}
${CMAKE_CURRENT_SOURCE_DIR}
${CE_INCLUDES}
)

)
28 changes: 16 additions & 12 deletions engine/ce_assets.h
Original file line number Diff line number Diff line change
@@ -1,41 +1,45 @@
#pragma once

#include <string>
#include <ce_math.h>

#include "rendering/vertex.h"
#include <string>
#include <vector>

namespace ce {
struct File {
std::string name = "";
};
struct ShaderFile :public File {
struct ShaderFile : public File {
std::string
vertName = "",
geomName = "",
fragName = "",
vertex = "",
fragment = "",
geometry = "";
geometry = "",
fragment = "";
};
struct TextureFile :public File {
struct TextureFile : public File {
unsigned char* data = NULL;
int
width = 0,
height = 0,
channelCount = 0;
};
struct MaterialFile :public File {
struct MaterialFile : public File {
glm::vec4
ambient = glm::vec4(0.0f),
diffuse = glm::vec4(0.0f),
speclular = glm::vec4(0.0f);
std::string
diffuseTex = "missing.png",
specularTex = "missing.png",
shader = "";
shader = NULL;
};
struct MeshFile:public File {
std::vector<Vertex> vertices;
std::vector<unsigned> indices;
std::vector<const char*> textures;

struct MeshFile : public File {
std::vector<Vertex> vertices;
std::vector<unsigned> indices;
std::vector<const char*> textures;
};
}
2 changes: 1 addition & 1 deletion engine/ce_module_api.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
*
*/

#include "core/module.h"
#include "core/module.h"
17 changes: 7 additions & 10 deletions engine/core/module.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,17 @@
* API FOR CREATING MODULES FOR CINNABAR ENGINE
*/

#ifndef _CE_MODULE_H_
#define _CE_MODULE_H_
#pragma once

namespace ce {
class Module {
private:
public:
virtual void tick(float deltaTime)=0;
private:
public:
virtual void tick(float deltaTime) = 0;
};

typedef Module* init_module_t();
typedef void delete_module_t(Module*);

}
#define CE_MODULE(X) extern "C" ce::Module* init_module() { return new X;} extern "C" void delete_module(ce::Module* m) { delete m;}

#endif //_CE_MODULE_H_
#define CE_MODULE(X) \
extern "C" ce::Module* init_module() { return new X; } \
extern "C" void delete_module(ce::Module* m) { delete m; }
1 change: 1 addition & 0 deletions engine/core/tpnt_log.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
*/
#pragma once

#include <iostream>
#include <cstring>
#include <stdio.h>
#include <string>
Expand Down
Loading

0 comments on commit 73a5bdc

Please sign in to comment.