cleaned more stuff
This commit is contained in:
@@ -6,16 +6,24 @@
|
||||
*/
|
||||
|
||||
#include "scenetest.h"
|
||||
#include "scene/scenetree.h"
|
||||
#include "scene/node.h"
|
||||
#include "display/camera.h"
|
||||
#include "display/display.h"
|
||||
|
||||
ecsid_t sceneTestAdd(void) {
|
||||
ecsid_t id = ecsEntityAdd();
|
||||
|
||||
// Initialize the entity with a camera component
|
||||
ecsid_t camera = ecsEntityAdd();
|
||||
sceneTreeChildAdd(id, camera);
|
||||
nodeChildAdd(id, camera);
|
||||
camera_t *camData = cameraAdd(camera);
|
||||
camData->type = CAMERA_TYPE_ORTHOGRAPHIC;
|
||||
camData->orthographic.left = 0.0f;
|
||||
camData->orthographic.right = 1.0f;
|
||||
camData->orthographic.top = 0.0f;
|
||||
camData->orthographic.bottom = 1.0f;
|
||||
camData->nearClip = -1.0f;
|
||||
camData->farClip = 1.0f;
|
||||
|
||||
// Optionally, you can set other properties or components here
|
||||
|
||||
|
Reference in New Issue
Block a user