better yet, also probably should do more in the ini I guess.
This commit is contained in:
@@ -11,6 +11,6 @@ Pos=588,54
|
||||
Size=550,680
|
||||
|
||||
[Window][Gradient settings]
|
||||
Pos=295,174
|
||||
Size=411,192
|
||||
Pos=173,209
|
||||
Size=721,170
|
||||
|
||||
|
||||
35
makefile
Normal file
35
makefile
Normal file
@@ -0,0 +1,35 @@
|
||||
# Compiler and flags
|
||||
CXX := g++
|
||||
CXXFLAGS := -std=c++23 -O3 -march=native -I./imgui
|
||||
LDFLAGS := -L./imgui -limgui -lstb -lGL
|
||||
PKG_FLAGS := $(shell pkg-config --cflags --libs glfw3)
|
||||
|
||||
# Directories
|
||||
BIN_DIR := ./bin
|
||||
SRC_DIR := ./tests
|
||||
|
||||
# Source files
|
||||
SRC := $(SRC_DIR)/g2chromatic2.cpp
|
||||
TARGET := $(BIN_DIR)/g2gradc
|
||||
|
||||
# Default target
|
||||
all: $(TARGET)
|
||||
|
||||
# Create binary directory if it doesn't exist
|
||||
$(BIN_DIR):
|
||||
@mkdir -p $(BIN_DIR)
|
||||
|
||||
# Build target
|
||||
$(TARGET): $(SRC) | $(BIN_DIR)
|
||||
$(CXX) $(CXXFLAGS) -o $@ $< $(LDFLAGS) $(PKG_FLAGS)
|
||||
|
||||
# Run the program
|
||||
run: $(TARGET)
|
||||
./$(TARGET)
|
||||
|
||||
# Clean build artifacts
|
||||
clean:
|
||||
rm -rf $(BIN_DIR)
|
||||
|
||||
# Phony targets
|
||||
.PHONY: all run clean
|
||||
@@ -316,7 +316,7 @@ int main() {
|
||||
ImGui::SliderInt("framecount", &i3, 10, 5000);
|
||||
ImGui::SliderInt("numSeeds", &i4, 0, 10);
|
||||
|
||||
if (ImGui::Button("Button")) // Buttons return true when clicked (most widgets return true when edited/activated)
|
||||
if (ImGui::Button("Generate Animation")) // Buttons return true when clicked (most widgets return true when edited/activated)
|
||||
mainLogic(f,i1,i2,i3,i4);
|
||||
ImGui::SameLine();
|
||||
|
||||
@@ -328,9 +328,9 @@ int main() {
|
||||
ImGui::Render();
|
||||
int display_w, display_h;
|
||||
glfwGetFramebufferSize(window, &display_w, &display_h);
|
||||
//glViewport(0, 0, display_w, display_h);
|
||||
//glClearColor(clear_color.x * clear_color.w, clear_color.y * clear_color.w, clear_color.z * clear_color.w, clear_color.w);
|
||||
//glClear(GL_COLOR_BUFFER_BIT);
|
||||
glViewport(0, 0, display_w, display_h);
|
||||
glClearColor(clear_color.x * clear_color.w, clear_color.y * clear_color.w, clear_color.z * clear_color.w, clear_color.w);
|
||||
glClear(GL_COLOR_BUFFER_BIT);
|
||||
ImGui_ImplOpenGL3_RenderDrawData(ImGui::GetDrawData());
|
||||
|
||||
glfwSwapBuffers(window);
|
||||
|
||||
Reference in New Issue
Block a user