Open zmac74 opened 2 years ago
This week I started to implement the scene heirarchy along with a importer system, It is now able to load basic model data, but is still not done I still need to get material data and lights and stuff. I implenmented part of the scene system with the basic structure I think by the end of next week i should be fully done with this and I will be able to pass my scene to my render engine to render it
I continued working on my scene and made a good structure for evrything. So I know where everything is in scene so I can later do frustum culling for optimization and I perfected the node structure which holds all kind of data like meshes, lights, camers, etc... Later it should be easy for me to implement 3d animation due to this good node system. I finally loaded everything in the scene such as lights , cameras and all the data in, only thing that I did not import yet is materials, textures, and bones for animation which I plan to do later.
This week was a more difficult one. I made a shader system which is code that runs on gpu, then compiled at runtime and used for rendering and within the shader, I can color the mesh based on its data, like texture coordinated, normals, vertex colors. So I am happy with this change and now everthying is ready to render a mesh
and this is a screenshot of the small demo I made running at pretty good fps using my engine (Ignite).
So now I want to spend the rest of 2021 just optimizing code and improvements. This means I wont be adding many graphical features and stuff but its important for me to get this out of the way.
To-do list of 2021:
I want to finsh on all these things before 2022
So this week I worked on researching designes for a entity component system i almost done with coming up with the design also I am loading more material data, and indecies to optimize mesh data
So i have been doing things that I listed from last weeks update that my goal is to finsh before 2022
I started off the week by modelling a super high resolution mesh in blender and importing to Ignite to see the performnce. It has 1.4 million vertices and I got about 20 fps. I added some performance stats to the window, and a mode where I can view each triangle of a mesh. So from here what I want to do is make a micro polygon renderer, this may take months but i want to get started now. Unreal engine 5 is what inspired me to do this as they made a demo and had a scene with hundreds of billions of triangles in realtime, so I want to make my own but try to make it run faster. over the last week I thought of ways I can implement this and I have some good approaches to make this
I MADE A LOT OF PROGRESS, here are the major thangs I did:
-added a world grid -made a shader so I can light up objects -added a entire new CROSS PLATFORM window system -finally finished up input
This week I added a drop input this is when you drag and drop files onto the window, if the files are 3d models i =t will be loaded but im not done yet , also i started getting sone gui ready but im not done wih that either. Next week i will try getting some gui to render!
So I made a lot of progress, first I finally added a editor so some gui at the bottom there is a area where I show performace stats such as fps, frame time in millisecons, screen resloution, vertices an triangles and more, then I added a viewport so now I only render what I can see and then I made it so that I can resize my window and and everthing scales to the window. I fixed up the camera and now only when I hold left click in the vieew port I move around in the scene.
This week I worked on backend stuff so nothing chged in the actual editor, I am redoing my importing system and my asset system. Currently I cant have multiple obkects in at once and if I wanted to I would have to change messy code so I am redoing some things.
Im still working on my asset system, but I have made A lot of progress in terms of loading textures. for example a material can have properties, but it also has textures with it. So now I can load textures such as normal maps, displacement maps, roughnes, specular and much more, I think there is about 15 to 20 different types of textures in my material system (this does not mean that a material will have all these textures it does not even need to have a texture). I worked on also loading indices mor meshes which help remove overlapping vertices saving a lot of vram
Sorry I forgot to do the weekly issues, but there is a lot I have been working on and I will say the summary. So first of all right now I am making a new shader loading system. A shader a seperate file that in a langauge called glsl and runs on the gpu, so I wanted to make my own shader language where I would make a file and type code the way I want and it will be parsed and compiled and sent to gpu at runtime. still working on this but I am almost done. btw shaders are a asset and in ingite I name them sources, and I have worked on many other sources including a scene. the scene contains a registry to all the entites which have components that I made and these components can use sources that are in the source registry. So thats the design I am going with and I managed to make a entity compionent system as well. so ya thats a summary and with the shader system that I am making, I will be able to make a really really cool feature that will be in the editor
This week I continued working on my shader loader. So a shader will be a source and it is a seperate file with code in it which is written in the langauge glsl. What I did is made some modifications so that the syntax for writing shaders is improved,
VERTEX: layout(location = 0) in vec3 iPosition;
void main()
{
}
FRAGMENT: in vec4 color; in vec3 worldSpace;
This is how a shader file looks like it is simular to glsl but the difference is that all code (stages) are in 1 file. at the moment I am working on a system where you can add a library of functions and call them with a shader witjout the need to include them and the parser will find the function call, search the library directery for for the function implementation and paste that in the stage then compile the code and send it to gpu. I am almost done and afterwards I plan to add a system where I can free mamory from sources when the engine terminates to avoid memory leaks.
I just fixed some bugs worked on fixed the entity component system and reworked the way i pass meshes to gpu. Now there is a element buffer that is read from the model file and is sent to the gpu. This will make it so that the gpu does need overlapping vertices and can improve vram memory by up to 50%. All of this data gets freed at freed when the enigne terminates
I just fixed some bugs and started to rework my main.cpp to make it cleaner.
This week I started off by finishing my framebuffer and making sure it connects to opengl my graphics api I am using. Afterwards I got started with a system that uploads mesh data to gpu (not done). I also justr planned out how I am going to design my scene because it will be like a heirarcy holding many objects, so i should implement this next week along with a model file loader to read model files and store them in the scene data structure. but ya that is what i basicaly worked on this week