Compare commits
8 Commits
cmake-upda
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| f613b5a97f | |||
| 90728defd6 | |||
|
|
ed1bf4a9b1 | ||
|
|
3ceecb69f9 | ||
|
|
7259b8efb5 | ||
| 65cb29a65a | |||
| 08ded96060 | |||
| ce97b7454a |
151
.idea/workspace.xml
generated
Normal file
151
.idea/workspace.xml
generated
Normal file
@ -0,0 +1,151 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="AutoImportSettings">
|
||||
<option name="autoReloadType" value="SELECTIVE" />
|
||||
</component>
|
||||
<component name="BackendCodeEditorMiscSettings">
|
||||
<option name="/Default/RiderDebugger/RiderRestoreDecompile/RestoreDecompileSetting/@EntryValue" value="false" type="bool" />
|
||||
<option name="/Default/Housekeeping/GlobalSettingsUpgraded/IsUpgraded/@EntryValue" value="true" type="bool" />
|
||||
<option name="/Default/Housekeeping/FeatureSuggestion/FeatureSuggestionManager/DisabledSuggesters/=SwitchToGoToActionSuggester/@EntryIndexedValue" value="true" type="bool" />
|
||||
</component>
|
||||
<component name="CMakePresetLoader">{
|
||||
"useNewFormat": true
|
||||
}</component>
|
||||
<component name="CMakeProjectFlavorService">
|
||||
<option name="flavorId" value="CMakePlainProjectFlavor" />
|
||||
</component>
|
||||
<component name="CMakeReloadState">
|
||||
<option name="reloaded" value="true" />
|
||||
</component>
|
||||
<component name="CMakeRunConfigurationManager">
|
||||
<generated>
|
||||
<config projectName="Prog3B" targetName="Prog3B" />
|
||||
</generated>
|
||||
</component>
|
||||
<component name="CMakeSettings">
|
||||
<configurations>
|
||||
<configuration PROFILE_NAME="Debug" ENABLED="true" CONFIG_NAME="Debug" />
|
||||
</configurations>
|
||||
</component>
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="bc14ea44-6152-4afc-90d0-07644981c8ca" name="Changes" comment="otto">
|
||||
<change afterPath="$PROJECT_DIR$/.gitignore" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/CMakeLists.txt" beforeDir="false" afterPath="$PROJECT_DIR$/CMakeLists.txt" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/gamecube.cpp" beforeDir="false" afterPath="$PROJECT_DIR$/src/gamecube.cpp" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/gamecube.h" beforeDir="false" afterPath="$PROJECT_DIR$/includes/gamecube.h" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/gamematrix.h" beforeDir="false" afterPath="$PROJECT_DIR$/includes/gamematrix.h" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/main.cpp" beforeDir="false" afterPath="$PROJECT_DIR$/src/main.cpp" afterDir="false" />
|
||||
</list>
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
||||
<option name="LAST_RESOLUTION" value="IGNORE" />
|
||||
</component>
|
||||
<component name="ClangdSettings">
|
||||
<option name="formatViaClangd" value="false" />
|
||||
</component>
|
||||
<component name="ExecutionTargetManager" SELECTED_TARGET="CMakeBuildProfile:Debug" />
|
||||
<component name="Git.Settings">
|
||||
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
|
||||
</component>
|
||||
<component name="ProjectApplicationVersion">
|
||||
<option name="ide" value="CLion" />
|
||||
<option name="majorVersion" value="2024" />
|
||||
<option name="minorVersion" value="3.5" />
|
||||
<option name="productBranch" value="Classic" />
|
||||
</component>
|
||||
<component name="ProjectColorInfo">{
|
||||
"associatedIndex": 4
|
||||
}</component>
|
||||
<component name="ProjectId" id="34ehK54dp6OU0qNeW3IKWIrbM5O" />
|
||||
<component name="ProjectViewState">
|
||||
<option name="hideEmptyMiddlePackages" value="true" />
|
||||
<option name="showLibraryContents" value="true" />
|
||||
</component>
|
||||
<component name="PropertiesComponent"><![CDATA[{
|
||||
"keyToString": {
|
||||
"CMake Application.Prog3B.executor": "Run",
|
||||
"RunOnceActivity.RadMigrateCodeStyle": "true",
|
||||
"RunOnceActivity.ShowReadmeOnStart": "true",
|
||||
"RunOnceActivity.cidr.known.project.marker": "true",
|
||||
"RunOnceActivity.git.unshallow": "true",
|
||||
"RunOnceActivity.readMode.enableVisualFormatting": "true",
|
||||
"RunOnceActivity.west.config.association.type.startup.service": "true",
|
||||
"SHARE_PROJECT_CONFIGURATION_FILES": "true",
|
||||
"cf.first.check.clang-format": "false",
|
||||
"cidr.known.project.marker": "true",
|
||||
"git-widget-placeholder": "Merging master",
|
||||
"last_opened_file_path": "/Users/bendit.str/Desktop/CLION/PROG_3B",
|
||||
"node.js.detected.package.eslint": "true",
|
||||
"node.js.detected.package.tslint": "true",
|
||||
"node.js.selected.package.eslint": "(autodetect)",
|
||||
"node.js.selected.package.tslint": "(autodetect)",
|
||||
"nodejs_package_manager_path": "npm",
|
||||
"vue.rearranger.settings.migration": "true"
|
||||
}
|
||||
}]]></component>
|
||||
<component name="RunManager">
|
||||
<configuration default="true" type="CLionExternalRunConfiguration" factoryName="Application" REDIRECT_INPUT="false" ELEVATE="false" USE_EXTERNAL_CONSOLE="false" EMULATE_TERMINAL="false" PASS_PARENT_ENVS_2="true">
|
||||
<method v="2">
|
||||
<option name="CLION.EXTERNAL.BUILD" enabled="true" />
|
||||
</method>
|
||||
</configuration>
|
||||
<configuration name="Prog3B" type="CMakeRunConfiguration" factoryName="Application" REDIRECT_INPUT="false" ELEVATE="false" USE_EXTERNAL_CONSOLE="false" EMULATE_TERMINAL="false" PASS_PARENT_ENVS_2="true" PROJECT_NAME="Prog3B" TARGET_NAME="Prog3B" CONFIG_NAME="Debug" RUN_TARGET_PROJECT_NAME="Prog3B" RUN_TARGET_NAME="Prog3B">
|
||||
<method v="2">
|
||||
<option name="com.jetbrains.cidr.execution.CidrBuildBeforeRunTaskProvider$BuildBeforeRunTask" enabled="true" />
|
||||
</method>
|
||||
</configuration>
|
||||
</component>
|
||||
<component name="SpellCheckerSettings" RuntimeDictionaries="0" Folders="0" CustomDictionaries="0" DefaultDictionary="application-level" UseSingleDictionary="true" transferred="true" />
|
||||
<component name="TaskManager">
|
||||
<task active="true" id="Default" summary="Default task">
|
||||
<changelist id="bc14ea44-6152-4afc-90d0-07644981c8ca" name="Changes" comment="" />
|
||||
<created>1761579877481</created>
|
||||
<option name="number" value="Default" />
|
||||
<option name="presentableId" value="Default" />
|
||||
<updated>1761579877481</updated>
|
||||
<workItem from="1761579878668" duration="1151000" />
|
||||
<workItem from="1761659218955" duration="52000" />
|
||||
<workItem from="1762719029166" duration="1000" />
|
||||
</task>
|
||||
<task id="LOCAL-00001" summary="otto">
|
||||
<option name="closed" value="true" />
|
||||
<created>1761580147769</created>
|
||||
<option name="number" value="00001" />
|
||||
<option name="presentableId" value="LOCAL-00001" />
|
||||
<option name="project" value="LOCAL" />
|
||||
<updated>1761580147769</updated>
|
||||
</task>
|
||||
<task id="LOCAL-00002" summary="otto">
|
||||
<option name="closed" value="true" />
|
||||
<created>1761580176311</created>
|
||||
<option name="number" value="00002" />
|
||||
<option name="presentableId" value="LOCAL-00002" />
|
||||
<option name="project" value="LOCAL" />
|
||||
<updated>1761580176311</updated>
|
||||
</task>
|
||||
<task id="LOCAL-00003" summary="otto">
|
||||
<option name="closed" value="true" />
|
||||
<created>1762787735213</created>
|
||||
<option name="number" value="00003" />
|
||||
<option name="presentableId" value="LOCAL-00003" />
|
||||
<option name="project" value="LOCAL" />
|
||||
<updated>1762787735214</updated>
|
||||
</task>
|
||||
<option name="localTasksCounter" value="4" />
|
||||
<servers />
|
||||
</component>
|
||||
<component name="TypeScriptGeneratedFilesManager">
|
||||
<option name="version" value="3" />
|
||||
</component>
|
||||
<component name="VCPKGProject">
|
||||
<isAutomaticCheckingOnLaunch value="false" />
|
||||
<isAutomaticFoundErrors value="true" />
|
||||
<isAutomaticReloadCMake value="true" />
|
||||
</component>
|
||||
<component name="VcsManagerConfiguration">
|
||||
<MESSAGE value="otto" />
|
||||
<option name="LAST_COMMIT_MESSAGE" value="otto" />
|
||||
</component>
|
||||
</project>
|
||||
74
docs/design.txt
Normal file
74
docs/design.txt
Normal file
@ -0,0 +1,74 @@
|
||||
========================================================
|
||||
Projekt: gamematrix (C++ Library)
|
||||
Rolle: Architekt
|
||||
Datei: design.txt
|
||||
Datum: ____________________
|
||||
Team: ____________________
|
||||
========================================================
|
||||
|
||||
# ----------------------------
|
||||
# 1. Projektstruktur / Namespace
|
||||
# ----------------------------
|
||||
Namespace: _______________________________________________
|
||||
|
||||
Ziel: Saubere Trennung der Bibliothek, Vermeidung von Namenskonflikten.
|
||||
|
||||
Beispiel:
|
||||
namespace Matrix3D {
|
||||
// Funktionen, ggf Klasse(n)
|
||||
}
|
||||
|
||||
# ----------------------------
|
||||
# 2. Datenstrukturen / Klassen
|
||||
# ----------------------------
|
||||
Listen Sie die Klassen oder Structs auf, die verwendet werden:
|
||||
|
||||
| Name | Typ | Beschreibung |
|
||||
|--------|------------------------------------------|--------------|
|
||||
| Vec3 | struct Vec3 | 3D-Vektor (x, y, z) |
|
||||
| Mat4 | std::array<std::array<double,4>,4> | 4x4-Matrix (homogen) |
|
||||
| ______ | ________ | ___________________ |
|
||||
| ______ | ________ | ___________________ |
|
||||
|
||||
# ----------------------------
|
||||
# 3. Operatoren / Templates
|
||||
# ----------------------------
|
||||
Welche Operatoren oder Templates sollen definiert werden?
|
||||
|
||||
- Templates für unterschiedliche Datentypen? ☐ Ja ☐ Nein
|
||||
- Operatoren:
|
||||
- Mat4 * Mat4
|
||||
- Mat4 * Vec3
|
||||
|
||||
# ----------------------------
|
||||
# 4. Funktionen / Schnittstellen
|
||||
# ----------------------------
|
||||
Liste der Funktionen mit Eingabe/Ausgabe und kurzer Beschreibung:
|
||||
|
||||
| Funktion | Eingabe | Ausgabe | Kurzbeschreibung |
|
||||
|---------------|------------------------------------|-----------------------|----------------------------------------|
|
||||
| matmul | Mat4 A, Mat4 B | Mat4 | Matrixmultiplikation 4x4 |
|
||||
| translate | Vec3 pos | Mat4 | Verschiebungstransformation |
|
||||
| rot3D | double angle_deg, char axis | Mat4 | Rotation um Achse x/y/z |
|
||||
| identity (optional)| --- | Mat4 | Identitätsmatrix |
|
||||
| _____________ | __________________________________ | ____________________ | ______________________________ |
|
||||
|
||||
# ----------------------------
|
||||
# 5. Designentscheidungen / Hinweise
|
||||
# ----------------------------
|
||||
- Rückgabe der Matrizen per Wert oder Referenz? ___________
|
||||
- Verwendung von std::array oder std::vector? ___________
|
||||
- Homogene Koordinaten für Translation / Rotation (4x4)? ☐ Ja ☐ Nein
|
||||
- Weitere Designüberlegungen: ___________________________
|
||||
|
||||
# ----------------------------
|
||||
# 6. Deliverables / Milestones
|
||||
# ----------------------------
|
||||
- design.txt fertig und im Branch architect committed
|
||||
- Übergabe an Entwickler für Implementierung
|
||||
|
||||
========================================================
|
||||
Hinweis:
|
||||
- Dieses Dokument dient als Grundlage für die Implementierung.
|
||||
- Alle Designentscheidungen sollen klar nachvollziehbar sein.
|
||||
========================================================
|
||||
@ -3,7 +3,7 @@
|
||||
#include "raylib.h"
|
||||
#include "rlgl.h"
|
||||
|
||||
struct Vec3
|
||||
struct Vec3 //anisch unnötig weil rylib schon vec3 hat
|
||||
{
|
||||
float x, y, z;
|
||||
};
|
||||
@ -22,7 +22,7 @@ public:
|
||||
Vec3 GetPosition() const;
|
||||
float GetRotationY() const;
|
||||
Color GetColor() const { return color; }
|
||||
|
||||
//zustände klarer abbikden bzw weniger bools = klarare Logik
|
||||
private:
|
||||
Vec3 position;
|
||||
Color color;
|
||||
@ -32,3 +32,4 @@ private:
|
||||
bool flippingBackward = false;
|
||||
float rotation = 0.0f;
|
||||
};
|
||||
// braucht bessere trennung von logik & darstellung
|
||||
1708
includes/raylib.h
Normal file
1708
includes/raylib.h
Normal file
File diff suppressed because it is too large
Load Diff
@ -1,4 +1,4 @@
|
||||
#include "../../prog_3/includes/gamecube.h"
|
||||
#include "gamecube.h"
|
||||
#include <algorithm>
|
||||
#include <ctime>
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user