Need to fix grid thing
This commit is contained in:
parent
1f7fceb9b5
commit
4dfd637972
3
.vscode/settings.json
vendored
3
.vscode/settings.json
vendored
@ -73,6 +73,7 @@
|
||||
"typeinfo": "cpp",
|
||||
"valarray": "cpp",
|
||||
"variant": "cpp",
|
||||
"fstream": "cpp"
|
||||
"fstream": "cpp",
|
||||
"codecvt": "cpp"
|
||||
}
|
||||
}
|
27
build.log
27
build.log
@ -1,27 +1,14 @@
|
||||
[COMPILE] g++ -std=c++20 -Wall -Isrc/include -Isrc/vendor -Isrc/vendor/imgui -IC:/msys64/mingw64/include -MMD -MP -c src\src\Engine.cpp -o src\build\src\Engine.osrc\src\Engine.cpp:24:9: warning: "NOMINMAX" redefined
|
||||
24 | #define NOMINMAX
|
||||
| ^~~~~~~~
|
||||
In file included from C:/msys64/mingw64/include/c++/14.2.0/x86_64-w64-mingw32/bits/c++config.h:680,
|
||||
from C:/msys64/mingw64/include/c++/14.2.0/bits/memoryfwd.h:48,
|
||||
from C:/msys64/mingw64/include/c++/14.2.0/memory:63,
|
||||
from src\src\Engine.h:2,
|
||||
from src\src\Engine.cpp:1:
|
||||
C:/msys64/mingw64/include/c++/14.2.0/x86_64-w64-mingw32/bits/os_defines.h:45:9: note: this is the location of the previous definition
|
||||
45 | #define NOMINMAX 1
|
||||
| ^~~~~~~~
|
||||
In file included from C:/msys64/mingw64/include/yaml-cpp/parser.h:13,
|
||||
[COMPILE] g++ -std=c++20 -Wall -Isrc/include -Isrc/vendor -Isrc/vendor/imgui -IC:/msys64/mingw64/include -MMD -MP -c src\src\Renderer.cpp -o src\build\src\Renderer.oIn file included from C:/msys64/mingw64/include/yaml-cpp/parser.h:13,
|
||||
from C:/msys64/mingw64/include/yaml-cpp/yaml.h:10,
|
||||
from src\src\Entitys/Object.h:7,
|
||||
from src\src\Engine.cpp:2:
|
||||
from src\src\Components/Component.h:5,
|
||||
from src\src\Components/SpriteComponent.h:3,
|
||||
from src\src\Renderer.cpp:2:
|
||||
C:/msys64/mingw64/include/yaml-cpp/dll.h:22:65: note: '#pragma message: Defining YAML_CPP_API for DLL import'
|
||||
22 | # pragma message( "Defining YAML_CPP_API for DLL import" )
|
||||
| ^
|
||||
src\src\Engine.cpp:35:13: warning: 'isDragging' defined but not used [-Wunused-variable]
|
||||
35 | static bool isDragging = false;
|
||||
| ^~~~~~~~~~
|
||||
|
||||
[LINK] g++ src\build\src\Engine.o src\build\src\main.o src\build\src\Renderer.o src\build\src\Components\CameraComponent.o src\build\src\Components\SpriteComponent.o src\build\src\Entitys\Object.o src\build\src\utils\FileDialog.o src\build\src\utils\Shader.o src\build\vendor\imgui\imgui.o src\build\vendor\imgui\imgui_demo.o src\build\vendor\imgui\imgui_draw.o src\build\vendor\imgui\imgui_impl_glfw.o src\build\vendor\imgui\imgui_impl_opengl3.o src\build\vendor\imgui\imgui_tables.o src\build\vendor\imgui\imgui_widgets.o -o src\build\app.exe -LC:/msys64/mingw64/lib -lglfw3 -lglew32 -lopengl32 -lgdi32 -lyaml-cpp -lcomdlg32 -lssl -lcrypto
|
||||
|
||||
[TIME] Build duration: 6.12s
|
||||
[RUN] Executed app.exe successfully.
|
||||
[TIME] Total runtime: 72.36s
|
||||
[TIME] Build duration: 2.75s
|
||||
[ERROR] Runtime crash
|
||||
Command 'src\build\app.exe' returned non-zero exit status 1.
|
||||
|
17
imgui.ini
17
imgui.ini
@ -10,29 +10,34 @@ Collapsed=1
|
||||
|
||||
[Window][WindowOverViewport_11111111]
|
||||
Pos=0,19
|
||||
Size=1920,1158
|
||||
Size=1280,701
|
||||
Collapsed=0
|
||||
|
||||
[Window][Inspector]
|
||||
Pos=1513,19
|
||||
Size=407,1158
|
||||
Pos=873,19
|
||||
Size=407,701
|
||||
Collapsed=0
|
||||
DockId=0x00000004,0
|
||||
|
||||
[Window][Scene Tree]
|
||||
Pos=0,19
|
||||
Size=263,1158
|
||||
Size=263,701
|
||||
Collapsed=0
|
||||
DockId=0x00000001,0
|
||||
|
||||
[Window][Viewport]
|
||||
Pos=265,19
|
||||
Size=1246,1158
|
||||
Size=606,701
|
||||
Collapsed=0
|
||||
DockId=0x00000002,0
|
||||
|
||||
[Window][##MainMenuBar]
|
||||
Pos=0,0
|
||||
Size=1280,19
|
||||
Collapsed=0
|
||||
|
||||
[Docking][Data]
|
||||
DockSpace ID=0x11111111 Window=0x1BBC0F80 Pos=0,19 Size=1920,1158 Split=X
|
||||
DockSpace ID=0x11111111 Window=0x1BBC0F80 Pos=0,19 Size=1280,701 Split=X
|
||||
DockNode ID=0x00000003 Parent=0x11111111 SizeRef=1511,1158 Split=X
|
||||
DockNode ID=0x00000001 Parent=0x00000003 SizeRef=263,701 HiddenTabBar=1 Selected=0x12EF0F59
|
||||
DockNode ID=0x00000002 Parent=0x00000003 SizeRef=1246,701 CentralNode=1 Selected=0xC450F867
|
||||
|
@ -274,6 +274,9 @@ void Engine::Run()
|
||||
|
||||
std::vector<std::shared_ptr<Object>> toDraw;
|
||||
|
||||
Renderer::DrawEditorGrid(cameraPos, cameraZoom);
|
||||
|
||||
|
||||
std::function<void(const std::shared_ptr<Object> &)> collect = [&](const std::shared_ptr<Object> &obj)
|
||||
{
|
||||
toDraw.push_back(obj);
|
||||
|
@ -107,6 +107,9 @@ void Renderer::End() {
|
||||
// glEnd();
|
||||
//}
|
||||
|
||||
|
||||
|
||||
|
||||
void Renderer::DrawSprite(SpriteComponent* sprite, const glm::vec2& pos, float zoom, glm::vec2& CameraPos) {
|
||||
if (!sprite || sprite->GetTextureID() == 0) return;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user