3D Scene initial
This commit is contained in:
parent
3fd3211f46
commit
55f5537a67
8 changed files with 117 additions and 77 deletions
|
|
@ -1,42 +1,13 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include "Buffer2D.hpp"
|
||||
#include "Camera.hpp"
|
||||
#include "Scene.hpp"
|
||||
#include "Color.hpp"
|
||||
#include "Module.hpp"
|
||||
#include "Topology.hpp"
|
||||
#include "Vec.hpp"
|
||||
|
||||
namespace tp {
|
||||
|
||||
extern ModuleManifest gModuleRayTracer;
|
||||
|
||||
class Object {
|
||||
public:
|
||||
Object() = default;
|
||||
|
||||
public:
|
||||
Topology mTopology;
|
||||
TopologyCache mCache;
|
||||
};
|
||||
|
||||
struct PointLight {
|
||||
Vec3F pos;
|
||||
halnf fallOut = 1.f;
|
||||
halnf intensity = 1.f;
|
||||
};
|
||||
|
||||
class Scene {
|
||||
public:
|
||||
Scene() = default;
|
||||
|
||||
public:
|
||||
Buffer<Object> mObjects;
|
||||
Buffer<PointLight> mLights;
|
||||
Camera mCamera;
|
||||
};
|
||||
|
||||
class RayTracer {
|
||||
public:
|
||||
typedef Buffer2D<RGBA> RenderBuffer;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue