瀏覽代碼

rename more stuff

Kolja Strohm 1 周之前
父節點
當前提交
8e3dbbae8e
共有 35 個文件被更改,包括 482 次插入480 次删除
  1. 24 24
      Animation.cpp
  2. 4 4
      Animation.h
  3. 14 14
      Border.cpp
  4. 1 1
      Border.h
  5. 23 23
      Camera2D.cpp
  6. 2 2
      Camera2D.h
  7. 3 3
      DX11GraphicsApi.cpp
  8. 1 1
      DX12GraphicsApi.cpp
  9. 9 9
      Drawing3D.cpp
  10. 9 9
      Drawing3D.h
  11. 74 74
      Font.cpp
  12. 2 2
      Font.h
  13. 3 3
      Image.cpp
  14. 4 4
      M2DPreview.cpp
  15. 11 11
      M2File.cpp
  16. 2 2
      M3File.cpp
  17. 138 138
      Model2D.cpp
  18. 31 29
      Model2D.h
  19. 7 7
      Model3D.cpp
  20. 2 2
      Model3D.h
  21. 2 2
      Point.cpp
  22. 21 21
      RenderThread.cpp
  23. 7 7
      RenderThread.h
  24. 1 1
      Screen.cpp
  25. 1 1
      Screen.h
  26. 4 4
      TextField.cpp
  27. 16 16
      Texture2D.cpp
  28. 2 2
      Texture2D.h
  29. 28 28
      TriangleList.h
  30. 1 1
      Vec2.h
  31. 3 3
      Vec3.h
  32. 3 3
      VecN.h
  33. 18 18
      World2D.cpp
  34. 9 9
      World2D.h
  35. 2 2
      World3D.cpp

+ 24 - 24
Animation.cpp

@@ -1,9 +1,9 @@
 #include "Animation.h"
 
-#include "Image.h"
+#include "Border.h"
 #include "FileSystem.h"
+#include "Image.h"
 #include "InitFile.h"
-#include "Border.h"
 #include "Text.h"
 #include "ToolTip.h"
 
@@ -16,7 +16,7 @@ Animation2DData::Animation2DData()
       bilder(0),
       imageCount(0),
       fps(0),
-      wiederhohlen(0),
+      repeat(0),
       transparent(0)
 {}
 
@@ -48,10 +48,10 @@ void Animation2DData::loadAnimation(InitFile* datei)
         --anz;
         fps = TextZuInt(datei->zValue("fps")->getText(), 10);
     }
-    if (datei->valueExists("wiederhohlen"))
+    if (datei->valueExists("repeat"))
     {
         --anz;
-        wiederhohlen = datei->zValue("wiederhohlen")->isEqual("true");
+        repeat = datei->zValue("repeat")->isEqual("true");
     }
     if (datei->valueExists("transparent"))
     {
@@ -64,7 +64,7 @@ void Animation2DData::loadAnimation(InitFile* datei)
     {
         bilder[j] = 0;
         if (datei->zName(i)->isEqual("fps")
-            || datei->zName(i)->isEqual("wiederhohlen")
+            || datei->zName(i)->isEqual("repeat")
             || datei->zName(i)->isEqual("transparent"))
             continue;
         Text pfad = datei->zValue(i)->getText();
@@ -133,7 +133,7 @@ void Animation2DData::setFPS(int fps)
 
 void Animation2DData::setWiederhohlend(bool wh)
 {
-    wiederhohlen = wh;
+    repeat = wh;
 }
 
 void Animation2DData::setTransparent(bool trp)
@@ -150,7 +150,7 @@ void Animation2DData::reset()
     bilder = 0;
     imageCount = 0;
     fps = 30;
-    wiederhohlen = 0;
+    repeat = 0;
     transparent = 0;
     unlock();
 }
@@ -180,7 +180,7 @@ int Animation2DData::getFPS() const
 
 bool Animation2DData::isRepeating() const
 {
-    return wiederhohlen;
+    return repeat;
 }
 
 bool Animation2DData::isTransparent() const
@@ -193,8 +193,8 @@ bool Animation2DData::isTransparent() const
 Animation2D::Animation2D()
     : Drawable(),
       data(0),
-      jetzt(0),
-      ausgleich(0),
+      now(0),
+      compensation(0),
       alpha(0),
       maxAlpha(255),
       border(0),
@@ -284,23 +284,23 @@ bool Animation2D::tick(double zeit)
             alpha = (unsigned char)(alpha - aps * zeit);
         rend = 1;
     }
-    ausgleich += zeit;
-    int tmp = jetzt;
+    compensation += zeit;
+    int tmp = now;
     data->lock();
-    if (ausgleich >= 1.0 / data->getFPS())
+    if (compensation >= 1.0 / data->getFPS())
     {
-        ausgleich -= 1.0 / data->getFPS();
-        ++jetzt;
-        if (jetzt >= data->getImageCount())
+        compensation -= 1.0 / data->getFPS();
+        ++now;
+        if (now >= data->getImageCount())
         {
             if (data->isRepeating())
-                jetzt = 0;
+                now = 0;
             else
-                jetzt = data->getImageCount();
+                now = data->getImageCount();
         }
     }
     data->unlock();
-    if (tmp != jetzt) rend = 1;
+    if (tmp != now) rend = 1;
     unlockDrawable();
     return Drawable::tick(zeit);
 }
@@ -315,13 +315,13 @@ void Animation2D::render(Image& zRObj)
     }
     Drawable::render(zRObj);
     data->lock();
-    if (data->zImage(jetzt))
+    if (data->zImage(now))
     {
         zRObj.setAlpha(alpha);
         if (data->isTransparent())
-            zRObj.alphaImage(pos.x, pos.y, gr.x, gr.y, *data->zImage(jetzt));
+            zRObj.alphaImage(pos.x, pos.y, gr.x, gr.y, *data->zImage(now));
         else
-            zRObj.drawImage(pos.x, pos.y, gr.x, gr.y, *data->zImage(jetzt));
+            zRObj.drawImage(pos.x, pos.y, gr.x, gr.y, *data->zImage(now));
         if (ram && border)
         {
             ram->setPosition(pos);
@@ -352,7 +352,7 @@ bool Animation2D::isVisible() const
 
 int Animation2D::getJetzt() const
 {
-    return jetzt;
+    return now;
 }
 
 unsigned char Animation2D::getAlphaMaske() const

+ 4 - 4
Animation.h

@@ -18,7 +18,7 @@ namespace Framework
         Image** bilder;
         int imageCount;
         int fps;
-        bool wiederhohlen;
+        bool repeat;
         bool transparent;
         Critical cs;
 
@@ -36,7 +36,7 @@ namespace Framework
         //! first one has called unlock().
         DLLEXPORT void unlock();
         //! Loads all images from an InitFile. The values 'fps',
-        //! 'wiederhohlen' (true, false), 'transparent' (true, false) are also
+        //! 'repeat' (true, false), 'transparent' (true, false) are also
         //! interpreted. The images must be in the correct order in the file.
         //! The name of the values does not matter, the value is the path to
         //! the ltdb file with /imagename appended. Example: fps=30
@@ -82,8 +82,8 @@ namespace Framework
     {
     private:
         Animation2DData* data;
-        int jetzt;
-        double ausgleich;
+        int now;
+        double compensation;
         unsigned char alpha;
         unsigned char maxAlpha;
         bool border;

+ 14 - 14
Border.cpp

@@ -12,7 +12,7 @@ using namespace Framework;
 // Constructor
 Border::Border()
     : Drawable(),
-      br(1),
+      thickness(1),
       color(0xFF000000),
       alpha(0),
       breaks(0)
@@ -24,7 +24,7 @@ Border::~Border() {}
 // non-constant
 void Border::setBorderWidth(int br) // sets the width of the border
 {
-    this->br = br;
+    this->thickness = br;
     rend = 1;
 }
 
@@ -65,7 +65,7 @@ bool Border::hasAlpha()
 
 int Border::getRWidth() const // Returns the width of the border
 {
-    return br;
+    return thickness;
 }
 
 // Returns 1 if the border is drawn dashed
@@ -113,7 +113,7 @@ void LBorder::render(Image& Obj) // Draws the border into the render object
     {
         if (alpha)
         {
-            for (int i = 0; i < br; ++i)
+            for (int i = 0; i < thickness; ++i)
             {
                 Obj.drawLineHAlpha(x + i + 1, y + i, gr.x - i * 2 - 1, color);
                 Obj.drawLineVAlpha(b - i, y + i + 1, gr.y - i * 2 - 2, color);
@@ -123,7 +123,7 @@ void LBorder::render(Image& Obj) // Draws the border into the render object
         }
         else
         {
-            for (int i = 0; i < br; ++i)
+            for (int i = 0; i < thickness; ++i)
             {
                 Obj.drawLineH(x + i + 1, y + i, gr.x - i * 2 - 1, color);
                 Obj.drawLineV(b - i, y + i + 1, gr.y - i * 2 - 2, color);
@@ -136,7 +136,7 @@ void LBorder::render(Image& Obj) // Draws the border into the render object
     {
         if (alpha)
         {
-            for (int i = 0; i < br; ++i)
+            for (int i = 0; i < thickness; ++i)
             {
                 for (int x = breakOffset; x < gr.x;
                     x += lineLength + breakLength)
@@ -173,7 +173,7 @@ void LBorder::render(Image& Obj) // Draws the border into the render object
         }
         else
         {
-            for (int i = 0; i < br; ++i)
+            for (int i = 0; i < thickness; ++i)
             {
                 for (int x = breakOffset; x < gr.x;
                     x += lineLength + breakLength)
@@ -225,7 +225,7 @@ Drawable* LBorder::duplicate() const // Copies the drawing
     obj->setBreaks(breaks);
     obj->setAlpha(alpha);
     obj->setColor(color);
-    obj->setBorderWidth(br);
+    obj->setBorderWidth(thickness);
     return obj;
 }
 
@@ -236,7 +236,7 @@ Border3D::Border3D()
 {
     alpha = 1;
     color = 0x70FFFFFF;
-    br = 5;
+    thickness = 5;
 }
 
 // Destructor
@@ -255,7 +255,7 @@ void Border3D::render(Image& Obj) // Draws the border into the render object
     {
         if (alpha)
         {
-            for (int i = 0; i < br; ++i)
+            for (int i = 0; i < thickness; ++i)
             {
                 Obj.drawLineHAlpha(x + i + 1, y + i, gr.x - i * 2 - 1, color);
                 Obj.drawLineVAlpha(b - i, y + i + 1, gr.y - i * 2 - 2, color);
@@ -265,7 +265,7 @@ void Border3D::render(Image& Obj) // Draws the border into the render object
         }
         else
         {
-            for (int i = 0; i < br; ++i)
+            for (int i = 0; i < thickness; ++i)
             {
                 Obj.drawLineH(x + i + 1, y + i, gr.x - i * 2 - 1, color);
                 Obj.drawLineV(b - i, y + i + 1, gr.y - i * 2 - 2, color);
@@ -278,7 +278,7 @@ void Border3D::render(Image& Obj) // Draws the border into the render object
     {
         if (alpha)
         {
-            for (int i = 0; i < br; ++i)
+            for (int i = 0; i < thickness; ++i)
             {
                 for (int x = breakOffset; x < gr.x;
                     x += lineLength + breakLength)
@@ -315,7 +315,7 @@ void Border3D::render(Image& Obj) // Draws the border into the render object
         }
         else
         {
-            for (int i = 0; i < br; ++i)
+            for (int i = 0; i < thickness; ++i)
             {
                 for (int x = breakOffset; x < gr.x;
                     x += lineLength + breakLength)
@@ -367,6 +367,6 @@ Drawable* Border3D::duplicate() const // Copies the drawing
     obj->setBreaks(breaks);
     obj->setAlpha(alpha);
     obj->setColor(color);
-    obj->setBorderWidth(br);
+    obj->setBorderWidth(thickness);
     return obj;
 }

+ 1 - 1
Border.h

@@ -10,7 +10,7 @@ namespace Framework
     class Border : public Drawable
     {
     protected:
-        int br;
+        int thickness;
         int color;
         bool alpha;
         bool breaks;

+ 23 - 23
Camera2D.cpp

@@ -10,7 +10,7 @@ Camera2D::Camera2D()
     : DrawableBackground()
 {
     setStyle(Style::Visible);
-    welt = 0;
+    world = 0;
     rotation = 0;
     matrix = Mat3<float>::identity();
     zoom = 1;
@@ -20,7 +20,7 @@ Camera2D::Camera2D()
 
 Camera2D::~Camera2D()
 {
-    if (welt) welt->release();
+    if (world) world->release();
     name->release();
 }
 
@@ -40,14 +40,14 @@ void Camera2D::lookAtWorldPos(float x, float y)
     rend |= wPos != Vertex(x, y);
     wPos.x = x;
     wPos.y = y;
-    if (welt && welt->getWorldInfo().hasSize && welt->getWorldInfo().circular)
+    if (world && world->getWorldInfo().hasSize && world->getWorldInfo().circular)
     {
-        if (wPos.x < 0) wPos.x += (float)welt->getWorldInfo().size.x;
-        if (wPos.y < 0) wPos.y += (float)welt->getWorldInfo().size.y;
-        if (wPos.x > (float)welt->getWorldInfo().size.x)
-            wPos.x -= (float)welt->getWorldInfo().size.x;
-        if (wPos.y > (float)welt->getWorldInfo().size.y)
-            wPos.y -= (float)welt->getWorldInfo().size.y;
+        if (wPos.x < 0) wPos.x += (float)world->getWorldInfo().size.x;
+        if (wPos.y < 0) wPos.y += (float)world->getWorldInfo().size.y;
+        if (wPos.x > (float)world->getWorldInfo().size.x)
+            wPos.x -= (float)world->getWorldInfo().size.x;
+        if (wPos.y > (float)world->getWorldInfo().size.y)
+            wPos.y -= (float)world->getWorldInfo().size.y;
     }
 }
 
@@ -62,7 +62,7 @@ void Camera2D::lookAtWorldArea(float width, float height)
     // TODO have two scaling factors
 }
 
-void Camera2D::setDrehung(float rotation)
+void Camera2D::setRotation(float rotation)
 {
     rend |= this->rotation != rotation;
     this->rotation = rotation;
@@ -76,15 +76,15 @@ void Camera2D::setZoom(float zoom)
 
 void Camera2D::setWorld(World2D* welt, bool tick)
 {
-    if (this->welt) this->welt->release();
-    this->welt = welt;
+    if (this->world) this->world->release();
+    this->world = welt;
     tickWorld = tick;
     rend = 1;
 }
 
 bool Camera2D::tick(double time)
 {
-    if (welt && tickWorld) rend |= welt->tick(time);
+    if (world && tickWorld) rend |= world->tick(time);
     return DrawableBackground::tick(time);
 }
 
@@ -92,7 +92,7 @@ void Camera2D::render(Image& zRObj)
 {
     if (hasStyleNot(Style::Visible)) return;
     DrawableBackground::render(zRObj);
-    if (!welt) return;
+    if (!world) return;
     lockDrawable();
     if (!zRObj.setDrawOptions(innenPosition, innenSize))
     {
@@ -102,7 +102,7 @@ void Camera2D::render(Image& zRObj)
     matrix = Mat3<float>::translation((Vertex)gr / 2)
            * Mat3<float>::rotation(rotation) * Mat3<float>::scaling(zoom)
            * Mat3<float>::translation(-wPos);
-    welt->render(matrix, gr, zRObj, *name);
+    world->render(matrix, gr, zRObj, *name);
     zRObj.releaseDrawOptions();
     unlockDrawable();
 }
@@ -114,17 +114,17 @@ Vertex Camera2D::getWorldCoordinates(Point screenPos)
               * Mat3<float>::rotation(-rotation)
               * Mat3<float>::translation((Vertex)gr / -2))
         * (Vertex)screenPos;
-    if (welt->getWorldInfo().circular && welt->getWorldInfo().hasSize
-        && welt->getWorldInfo().size.x && welt->getWorldInfo().size.y)
+    if (world->getWorldInfo().circular && world->getWorldInfo().hasSize
+        && world->getWorldInfo().size.x && world->getWorldInfo().size.y)
     {
         while (wKoord.x < 0)
-            wKoord.x += (float)welt->getWorldInfo().size.x;
-        while (wKoord.x > (float)welt->getWorldInfo().size.x)
-            wKoord.x -= (float)welt->getWorldInfo().size.x;
+            wKoord.x += (float)world->getWorldInfo().size.x;
+        while (wKoord.x > (float)world->getWorldInfo().size.x)
+            wKoord.x -= (float)world->getWorldInfo().size.x;
         while (wKoord.y < 0)
-            wKoord.y += (float)welt->getWorldInfo().size.y;
-        while (wKoord.y > (float)welt->getWorldInfo().size.y)
-            wKoord.y -= (float)welt->getWorldInfo().size.y;
+            wKoord.y += (float)world->getWorldInfo().size.y;
+        while (wKoord.y > (float)world->getWorldInfo().size.y)
+            wKoord.y -= (float)world->getWorldInfo().size.y;
     }
     return wKoord;
 }

+ 2 - 2
Camera2D.h

@@ -12,7 +12,7 @@ namespace Framework
     class Camera2D : public DrawableBackground
     {
     protected:
-        World2D* welt;
+        World2D* world;
         bool tickWorld;
         Vertex wPos;
         float rotation;
@@ -28,7 +28,7 @@ namespace Framework
         __declspec(dllexport) void lookAtWorldPos(Vertex pos);
         __declspec(dllexport) void lookAtWorldPos(float x, float y);
         __declspec(dllexport) void lookAtWorldArea(float width, float height);
-        __declspec(dllexport) void setDrehung(float rotation);
+        __declspec(dllexport) void setRotation(float rotation);
         __declspec(dllexport) void setZoom(float zoom);
         __declspec(dllexport) void setWorld(World2D* welt, bool tick);
         __declspec(dllexport) bool tick(double time);

+ 3 - 3
DX11GraphicsApi.cpp

@@ -774,7 +774,7 @@ bool DirectX11::isInFrustrum(
     {
         if (frustrum[i] * pos + radius < 0) return 0;
     }
-    if (dist) *dist = kamPos.abstand(pos);
+    if (dist) *dist = kamPos.distance(pos);
     return 1;
 }
 
@@ -786,7 +786,7 @@ bool DirectX11::isInFrustrum(
         float r = abs(frustrum[i].normal() * radius);
         if (frustrum[i] * pos + r < 0) return 0;
     }
-    if (dist) *dist = kamPos.abstand(pos);
+    if (dist) *dist = kamPos.distance(pos);
     return 1;
 }
 
@@ -870,7 +870,7 @@ void DirectX11::renderKamera(Cam3D* zKamera)
         for (auto obj : alphaModels)
         {
             float dist;
-            dist = kamPos.abstand(obj->getPos());
+            dist = kamPos.distance(obj->getPos());
             if (isInFrustrum(obj->getPos(), obj->getRadius(), &dist))
             {
                 int pos = (int)dist - minDist;

+ 1 - 1
DX12GraphicsApi.cpp

@@ -1097,7 +1097,7 @@ bool DirectX12::isInFrustrum(
     {
         if (frustrum[i] * pos + radius < 0) return 0;
     }
-    if (dist) *dist = kamPos.abstand(pos);
+    if (dist) *dist = kamPos.distance(pos);
     return 1;
 }
 

+ 9 - 9
Drawing3D.cpp

@@ -65,7 +65,7 @@ void Drawable3D::setZ(float z)
 
 // Sets the rotation of the drawing in the world
 //  d: The rotation around the x, y and z axis
-void Drawable3D::setDrehung(const Vec3<float>& d)
+void Drawable3D::setRotation(const Vec3<float>& d)
 {
     angle = d;
     rend = 1;
@@ -75,7 +75,7 @@ void Drawable3D::setDrehung(const Vec3<float>& d)
 //  xWinkel: The rotation around the x axis
 //  yWinkel: The rotation around the y axis
 //  zWinkel: The rotation around the z axis
-void Drawable3D::setDrehung(float xWinkel, float yWinkel, float zWinkel)
+void Drawable3D::setRotation(float xWinkel, float yWinkel, float zWinkel)
 {
     angle.x = xWinkel;
     angle.y = yWinkel;
@@ -85,7 +85,7 @@ void Drawable3D::setDrehung(float xWinkel, float yWinkel, float zWinkel)
 
 // Sets the rotation of the drawing in the world
 //  winkel: The rotation around the x axis
-void Drawable3D::setDrehungX(float winkel)
+void Drawable3D::setRotationX(float winkel)
 {
     angle.x = winkel;
     rend = 1;
@@ -93,7 +93,7 @@ void Drawable3D::setDrehungX(float winkel)
 
 // Sets the rotation of the drawing in the world
 //  winkel: The rotation around the y axis
-void Drawable3D::setDrehungY(float winkel)
+void Drawable3D::setRotationY(float winkel)
 {
     angle.y = winkel;
     rend = 1;
@@ -101,7 +101,7 @@ void Drawable3D::setDrehungY(float winkel)
 
 // Sets the rotation of the drawing in the world
 //  winkel: The rotation around the z axis
-void Drawable3D::setDrehungZ(float winkel)
+void Drawable3D::setRotationZ(float winkel)
 {
     angle.z = winkel;
     rend = 1;
@@ -196,25 +196,25 @@ float Drawable3D::getZ() const
 
 // Returns a vector representing the rotation of the drawing in the world.
 // x is the rotation around the X axis in radians, etc.
-const Vec3<float>& Drawable3D::getDrehung() const
+const Vec3<float>& Drawable3D::getRotation() const
 {
     return angle;
 }
 
 // Returns the rotation around the X axis in radians
-float Drawable3D::getXDrehung() const
+float Drawable3D::getXRotation() const
 {
     return angle.x;
 }
 
 // Returns the rotation around the Y axis in radians
-float Drawable3D::getYDrehung() const
+float Drawable3D::getYRotation() const
 {
     return angle.y;
 }
 
 // Returns the rotation around the Z axis in radians
-float Drawable3D::getZDrehung() const
+float Drawable3D::getZRotation() const
 {
     return angle.z;
 }

+ 9 - 9
Drawing3D.h

@@ -45,21 +45,21 @@ namespace Framework
         DLLEXPORT void setZ(float z);
         //! Sets the rotation of the drawing in the world
         //! \param d The rotation around the x, y and z axes
-        DLLEXPORT void setDrehung(const Vec3<float>& d);
+        DLLEXPORT void setRotation(const Vec3<float>& d);
         //! Sets the rotation of the drawing in the world
         //! \param xWinkel The rotation around the x axis
         //! \param yWinkel The rotation around the y axis
         //! \param zWinkel The rotation around the z axis
-        DLLEXPORT void setDrehung(float xWinkel, float yWinkel, float zWinkel);
+        DLLEXPORT void setRotation(float xWinkel, float yWinkel, float zWinkel);
         //! Sets the rotation of the drawing in the world
         //! \param winkel The rotation around the x axis
-        DLLEXPORT void setDrehungX(float winkel);
+        DLLEXPORT void setRotationX(float winkel);
         //! Sets the rotation of the drawing in the world
         //! \param winkel The rotation around the y axis
-        DLLEXPORT void setDrehungY(float winkel);
+        DLLEXPORT void setRotationY(float winkel);
         //! Sets the rotation of the drawing in the world
         //! \param winkel The rotation around the z axis
-        DLLEXPORT void setDrehungZ(float winkel);
+        DLLEXPORT void setRotationZ(float winkel);
         //! Sets whether the object contains partially or fully transparent
         //! areas \param a true if partially or fully transparent areas exist
         DLLEXPORT void setAlpha(bool a);
@@ -95,13 +95,13 @@ namespace Framework
         DLLEXPORT float getZ() const;
         //! Returns a vector representing the rotation of the drawing in the world.
         //! x is the rotation around the X axis in radians, etc.
-        DLLEXPORT const Vec3<float>& getDrehung() const;
+        DLLEXPORT const Vec3<float>& getRotation() const;
         //! Returns the rotation around the X axis in radians
-        DLLEXPORT float getXDrehung() const;
+        DLLEXPORT float getXRotation() const;
         //! Returns the rotation around the Y axis in radians
-        DLLEXPORT float getYDrehung() const;
+        DLLEXPORT float getYRotation() const;
         //! Returns the rotation around the Z axis in radians
-        DLLEXPORT float getZDrehung() const;
+        DLLEXPORT float getZRotation() const;
         //! Returns the matrix that translates the drawing into world space
         DLLEXPORT const Mat4<float>& getMatrix() const;
         //! Calculates a point in world coordinates from a point in local drawing

+ 74 - 74
Font.cpp

@@ -290,8 +290,8 @@ TextRenderer::TextRenderer(Font* font)
     : ReferenceCounter()
 {
     s = font;
-    zeilenAbstand = 5;
-    zeichenAbstand = 0;
+    lineSpacing = 5;
+    charSpacing = 0;
     fontSize = 0;
     setFontSize(12);
 }
@@ -392,14 +392,14 @@ void TextRenderer::setFontSize(int sg)
 //  za: The line spacing to the bottom of the line above in pixels
 void TextRenderer::setLineSpacing(int za)
 {
-    zeilenAbstand = za;
+    lineSpacing = za;
 }
 
 // Sets the character spacing to use for drawing
 //  za: The character spacing in pixels
 void TextRenderer::setCharSpacing(int za)
 {
-    zeichenAbstand = za;
+    charSpacing = za;
 }
 
 // Inserts line breaks into the text so it is fully displayed at a given width
@@ -417,13 +417,13 @@ void TextRenderer::formatText(Text* zTxt, int maxWidth)
         if (txt[i] == ' ')
         {
             lastPos = i;
-            x += fontSize / 2 + zeichenAbstand;
+            x += fontSize / 2 + charSpacing;
             continue;
         }
         if (txt[i] == '\t')
         {
             lastPos = i;
-            x += fontSize + zeichenAbstand;
+            x += fontSize + charSpacing;
             continue;
         }
         if (txt[i] == '\n')
@@ -432,7 +432,7 @@ void TextRenderer::formatText(Text* zTxt, int maxWidth)
             lastPos = -1;
             continue;
         }
-        x += getCharWidth(txt[i]) + zeichenAbstand;
+        x += getCharWidth(txt[i]) + charSpacing;
         if (x > maxWidth && lastPos > -1)
         {
             result.replace(lastPos, lastPos + 1, "\n");
@@ -473,7 +473,7 @@ void TextRenderer::renderText(int x,
     const Point& zRObjOff = zRObj.getDrawOff();
     int beginX = x;
     int zh = getRowHeight();
-    if (y + (zh + zeilenAbstand) * Text(txt).countOf('\n') + zh + zRObjOff.y
+    if (y + (zh + lineSpacing) * Text(txt).countOf('\n') + zh + zRObjOff.y
             < 0
         || x + zRObjOff.x >= zRObjBr || y + zRObjOff.y >= zRObjHi)
         return;
@@ -491,20 +491,20 @@ void TextRenderer::renderText(int x,
         {
             if (faerb)
                 zRObj.alphaRegion(
-                    x, y, fontSize / 2 + zeichenAbstand, zh, ff);
-            x += fontSize / 2 + zeichenAbstand;
+                    x, y, fontSize / 2 + charSpacing, zh, ff);
+            x += fontSize / 2 + charSpacing;
             continue;
         }
         if (txt[i] == '\t')
         {
             if (faerb)
-                zRObj.alphaRegion(x, y, fontSize + zeichenAbstand, zh, ff);
-            x += fontSize + zeichenAbstand;
+                zRObj.alphaRegion(x, y, fontSize + charSpacing, zh, ff);
+            x += fontSize + charSpacing;
             continue;
         }
         if (txt[i] == '\n')
         {
-            y += zh + zeilenAbstand;
+            y += zh + lineSpacing;
             x = beginX;
             continue;
         }
@@ -577,11 +577,11 @@ void TextRenderer::renderChar(int& x,
         {
             if (selected)
             {
-                int br = getCharWidth(c) + zeichenAbstand;
+                int br = getCharWidth(c) + charSpacing;
                 zRObj.alphaRegion(x,
                     y,
                     br,
-                    getRowHeight() + zeilenAbstand,
+                    getRowHeight() + lineSpacing,
                     selectedBackgroundColor);
             }
             if (b->getBuff())
@@ -636,44 +636,44 @@ void TextRenderer::renderChar(int& x,
                 }
             }
             if (underlined)
-                zRObj.drawLineHAlpha(x - (int)(zeichenAbstand / 2.0 + 0.5),
+                zRObj.drawLineHAlpha(x - (int)(charSpacing / 2.0 + 0.5),
                     y + getRowHeight() + getCharSpacing() / 2,
-                    getCharWidth(c) + (int)(zeichenAbstand / 2.0 + 0.5),
+                    getCharWidth(c) + (int)(charSpacing / 2.0 + 0.5),
                     0xFF000000 | color);
         }
-        x += getCharWidth(c) + zeichenAbstand;
+        x += getCharWidth(c) + charSpacing;
     }
     else if (c == ' ')
     {
         if (selected)
             zRObj.alphaRegion(x,
                 y,
-                fontSize / 2 + zeichenAbstand,
-                getRowHeight() + zeilenAbstand,
+                fontSize / 2 + charSpacing,
+                getRowHeight() + lineSpacing,
                 selectedBackgroundColor);
         if (underlined)
-            zRObj.drawLineHAlpha(x - (int)(zeichenAbstand / 2.0 + 0.5),
+            zRObj.drawLineHAlpha(x - (int)(charSpacing / 2.0 + 0.5),
                 y + getRowHeight() + getCharSpacing() / 2,
-                fontSize / 2 + zeichenAbstand
-                    + (int)(zeichenAbstand / 2.0 + 0.5),
+                fontSize / 2 + charSpacing
+                    + (int)(charSpacing / 2.0 + 0.5),
                 0xFF000000 | color);
-        x += fontSize / 2 + zeichenAbstand;
+        x += fontSize / 2 + charSpacing;
     }
     else if (c == '\t')
     {
         if (selected)
             zRObj.alphaRegion(x,
                 y,
-                fontSize + zeichenAbstand,
-                getRowHeight() + zeilenAbstand,
+                fontSize + charSpacing,
+                getRowHeight() + lineSpacing,
                 selectedBackgroundColor);
         if (underlined)
-            zRObj.drawLineHAlpha(x - (int)(zeichenAbstand / 2.0 + 0.5),
+            zRObj.drawLineHAlpha(x - (int)(charSpacing / 2.0 + 0.5),
                 y + getRowHeight() + getCharSpacing() / 2,
-                fontSize + zeichenAbstand
-                    + (int)(zeichenAbstand / 2.0 + 0.5),
+                fontSize + charSpacing
+                    + (int)(charSpacing / 2.0 + 0.5),
                 0xFF000000 | color);
-        x += fontSize + zeichenAbstand;
+        x += fontSize + charSpacing;
     }
 }
 
@@ -686,7 +686,7 @@ int TextRenderer::getFontSize() const
 // Returns the character spacing in pixels on the x axis
 int TextRenderer::getCharSpacing() const
 {
-    return zeichenAbstand;
+    return charSpacing;
 }
 
 // Determines how many pixels are needed to fully display a specific text
@@ -704,7 +704,7 @@ int TextRenderer::getTextWidth(const char* txt) const
             tmp = 0;
         }
         else
-            tmp += getCharWidth(txt[i]) + zeichenAbstand;
+            tmp += getCharWidth(txt[i]) + charSpacing;
     }
     if (tmp > ret) ret = tmp;
     return ret;
@@ -715,7 +715,7 @@ int TextRenderer::getTextWidth(const char* txt) const
 int TextRenderer::getTextHeight(const char* txt) const
 {
     int hi = getRowHeight();
-    return hi + ((hi + zeilenAbstand) * Text(txt).countOf('\n'));
+    return hi + ((hi + lineSpacing) * Text(txt).countOf('\n'));
 }
 
 // Determines how many pixels are needed to fully display a specific character
@@ -750,7 +750,7 @@ int TextRenderer::getCharHeight(const char c) const
 // Returns the line spacing in pixels to the bottom of the line above
 int TextRenderer::getLineSpacing() const
 {
-    return zeilenAbstand;
+    return lineSpacing;
 }
 
 // Returns the scaled height needed by a drawn line in pixels
@@ -781,26 +781,26 @@ int TextRenderer::textPos(const char* txt, int mouseX, int mouseY) const
     {
         if (txt[i] == '\n')
         {
-            ty += sh + zeilenAbstand;
+            ty += sh + lineSpacing;
             tx = 0;
             if (mouseY < ty) return i;
         }
         if (txt[i] == '\t')
         {
-            tx += fontSize + zeichenAbstand;
+            tx += fontSize + charSpacing;
         }
         else if (txt[i] == ' ')
         {
-            tx += fontSize / 2 + zeichenAbstand;
+            tx += fontSize / 2 + charSpacing;
         }
         else
         {
-            tx += getCharWidth(txt[i]) + zeichenAbstand;
+            tx += getCharWidth(txt[i]) + charSpacing;
         }
         int txpl = getCharWidth(txt[i]) / 2;
-        if (mouseX < tx - txpl && mouseY < ty + sh + zeilenAbstand) return i;
+        if (mouseX < tx - txpl && mouseY < ty + sh + lineSpacing) return i;
     }
-    if (mouseY < ty + sh + zeilenAbstand) return textLength(txt);
+    if (mouseY < ty + sh + lineSpacing) return textLength(txt);
     return -1;
 }
 
@@ -843,11 +843,11 @@ void EngravedTextRenderer::renderChar(int& x,
         {
             if (selected)
             {
-                int br = getCharWidth(c) + zeichenAbstand;
+                int br = getCharWidth(c) + charSpacing;
                 zRObj.alphaRegion(x,
                     y,
                     br,
-                    getRowHeight() + zeilenAbstand,
+                    getRowHeight() + lineSpacing,
                     selectedBackgroundColor);
             }
             if (b->getBuff())
@@ -937,44 +937,44 @@ void EngravedTextRenderer::renderChar(int& x,
                 }
             }
             if (underlined)
-                zRObj.drawLineHAlpha(x - (int)(zeichenAbstand / 2.0 + 0.5),
+                zRObj.drawLineHAlpha(x - (int)(charSpacing / 2.0 + 0.5),
                     y + getRowHeight() + getCharSpacing() / 2,
-                    getCharWidth(c) + (int)(zeichenAbstand / 2.0 + 0.5),
+                    getCharWidth(c) + (int)(charSpacing / 2.0 + 0.5),
                     0xFF000000 | color);
         }
-        x += getCharWidth(c) + zeichenAbstand;
+        x += getCharWidth(c) + charSpacing;
     }
     else if (c == ' ')
     {
         if (selected)
             zRObj.alphaRegion(x,
                 y,
-                fontSize / 2 + zeichenAbstand,
-                getRowHeight() + zeilenAbstand,
+                fontSize / 2 + charSpacing,
+                getRowHeight() + lineSpacing,
                 selectedBackgroundColor);
         if (underlined)
-            zRObj.drawLineHAlpha(x - (int)(zeichenAbstand / 2.0 + 0.5),
+            zRObj.drawLineHAlpha(x - (int)(charSpacing / 2.0 + 0.5),
                 y + getRowHeight() + getCharSpacing() / 2,
-                fontSize / 2 + zeichenAbstand
-                    + (int)(zeichenAbstand / 2.0 + 0.5),
+                fontSize / 2 + charSpacing
+                    + (int)(charSpacing / 2.0 + 0.5),
                 0xFF000000 | color);
-        x += fontSize / 2 + zeichenAbstand;
+        x += fontSize / 2 + charSpacing;
     }
     else if (c == '\t')
     {
         if (selected)
             zRObj.alphaRegion(x,
                 y,
-                fontSize + zeichenAbstand,
-                getRowHeight() + zeilenAbstand,
+                fontSize + charSpacing,
+                getRowHeight() + lineSpacing,
                 selectedBackgroundColor);
         if (underlined)
-            zRObj.drawLineHAlpha(x - (int)(zeichenAbstand / 2.0 + 0.5),
+            zRObj.drawLineHAlpha(x - (int)(charSpacing / 2.0 + 0.5),
                 y + getRowHeight() + getCharSpacing() / 2,
-                fontSize + zeichenAbstand
-                    + (int)(zeichenAbstand / 2.0 + 0.5),
+                fontSize + charSpacing
+                    + (int)(charSpacing / 2.0 + 0.5),
                 0xFF000000 | color);
-        x += fontSize + zeichenAbstand;
+        x += fontSize + charSpacing;
     }
 }
 
@@ -1037,11 +1037,11 @@ void ItalicTextRenderer::renderChar(int& x,
         {
             if (selected)
             {
-                int br = getCharWidth(c) + zeichenAbstand;
+                int br = getCharWidth(c) + charSpacing;
                 zRObj.alphaRegion(x,
                     y,
                     br,
-                    getRowHeight() + zeilenAbstand,
+                    getRowHeight() + lineSpacing,
                     selectedBackgroundColor);
             }
             if (b->getBuff())
@@ -1112,44 +1112,44 @@ void ItalicTextRenderer::renderChar(int& x,
                 }
             }
             if (underlined)
-                zRObj.drawLineHAlpha(x - (int)(zeichenAbstand / 2.0 + 0.5),
+                zRObj.drawLineHAlpha(x - (int)(charSpacing / 2.0 + 0.5),
                     y + getRowHeight() + getCharSpacing() / 2,
-                    getCharWidth(c) + (int)(zeichenAbstand / 2.0 + 0.5),
+                    getCharWidth(c) + (int)(charSpacing / 2.0 + 0.5),
                     0xFF000000 | color);
         }
-        x += getCharWidth(c) + zeichenAbstand;
+        x += getCharWidth(c) + charSpacing;
     }
     else if (c == ' ')
     {
         if (selected)
             zRObj.alphaRegion(x,
                 y,
-                fontSize / 2 + zeichenAbstand,
-                getRowHeight() + zeilenAbstand,
+                fontSize / 2 + charSpacing,
+                getRowHeight() + lineSpacing,
                 selectedBackgroundColor);
         if (underlined)
-            zRObj.drawLineHAlpha(x - (int)(zeichenAbstand / 2.0 + 0.5),
+            zRObj.drawLineHAlpha(x - (int)(charSpacing / 2.0 + 0.5),
                 y + getRowHeight() + getCharSpacing() / 2,
-                fontSize / 2 + zeichenAbstand
-                    + (int)(zeichenAbstand / 2.0 + 0.5),
+                fontSize / 2 + charSpacing
+                    + (int)(charSpacing / 2.0 + 0.5),
                 0xFF000000 | color);
-        x += fontSize / 2 + zeichenAbstand;
+        x += fontSize / 2 + charSpacing;
     }
     else if (c == '\t')
     {
         if (selected)
             zRObj.alphaRegion(x,
                 y,
-                fontSize + zeichenAbstand,
-                getRowHeight() + zeilenAbstand,
+                fontSize + charSpacing,
+                getRowHeight() + lineSpacing,
                 selectedBackgroundColor);
         if (underlined)
-            zRObj.drawLineHAlpha(x - (int)(zeichenAbstand / 2.0 + 0.5),
+            zRObj.drawLineHAlpha(x - (int)(charSpacing / 2.0 + 0.5),
                 y + getRowHeight() + getCharSpacing() / 2,
-                fontSize + zeichenAbstand
-                    + (int)(zeichenAbstand / 2.0 + 0.5),
+                fontSize + charSpacing
+                    + (int)(charSpacing / 2.0 + 0.5),
                 0xFF000000 | color);
-        x += fontSize + zeichenAbstand;
+        x += fontSize + charSpacing;
     }
 }
 

+ 2 - 2
Font.h

@@ -171,8 +171,8 @@ namespace Framework
     protected:
         Font* s;
         int fontSize;
-        int zeilenAbstand;
-        int zeichenAbstand;
+        int lineSpacing;
+        int charSpacing;
         int charWidths[256];
         int charHeights[256];
 

+ 3 - 3
Image.cpp

@@ -2727,11 +2727,11 @@ void Image::replaceColorWithAlpha(int color)
         for (int x = dx + xx; x < bb; x++)
         {
             unsigned char* cf = (unsigned char*)&(fc[x + ygr]);
-            int abstand = (int)sqrt(
+            int distance = (int)sqrt(
                 (float)((r - cf[2]) * (r - cf[2]) + (g - cf[1]) * (g - cf[1])
                         + (b - cf[0]) * (b - cf[0])));
-            if (abstand > 255) abstand = 255;
-            cf[3] = (unsigned char)(abstand);
+            if (distance > 255) distance = 255;
+            cf[3] = (unsigned char)(distance);
         }
     }
 }

+ 4 - 4
M2DPreview.cpp

@@ -53,13 +53,13 @@ void M2DPreview::doMouseEvent(MouseEvent& me, bool userRet)
             if (getMouseState(M_Right) && hasStyle(Style::UsrRot))
             {
                 if (me.mx > gr.x / 2)
-                    mdl->addDrehung(0.01f * (float)(me.my - my));
+                    mdl->addRotation(0.01f * (float)(me.my - my));
                 else
-                    mdl->addDrehung(-0.01f * (float)(me.my - my));
+                    mdl->addRotation(-0.01f * (float)(me.my - my));
                 if (me.my > gr.y / 2)
-                    mdl->addDrehung(-0.01f * (float)(me.mx - mx));
+                    mdl->addRotation(-0.01f * (float)(me.mx - mx));
                 else
-                    mdl->addDrehung(0.01f * (float)(me.mx - mx));
+                    mdl->addRotation(0.01f * (float)(me.mx - mx));
             }
             mx = me.mx;
             my = me.my;

+ 11 - 11
M2File.cpp

@@ -152,7 +152,7 @@ bool M2File::saveModel(Model2DData* zMdr, const char* name)
         for (int i = 0; i < vAnz; i++)
             options
                 = (char)(options
-                         & (char)zMdr->polygons->get(p).tKordinaten->has(i));
+                         & (char)zMdr->polygons->get(p).tCoordinates->has(i));
         if (pNameL != 0) options |= 2;
         if (zMdr->polygons->get(p).transparent) options |= 4;
         neu.write(&options, 1);
@@ -170,9 +170,9 @@ bool M2File::saveModel(Model2DData* zMdr, const char* name)
             neu.write((char*)&v, 4);
             if ((options | 1) == options) // textur
             {
-                float t = zMdr->polygons->get(p).tKordinaten->get(i).x;
+                float t = zMdr->polygons->get(p).tCoordinates->get(i).x;
                 neu.write((char*)&t, 4);
-                t = zMdr->polygons->get(p).tKordinaten->get(i).y;
+                t = zMdr->polygons->get(p).tCoordinates->get(i).y;
                 neu.write((char*)&t, 4);
             }
         }
@@ -309,7 +309,7 @@ Model2DData* M2File::loadModel(const char* name) const
         char options = 0;
         d.read(&options, 1);
         Polygon2D polygon;
-        polygon.schwerpunkt = new Vertex(0, 0);
+        polygon.center = new Vertex(0, 0);
         polygon.transparent = (options | 4) == options;
         polygon.name = new Text();
         if ((options | 2) == options)
@@ -327,34 +327,34 @@ Model2DData* M2File::loadModel(const char* name) const
         if (polygons->has(p))
         {
             if (polygons->get(p).vertex) polygons->get(p).vertex->release();
-            if (polygons->get(p).tKordinaten)
-                polygons->get(p).tKordinaten->release();
+            if (polygons->get(p).tCoordinates)
+                polygons->get(p).tCoordinates->release();
         }
         polygon.vertex = new Array<Vertex>();
         if ((options | 1) == options) // wenn textur
-            polygon.tKordinaten = new Array<Vertex>();
+            polygon.tCoordinates = new Array<Vertex>();
         else
-            polygon.tKordinaten = 0;
+            polygon.tCoordinates = 0;
         for (int v = 0; v < vAnz; v++)
         {
             Vertex p;
             d.read((char*)&p.x, 4);
             d.read((char*)&p.y, 4);
-            *polygon.schwerpunkt += p * (float)(1.0 / vAnz);
+            *polygon.center += p * (float)(1.0 / vAnz);
             polygon.vertex->add(p);
             if ((options | 1) == options) // wenn textur
             {
                 Vertex tp;
                 d.read((char*)&tp.x, 4);
                 d.read((char*)&tp.y, 4);
-                polygon.tKordinaten->add(tp);
+                polygon.tCoordinates->add(tp);
             }
         }
         polygons->add(polygon);
     }
     d.close();
     Model2DData* ret = new Model2DData();
-    ret->erstelleModell(polygons);
+    ret->createModell(polygons);
     return ret;
 }
 

+ 2 - 2
M3File.cpp

@@ -221,7 +221,7 @@ bool M3File::saveModel(Model3DData* zMdr, const char* name)
     neu.write((char*)&factor, 4);
     factor = zMdr->getSpecularFactor();
     neu.write((char*)&factor, 4);
-    Skeleton* skelet = zMdr->copySkelett();
+    Skeleton* skelet = zMdr->copySkeleton();
     if (skelet)
     {
         bool b = 1;
@@ -421,7 +421,7 @@ Model3DData* M3File::loadModel(
             d.read((char*)&nId, 4);
             s->nextId = nId;
             s->rootBone = readKnochen(&d);
-            model->setSkelettZ(s);
+            model->setSkeletonZ(s);
         }
         model->calculateNormals();
         d.close();

+ 138 - 138
Model2D.cpp

@@ -13,7 +13,7 @@ using namespace Framework;
 Model2DData::Model2DData()
     : ReferenceCounter(),
       polygons(0),
-      vListen(0),
+      vLists(0),
       minP(0, 0),
       maxP(0, 0)
 {}
@@ -27,15 +27,15 @@ Model2DData::~Model2DData()
         for (int i = 0; i < anz; i++)
         {
             if (polygons->get(i).name) polygons->get(i).name->release();
-            if (polygons->get(i).tKordinaten)
-                polygons->get(i).tKordinaten->release();
+            if (polygons->get(i).tCoordinates)
+                polygons->get(i).tCoordinates->release();
             if (polygons->get(i).vertex) polygons->get(i).vertex->release();
-            if (polygons->get(i).schwerpunkt)
-                delete polygons->get(i).schwerpunkt;
+            if (polygons->get(i).center)
+                delete polygons->get(i).center;
         }
         polygons = (Array<Polygon2D>*)polygons->release();
     }
-    if (vListen) vListen->release();
+    if (vLists) vLists->release();
 }
 
 // privat
@@ -138,28 +138,28 @@ bool Model2DData::isLineInside(Vertex a, Vertex b, int polygonId) const
 }
 
 // non-constant
-bool Model2DData::erstelleModell(Array<Polygon2D>* polygons)
+bool Model2DData::createModell(Array<Polygon2D>* polygons)
 {
     removeModell();
     if (!polygons || !polygons->getEntryCount())
     {
         this->polygons = polygons;
-        vListen = new RCArray<RCArray<TriangleList<Vertex>>>();
+        vLists = new RCArray<RCArray<TriangleList<Vertex>>>();
         return 1;
     }
     this->polygons = polygons;
     int pAnz = polygons->getEntryCount();
-    vListen = new RCArray<RCArray<TriangleList<Vertex>>>();
+    vLists = new RCArray<RCArray<TriangleList<Vertex>>>();
     for (int p = 0; p < pAnz; p++)
     {
         Polygon2D pg = polygons->get(p);
         if (!pg.vertex || pg.vertex->getEntryCount() < 3) continue;
-        vListen->add(new RCArray<TriangleList<Vertex>>());
+        vLists->add(new RCArray<TriangleList<Vertex>>());
         outList.add(new Array<Point>);
         int vAnz = pg.vertex->getEntryCount();
-        bool textur = pg.tKordinaten != 0;
+        bool textur = pg.tCoordinates != 0;
         for (int i = 0; i < vAnz && textur; i++)
-            textur &= pg.tKordinaten->has(i);
+            textur &= pg.tCoordinates->has(i);
         for (int i = 0; i < vAnz; i++)
         {
             if ((float)maxP.x < fabs(pg.vertex->get(i).x))
@@ -176,7 +176,7 @@ bool Model2DData::erstelleModell(Array<Polygon2D>* polygons)
         minP = -maxP;
         if (!textur)
         {
-            if (pg.tKordinaten) pg.tKordinaten->clear();
+            if (pg.tCoordinates) pg.tCoordinates->clear();
         }
         RCArray<RCArray<TriangleList<Vertex>>> lists;
         int lauf = 0;
@@ -226,9 +226,9 @@ bool Model2DData::erstelleModell(Array<Polygon2D>* polygons)
                     TriangleList<Vertex>* lowL = new TriangleList<Vertex>();
                     TriangleList<Vertex>* heightL = new TriangleList<Vertex>();
                     lowL->addPoint(new Vertex(pg.vertex->get(i)),
-                        textur ? new Vertex(pg.tKordinaten->get(i)) : 0);
+                        textur ? new Vertex(pg.tCoordinates->get(i)) : 0);
                     heightL->addPoint(new Vertex(pg.vertex->get(i)),
-                        textur ? new Vertex(pg.tKordinaten->get(i)) : 0);
+                        textur ? new Vertex(pg.tCoordinates->get(i)) : 0);
                     int height = i + 1;
                     int low = i - 1;
                     Point outL(0, 0);
@@ -265,12 +265,12 @@ bool Model2DData::erstelleModell(Array<Polygon2D>* polygons)
                                 if (!k)
                                     lowL->addPoint(new Vertex(b),
                                         textur ? new Vertex(
-                                                     pg.tKordinaten->get(low))
+                                                     pg.tCoordinates->get(low))
                                                : 0);
                                 else
                                     heightL->addPoint(new Vertex(b),
                                         textur ? new Vertex(
-                                                     pg.tKordinaten->get(low))
+                                                     pg.tCoordinates->get(low))
                                                : 0);
                                 break;
                             }
@@ -288,12 +288,12 @@ bool Model2DData::erstelleModell(Array<Polygon2D>* polygons)
                                 if (!k)
                                     lowL->addPoint(new Vertex(b),
                                         textur ? new Vertex(
-                                                     pg.tKordinaten->get(low))
+                                                     pg.tCoordinates->get(low))
                                                : 0);
                                 else
                                     heightL->addPoint(new Vertex(b),
                                         textur ? new Vertex(
-                                                     pg.tKordinaten->get(low))
+                                                     pg.tCoordinates->get(low))
                                                : 0);
                                 low--;
                             }
@@ -301,12 +301,12 @@ bool Model2DData::erstelleModell(Array<Polygon2D>* polygons)
                             {
                                 if (!k)
                                     lowL->addPoint(new Vertex(a),
-                                        textur ? new Vertex(pg.tKordinaten->get(
+                                        textur ? new Vertex(pg.tCoordinates->get(
                                                      height))
                                                : 0);
                                 else
                                     heightL->addPoint(new Vertex(a),
-                                        textur ? new Vertex(pg.tKordinaten->get(
+                                        textur ? new Vertex(pg.tCoordinates->get(
                                                      height))
                                                : 0);
                                 height++;
@@ -351,7 +351,7 @@ bool Model2DData::erstelleModell(Array<Polygon2D>* polygons)
                 }
             }
             if (!max || maxP < 0) break;
-            vListen->z(p)->add(lists.z(lauf)->get(maxP));
+            vLists->z(p)->add(lists.z(lauf)->get(maxP));
             outList.z(p)->set(tmpOutList.get(maxP), lauf);
             if (fertig) break;
             lauf++;
@@ -369,16 +369,16 @@ void Model2DData::removeModell() // resets the vertex data
         for (int i = 0; i < anz; i++)
         {
             if (polygons->get(i).name) polygons->get(i).name->release();
-            if (polygons->get(i).tKordinaten)
-                polygons->get(i).tKordinaten->release();
+            if (polygons->get(i).tCoordinates)
+                polygons->get(i).tCoordinates->release();
             if (polygons->get(i).vertex) polygons->get(i).vertex->release();
-            if (polygons->get(i).schwerpunkt)
-                delete polygons->get(i).schwerpunkt;
+            if (polygons->get(i).center)
+                delete polygons->get(i).center;
         }
         polygons = (Array<Polygon2D>*)polygons->release();
     }
-    if (vListen)
-        vListen = (RCArray<RCArray<TriangleList<Vertex>>>*)vListen->release();
+    if (vLists)
+        vLists = (RCArray<RCArray<TriangleList<Vertex>>>*)vLists->release();
     outList.clear();
     minP = Point(0, 0);
     maxP = Point(0, 0);
@@ -432,13 +432,13 @@ bool Model2DData::calcHitPoint(Vertex pos,
                         Vertex kNorm = Vertex(dir).normalize();
                         moveSpeed = normal * (normal * kNorm) * dir.getLength();
                         normal
-                            = (point - *polygon.schwerpunkt).CW90().normalize();
+                            = (point - *polygon.center).CW90().normalize();
                         Vertex rotKraft
                             = normal * (normal * kNorm) * dir.getLength();
                         rotSpeed
                             = ((float)sqrt(
                                    rotKraft.getLength()
-                                   * (point - *polygon.schwerpunkt).getLength())
+                                   * (point - *polygon.center).getLength())
                                   / 180.f)
                             * 3.14f * (normal * kNorm);
                         hitpoint = point;
@@ -488,8 +488,8 @@ bool Model2DData::split(Vertex pos,
                 if ((txtChpPix.x == 0 || txtChpPix.y == 0) && b.x != 0
                     && b.y != 0)
                 {
-                    Vertex ta = polygon.tKordinaten->get(i);
-                    Vertex tb = polygon.tKordinaten->get((i + 1) % anz);
+                    Vertex ta = polygon.tCoordinates->get(i);
+                    Vertex tb = polygon.tCoordinates->get((i + 1) % anz);
                     tb -= ta;
                     txtChpPix = Vertex(tb.x / b.x, tb.y / b.y);
                 }
@@ -512,9 +512,9 @@ bool Model2DData::split(Vertex pos,
                         leftI = i;
                         rightI = (i + 1) % anz;
                         startPoint = point;
-                        texturSP = polygon.tKordinaten->get(i)
-                                 + (polygon.tKordinaten->get((i + 1) % anz)
-                                       - polygon.tKordinaten->get(i))
+                        texturSP = polygon.tCoordinates->get(i)
+                                 + (polygon.tCoordinates->get((i + 1) % anz)
+                                       - polygon.tCoordinates->get(i))
                                        * offset;
                     }
                     ret = 1;
@@ -523,21 +523,21 @@ bool Model2DData::split(Vertex pos,
             if (ret)
             {
                 partA.transparent = polygon.transparent;
-                partA.schwerpunkt = new Vertex(0, 0);
-                partA.tKordinaten = new Array<Vertex>();
+                partA.center = new Vertex(0, 0);
+                partA.tCoordinates = new Array<Vertex>();
                 partA.name = new Text(polygon.name->getText());
                 partA.vertex = new Array<Vertex>();
                 partB.transparent = polygon.transparent;
-                partB.schwerpunkt = new Vertex(0, 0);
-                partB.tKordinaten = new Array<Vertex>();
+                partB.center = new Vertex(0, 0);
+                partB.tCoordinates = new Array<Vertex>();
                 partB.name = new Text(polygon.name->getText());
                 partB.vertex = new Array<Vertex>();
-                *partA.schwerpunkt += startPoint;
-                *partB.schwerpunkt += startPoint;
+                *partA.center += startPoint;
+                *partB.center += startPoint;
                 partA.vertex->add(startPoint);
                 partB.vertex->add(startPoint);
-                partA.tKordinaten->add(texturSP);
-                partB.tKordinaten->add(texturSP);
+                partA.tCoordinates->add(texturSP);
+                partB.tCoordinates->add(texturSP);
                 int leftIE = 0;
                 int rightIE = 0;
                 while (1)
@@ -596,9 +596,9 @@ bool Model2DData::split(Vertex pos,
                                 rightIE = (i + 1) % anz;
                                 startPoint = point;
                                 texturSP
-                                    = polygon.tKordinaten->get(i)
-                                    + (polygon.tKordinaten->get((i + 1) % anz)
-                                          - polygon.tKordinaten->get(i))
+                                    = polygon.tCoordinates->get(i)
+                                    + (polygon.tCoordinates->get((i + 1) % anz)
+                                          - polygon.tCoordinates->get(i))
                                           * offset1;
                             }
                             ret = 1;
@@ -612,63 +612,63 @@ bool Model2DData::split(Vertex pos,
                         leftIE = bestI;
                         rightIE = (bestI + 1) % anz;
                         startPoint = a + (b * bo1);
-                        texturSP = polygon.tKordinaten->get(bestI)
-                                 + (polygon.tKordinaten->get((bestI + 1) % anz)
-                                       - polygon.tKordinaten->get(bestI))
+                        texturSP = polygon.tCoordinates->get(bestI)
+                                 + (polygon.tCoordinates->get((bestI + 1) % anz)
+                                       - polygon.tCoordinates->get(bestI))
                                        * bo1;
                         ret = 1;
                     }
                     if (ret) break;
-                    *partA.schwerpunkt += next;
-                    *partB.schwerpunkt += next;
+                    *partA.center += next;
+                    *partB.center += next;
                     partA.vertex->add(next);
                     partB.vertex->add(next);
-                    partA.tKordinaten->add(nextT);
-                    partB.tKordinaten->add(nextT);
+                    partA.tCoordinates->add(nextT);
+                    partB.tCoordinates->add(nextT);
                     startPoint = next;
                     texturSP = nextT;
                     dir = originalDir.rotation((float)(random() - 0.5));
                 }
-                *partA.schwerpunkt += startPoint;
-                *partB.schwerpunkt += startPoint;
+                *partA.center += startPoint;
+                *partB.center += startPoint;
                 partA.vertex->add(startPoint);
                 partB.vertex->add(startPoint);
-                partA.tKordinaten->add(texturSP);
-                partB.tKordinaten->add(texturSP);
+                partA.tCoordinates->add(texturSP);
+                partB.tCoordinates->add(texturSP);
                 for (int i = rightIE; i != leftI; i++)
                 {
                     i = i % anz;
                     if (i == leftI) break;
-                    *partA.schwerpunkt += polygon.vertex->get(i);
+                    *partA.center += polygon.vertex->get(i);
                     partA.vertex->add(polygon.vertex->get(i));
-                    partA.tKordinaten->add(polygon.tKordinaten->get(i));
+                    partA.tCoordinates->add(polygon.tCoordinates->get(i));
                 }
-                *partA.schwerpunkt += polygon.vertex->get(leftI);
+                *partA.center += polygon.vertex->get(leftI);
                 partA.vertex->add(polygon.vertex->get(leftI));
-                partA.tKordinaten->add(polygon.tKordinaten->get(leftI));
+                partA.tCoordinates->add(polygon.tCoordinates->get(leftI));
                 for (int i = leftIE; i != rightI; i--)
                 {
                     if (i < 0) i += anz;
                     if (i == rightI) break;
-                    *partB.schwerpunkt += polygon.vertex->get(i);
+                    *partB.center += polygon.vertex->get(i);
                     partB.vertex->add(polygon.vertex->get(i));
-                    partB.tKordinaten->add(polygon.tKordinaten->get(i));
+                    partB.tCoordinates->add(polygon.tCoordinates->get(i));
                 }
-                *partB.schwerpunkt += polygon.vertex->get(rightI);
+                *partB.center += polygon.vertex->get(rightI);
                 partB.vertex->add(polygon.vertex->get(rightI));
-                partB.tKordinaten->add(polygon.tKordinaten->get(rightI));
-                *partA.schwerpunkt /= (float)partA.vertex->getEntryCount();
-                *partB.schwerpunkt /= (float)partB.vertex->getEntryCount();
-                posA = (Point)*partA.schwerpunkt;
-                posB = (Point)*partB.schwerpunkt;
+                partB.tCoordinates->add(polygon.tCoordinates->get(rightI));
+                *partA.center /= (float)partA.vertex->getEntryCount();
+                *partB.center /= (float)partB.vertex->getEntryCount();
+                posA = (Point)*partA.center;
+                posB = (Point)*partB.center;
                 for (int i = 0; i < partA.vertex->getEntryCount(); i++)
                     partA.vertex->set(
-                        partA.vertex->get(i) - *partA.schwerpunkt, i);
+                        partA.vertex->get(i) - *partA.center, i);
                 for (int i = 0; i < partB.vertex->getEntryCount(); i++)
                     partB.vertex->set(
-                        partB.vertex->get(i) - *partB.schwerpunkt, i);
-                *partA.schwerpunkt = Vertex(0, 0);
-                *partB.schwerpunkt = Vertex(0, 0);
+                        partB.vertex->get(i) - *partB.center, i);
+                *partA.center = Vertex(0, 0);
+                *partB.center = Vertex(0, 0);
             }
         }
         num++;
@@ -704,14 +704,14 @@ Model2DObject::Model2DObject()
     : Object2D()
 {
     rData = 0;
-    textur = new RCArray<Texture2D>();
+    texture = new RCArray<Texture2D>();
 }
 
 // Destructor
 Model2DObject::~Model2DObject()
 {
     if (rData) rData->release();
-    textur->release();
+    texture->release();
 }
 
 // non-constant
@@ -725,9 +725,9 @@ void Model2DObject::setTexture(Texture2D* t)
 {
     if (rData)
     {
-        textur->clear();
+        texture->clear();
         for (int i = 0; i < rData->polygons->getEntryCount(); i++)
-            textur->add(dynamic_cast<Texture2D*>(t->getThis()));
+            texture->add(dynamic_cast<Texture2D*>(t->getThis()));
     }
     t->release();
 }
@@ -776,7 +776,7 @@ void Model2DObject::setTexture(Texture2D* t, const char* polygonName)
     for (const Polygon2D& i : *rData->polygons)
     {
         if (i.name->isEqual(polygonName))
-            textur->set(dynamic_cast<Texture2D*>(t->getThis()), index);
+            texture->set(dynamic_cast<Texture2D*>(t->getThis()), index);
         index++;
     }
     t->release();
@@ -785,33 +785,33 @@ void Model2DObject::setTexture(Texture2D* t, const char* polygonName)
 void Model2DObject::render(
     Mat3<float>& kamMat, Image& zRObj, const char* kamName)
 {
-    if (!rData || !rData->polygons || !textur) return;
+    if (!rData || !rData->polygons || !texture) return;
     int num = 0;
-    for (auto p : *rData->vListen)
+    for (auto p : *rData->vLists)
     {
         Mat3<float> mat = kamMat * getObjectMatrix();
-        if (textur->has(num))
+        if (texture->has(num))
         {
-            Image* txt = textur->z(num)->zTexture();
+            Image* txt = texture->z(num)->zTexture();
             for (auto i = p->begin(); i && txt; i++)
             {
                 for (auto j = i->zListe()->begin();
                     j.hasNext() && j.next().hasNext();
                     j++)
                 {
-                    Vertex a = mat * *j->punkt;
-                    Vertex b = mat * *j.next()->punkt;
-                    Vertex c = mat * *j.next().next()->punkt;
+                    Vertex a = mat * *j->point;
+                    Vertex b = mat * *j.next()->point;
+                    Vertex c = mat * *j.next().next()->point;
                     Point ta = (Point)Vertex(
-                        j->textur->x * (float)(txt->getWidth() - 1),
-                        j->textur->y * (float)(txt->getHeight() - 1));
+                        j->texture->x * (float)(txt->getWidth() - 1),
+                        j->texture->y * (float)(txt->getHeight() - 1));
                     Point tb = (Point)Vertex(
-                        j.next()->textur->x * (float)(txt->getWidth() - 1),
-                        j.next()->textur->y * (float)(txt->getHeight() - 1));
+                        j.next()->texture->x * (float)(txt->getWidth() - 1),
+                        j.next()->texture->y * (float)(txt->getHeight() - 1));
                     Point tc
-                        = (Point)Vertex(j.next().next()->textur->x
+                        = (Point)Vertex(j.next().next()->texture->x
                                             * (float)(txt->getWidth() - 1),
-                            j.next().next()->textur->y
+                            j.next().next()->texture->y
                                 * (float)(txt->getHeight() - 1));
                     zRObj.drawTriangleTextureAlpha(a, b, c, ta, tb, tc, *txt);
                 }
@@ -829,9 +829,9 @@ void Model2DObject::render(
             for( auto *j = &i->var->zListe()->getArray(); j->next->next &&
     j->next->next->set; j = j->next )
             {
-                Vertex a = mat * *j->var->punkt;
-                Vertex b = mat * *j->next->var->punkt;
-                Vertex c = mat * *j->next->next->var->punkt;
+                Vertex a = mat * *j->var->point;
+                Vertex b = mat * *j->next->var->point;
+                Vertex c = mat * *j->next->next->var->point;
                 zRObj.drawLine( a, b, 0xFFFFFFFF );
                 zRObj.drawLine( a, c, 0xFFFFFFFF );
                 zRObj.drawLine( b, c, 0xFFFFFFFF );
@@ -983,13 +983,13 @@ bool Model2DObject::calcHitPoint(Vertex pos, Vertex dir, Vertex& hitpoint) const
     return 0;
 }
 
-float Model2DObject::getLuftWiederstand() const
+float Model2DObject::getAirResistance() const
 {
     if (!rData) return 0;
     float angle = speed.angle(Vertex(1, 0));
     float faktor = -1;
-    if (getDrehung() > PI) faktor = -faktor;
-    if (getDrehung() < -PI) faktor = -faktor;
+    if (getRotation() > PI) faktor = -faktor;
+    if (getRotation() < -PI) faktor = -faktor;
     Mat3<float> m = Mat3<float>::rotation(rotation + faktor * angle)
                   * Mat3<float>::scaling(size);
     float yMin = INFINITY;
@@ -1011,7 +1011,7 @@ float Model2DObject::getLuftWiederstand() const
     return 0;
 }
 
-float Model2DObject::getMasse() const
+float Model2DObject::getMass() const
 {
     if (!rData) return 0;
     return abs(rData->getMasse() * size * size);
@@ -1020,7 +1020,7 @@ float Model2DObject::getMasse() const
 // Returns the texture of the first polygon
 Texture2D* Model2DObject::getTexture() const
 {
-    return textur->get(0);
+    return texture->get(0);
 }
 
 // Returns the texture of a polygon
@@ -1030,7 +1030,7 @@ Texture2D* Model2DObject::getTexture(const char* polygonName) const
     int index = 0;
     for (const Polygon2D& p : *rData->polygons)
     {
-        if (p.name->isEqual(polygonName)) return textur->get(index);
+        if (p.name->isEqual(polygonName)) return texture->get(index);
         index++;
     }
     return 0;
@@ -1039,7 +1039,7 @@ Texture2D* Model2DObject::getTexture(const char* polygonName) const
 // Returns the texture of the first polygon without increased reference counter
 Texture2D* Model2DObject::zTexture() const
 {
-    return textur->z(0);
+    return texture->z(0);
 }
 
 // Returns the texture of a polygon without increased reference counter
@@ -1049,7 +1049,7 @@ Texture2D* Model2DObject::zTexture(const char* polygonName) const
     int index = 0;
     for (const Polygon2D& p : *rData->polygons)
     {
-        if (p.name->isEqual(polygonName)) return textur->z(index);
+        if (p.name->isEqual(polygonName)) return texture->z(index);
         index++;
     }
     return 0;
@@ -1073,7 +1073,7 @@ Model2D::Model2D()
     color = 0;
     style = 0;
     rData = 0;
-    drehung = 0;
+    rotation = 0;
     size = 1;
     textur = new RCArray<Texture2D>;
 }
@@ -1092,23 +1092,23 @@ void Model2D::setModel(Model2DData* mdl)
     rData = mdl;
 }
 
-void Model2D::setDrehung(float drehung)
+void Model2D::setRotation(float rotation)
 {
-    this->drehung = drehung;
-    while (this->drehung > PI * 2)
-        this->drehung -= (float)PI * 2;
-    while (this->drehung < 0)
-        this->drehung += (float)PI * 2;
+    this->rotation = rotation;
+    while (this->rotation > PI * 2)
+        this->rotation -= (float)PI * 2;
+    while (this->rotation < 0)
+        this->rotation += (float)PI * 2;
     rend = 1;
 }
 
-void Model2D::addDrehung(float drehung)
+void Model2D::addRotation(float rotation)
 {
-    this->drehung += drehung;
-    while (this->drehung > PI * 2)
-        this->drehung -= (float)PI * 2;
-    while (this->drehung < 0)
-        this->drehung += (float)PI * 2;
+    this->rotation += rotation;
+    while (this->rotation > PI * 2)
+        this->rotation -= (float)PI * 2;
+    while (this->rotation < 0)
+        this->rotation += (float)PI * 2;
     rend = 1;
 }
 
@@ -1163,15 +1163,15 @@ void Model2D::render(Image& zRObj)
         return;
     Drawable::render(zRObj);
     int num = 0;
-    for (auto p : *rData->vListen)
+    for (auto p : *rData->vLists)
     {
         Mat3<float> mat = Mat3<float>::translation(pos)
-                        * Mat3<float>::rotation(drehung)
+                        * Mat3<float>::rotation(rotation)
                         * Mat3<float>::scaling(size);
         if (hasStyle(Model2D::Style::Texture))
         {
             if (!textur || !textur->z(num) || !textur->z(num)->zTexture()
-                || !rData->polygons->get(num).tKordinaten)
+                || !rData->polygons->get(num).tCoordinates)
             {
                 for (auto i : *p)
                 {
@@ -1179,9 +1179,9 @@ void Model2D::render(Image& zRObj)
                         j.hasNext() && j.next().hasNext();
                         j++)
                     {
-                        Vertex a = mat * *j->punkt;
-                        Vertex b = mat * *j.next()->punkt;
-                        Vertex c = mat * *j.next().next()->punkt;
+                        Vertex a = mat * *j->point;
+                        Vertex b = mat * *j.next()->point;
+                        Vertex c = mat * *j.next().next()->point;
                         if (hasStyle(Model2D::Style::Alpha))
                             zRObj.drawTriangleAlpha(a, b, c, color);
                         else
@@ -1198,20 +1198,20 @@ void Model2D::render(Image& zRObj)
                         j.hasNext() && j.next().hasNext();
                         j++)
                     {
-                        Vertex a = mat * *j->punkt;
-                        Vertex b = mat * *j.next()->punkt;
-                        Vertex c = mat * *j.next().next()->punkt;
+                        Vertex a = mat * *j->point;
+                        Vertex b = mat * *j.next()->point;
+                        Vertex c = mat * *j.next().next()->point;
                         Point ta = (Point)Vertex(
-                            j->textur->x * (float)(txt->getWidth() - 1),
-                            j->textur->y * (float)(txt->getHeight() - 1));
+                            j->texture->x * (float)(txt->getWidth() - 1),
+                            j->texture->y * (float)(txt->getHeight() - 1));
                         Point tb = (Point)Vertex(
-                            j.next()->textur->x * (float)(txt->getWidth() - 1),
-                            j.next()->textur->y
+                            j.next()->texture->x * (float)(txt->getWidth() - 1),
+                            j.next()->texture->y
                                 * (float)(txt->getHeight() - 1));
                         Point tc
-                            = (Point)Vertex(j.next().next()->textur->x
+                            = (Point)Vertex(j.next().next()->texture->x
                                                 * (float)(txt->getWidth() - 1),
-                                j.next().next()->textur->y
+                                j.next().next()->texture->y
                                     * (float)(txt->getHeight() - 1));
                         if (hasStyle(Model2D::Style::Alpha))
                             zRObj.drawTriangleTextureAlpha(
@@ -1230,9 +1230,9 @@ void Model2D::render(Image& zRObj)
                     j.hasNext() && j.next().hasNext();
                     j++)
                 {
-                    Vertex a = mat * *j->punkt;
-                    Vertex b = mat * *j.next()->punkt;
-                    Vertex c = mat * *j.next().next()->punkt;
+                    Vertex a = mat * *j->point;
+                    Vertex b = mat * *j.next()->point;
+                    Vertex c = mat * *j.next().next()->point;
                     if (hasStyle(Model2D::Style::Alpha))
                     {
                         zRObj.drawLineAlpha(a, b, color);
@@ -1277,9 +1277,9 @@ void Model2D::render(Image& zRObj)
 }
 
 // constant
-float Model2D::getDrehung() const
+float Model2D::getRotation() const
 {
-    return drehung;
+    return rotation;
 }
 
 float Model2D::getSize() const
@@ -1305,7 +1305,7 @@ bool Model2D::isPointInside(Vertex p) const
     {
         if (polygon.transparent) continue;
         Mat3<float> mat
-            = Mat3<float>::rotation(drehung) * Mat3<float>::scaling(size);
+            = Mat3<float>::rotation(rotation) * Mat3<float>::scaling(size);
         int anz = polygon.vertex->getEntryCount();
         bool c = 0;
         int j = anz - 1;
@@ -1332,7 +1332,7 @@ bool Model2D::isLineInside(Vertex a, Vertex b) const
     {
         if (rData->polygons->get(p).transparent) continue;
         Mat3<float> mat
-            = Mat3<float>::rotation(drehung) * Mat3<float>::scaling(size);
+            = Mat3<float>::rotation(rotation) * Mat3<float>::scaling(size);
         int anz = rData->polygons->get(p).vertex->getEntryCount();
         int j = anz - 1;
         for (int i = 0; i < anz; i++)
@@ -1382,7 +1382,7 @@ bool Model2D::isModelInside(const Model2D* zMdl, bool end) const
             return 0;
     }
     Mat3<float> mat = Mat3<float>::translation(pos)
-                    * Mat3<float>::rotation(drehung)
+                    * Mat3<float>::rotation(rotation)
                     * Mat3<float>::scaling(size);
     for (const Polygon2D& polygon : *rData->polygons)
     {

+ 31 - 29
Model2D.h

@@ -4,11 +4,11 @@
 #include <functional>
 
 #include "Array.h"
-#include "TriangleList.h"
+#include "Drawing.h"
 #include "Point.h"
+#include "TriangleList.h"
 #include "Vec3.h"
 #include "World2D.h"
-#include "Drawing.h"
 
 namespace Framework
 {
@@ -21,8 +21,8 @@ namespace Framework
         bool transparent;
         Text* name;
         Array<Vertex>* vertex;
-        Array<Vertex>* tKordinaten;
-        Vertex* schwerpunkt;
+        Array<Vertex>* tCoordinates;
+        Vertex* center;
     };
 
     //! The data for a 2D model
@@ -42,7 +42,7 @@ namespace Framework
 
     public:
         Array<Polygon2D>* polygons;
-        RCArray<RCArray<TriangleList<Vertex>>>* vListen;
+        RCArray<RCArray<TriangleList<Vertex>>>* vLists;
         Point minP, maxP;
 
         //! Constructor
@@ -52,7 +52,7 @@ namespace Framework
         //! Creates the triangle lists from all given vertices of the
         //! polygons \param polygons An array of polygons \return always
         //! returns 1
-        __declspec(dllexport) bool erstelleModell(Array<Polygon2D>* polygons);
+        __declspec(dllexport) bool createModell(Array<Polygon2D>* polygons);
         //! Deletes the created triangle lists and vertices
         __declspec(dllexport) void removeModell();
         //! Returns the polygon with a specific name
@@ -75,9 +75,9 @@ namespace Framework
         //! \param dir Start direction of the split
         //! \param polygonName The name of the polygon
         //! \param partA A pointer to a Model2DData object to store one
-        //! half (output) \param partB A pointer to a Model2DData object to store
-        //! the other half (output) \param posA The position of one new polygon
-        //! (output) \param posB The position of the other new polygon
+        //! half (output) \param partB A pointer to a Model2DData object to
+        //! store the other half (output) \param posA The position of one new
+        //! polygon (output) \param posB The position of the other new polygon
         //! (output) \param random A function that returns random values
         __declspec(dllexport) bool split(Vertex pos,
             Vertex dir,
@@ -96,7 +96,7 @@ namespace Framework
     {
     private:
         Model2DData* rData;
-        RCArray<Texture2D>* textur;
+        RCArray<Texture2D>* texture;
 
     public:
         //! Constructor
@@ -134,12 +134,12 @@ namespace Framework
         __declspec(dllexport) bool isLineInside(
             Vertex a, Vertex b, bool ignoreTransparent = 0) const override;
         //! Checks whether the object intersects with another
-        //! \param zObj A pointer to the other object without increased reference
-        //! counter \param sp A pointer to a point where the intersection
-        //! point is stored \param end 0 if all corners of both objects should be
-        //! checked. 1 if only the points of this model should be searched
-        //! in the other \param ignoreTransparentFlag if 1, collisions with
-        //! transparent polygons are also considered
+        //! \param zObj A pointer to the other object without increased
+        //! reference counter \param sp A pointer to a point where the
+        //! intersection point is stored \param end 0 if all corners of both
+        //! objects should be checked. 1 if only the points of this model should
+        //! be searched in the other \param ignoreTransparentFlag if 1,
+        //! collisions with transparent polygons are also considered
         __declspec(dllexport) virtual bool isModelInside(const Object2D* zObj,
             Vertex* sp = 0,
             bool end = 0,
@@ -152,10 +152,10 @@ namespace Framework
         //! hit point should be stored \return 1 if a hit point exists
         __declspec(dllexport) bool calcHitPoint(
             Vertex pos, Vertex dir, Vertex& hitpoint) const override;
-        __declspec(dllexport) float getLuftWiederstand() const override;
+        __declspec(dllexport) float getAirResistance() const override;
         //! Returns the mass of the 2D model (sum of the areas of the
         //! non-transparent polygons)
-        __declspec(dllexport) float getMasse() const override;
+        __declspec(dllexport) float getMass() const override;
         //! Returns the texture of the first polygon
         __declspec(dllexport) Texture2D* getTexture() const;
         //! Returns the texture of a polygon
@@ -167,7 +167,8 @@ namespace Framework
         __declspec(dllexport) Texture2D* zTexture() const;
         //! Returns the texture of a polygon without increased reference
         //! counter \param polygonName The name of the polygon
-        __declspec(dllexport) Texture2D* zTexture(const char* polygonName) const;
+        __declspec(dllexport) Texture2D* zTexture(
+            const char* polygonName) const;
         //! Returns the model data
         __declspec(dllexport) Model2DData* getModel() const;
         //! Returns the model data without increased reference counter
@@ -185,15 +186,15 @@ namespace Framework
                 = 0x8; //! If this flag is set, a texture is used when drawing
             static const __int64 Border
                 = 0x10; //! If this flag is set, the polygon borders are drawn
-            static const __int64 Alpha
-                = 0x40; //! If this flag is set, alpha blending is used when drawing
+            static const __int64 Alpha = 0x40; //! If this flag is set, alpha
+                                               //! blending is used when drawing
             static const __int64 Mesh
                 = 0x20; //! If this flag is set, the triangle borders are drawn
         };
 
     private:
         Model2DData* rData;
-        float drehung;
+        float rotation;
         float size;
         int color;
         RCArray<Texture2D>* textur;
@@ -207,11 +208,11 @@ namespace Framework
         //! \param mdl The model data
         __declspec(dllexport) void setModel(Model2DData* mdl);
         //! Sets the counter-clockwise rotation of the model
-        //! \param drehung The angle in radians
-        __declspec(dllexport) void setDrehung(float drehung);
+        //! \param rotation The angle in radians
+        __declspec(dllexport) void setRotation(float rotation);
         //! Adds to the current rotation angle
-        //! \param drehung The angle in radians to add
-        __declspec(dllexport) void addDrehung(float drehung);
+        //! \param rotation The angle in radians to add
+        __declspec(dllexport) void addRotation(float rotation);
         //! Sets the scaling of the model
         //! \param size The scaling factor
         __declspec(dllexport) void setSize(float size);
@@ -236,7 +237,7 @@ namespace Framework
         //! \param zRObj The image to draw into
         __declspec(dllexport) void render(Image& zRObj) override;
         //! Returns the rotation of the model
-        __declspec(dllexport) float getDrehung() const;
+        __declspec(dllexport) float getRotation() const;
         //! Returns the scaling factor
         __declspec(dllexport) float getSize() const;
         //! Returns whether a point is inside the model
@@ -251,8 +252,9 @@ namespace Framework
         __declspec(dllexport) bool isLineInside(Vertex a, Vertex b) const;
         //! Checks whether the model intersects with another
         //! \param zMdl A pointer to the other model without increased reference
-        //! counter \param end 0 if all corners of both models should be checked.
-        //! 1 if only the points of this model should be searched in the other
+        //! counter \param end 0 if all corners of both models should be
+        //! checked. 1 if only the points of this model should be searched in
+        //! the other
         __declspec(dllexport) bool isModelInside(
             const Model2D* zMdl, bool end = 0) const;
         //! Returns the model data

+ 7 - 7
Model3D.cpp

@@ -417,7 +417,7 @@ void Model3DData::buildIndexBuffer()
 
 // Sets the pointer to a default skeleton
 //  s: The skeleton to be used
-void Model3DData::setSkelettZ(Skeleton* s)
+void Model3DData::setSkeletonZ(Skeleton* s)
 {
     if (skelett) skelett->release();
     skelett = s;
@@ -487,7 +487,7 @@ void Model3DData::setSpecularFactor(float f)
 //  z: The z coordinate of all points of the model
 void Model3DData::copyModel2D(Model2DData* model, float z)
 {
-    if (model && model->vListen && model->polygons)
+    if (model && model->vLists && model->polygons)
     {
         clearModel();
         int vAnz = 0;
@@ -495,7 +495,7 @@ void Model3DData::copyModel2D(Model2DData* model, float z)
             vAnz += p.vertex->getEntryCount();
         Vertex3D* vertexList = new Vertex3D[vAnz];
         int index = 0;
-        for (auto i : *model->vListen)
+        for (auto i : *model->vLists)
         {
             Polygon3D* p = new Polygon3D();
             p->indexAnz = 0;
@@ -516,8 +516,8 @@ void Model3DData::copyModel2D(Model2DData* model, float z)
                     if (index < vAnz)
                     {
                         vertexList[index].pos
-                            = Vec3<float>(k->punkt->x, k->punkt->y, z);
-                        vertexList[index].tPos = (Vec2<float>)*k->textur;
+                            = Vec3<float>(k->point->x, k->point->y, z);
+                        vertexList[index].tPos = (Vec2<float>)*k->texture;
                         if (k.hasNext() && k.next().hasNext())
                         {
                             p->indexList[p->indexAnz] = index;
@@ -619,7 +619,7 @@ float Model3DData::getSpecularFactor() const
 }
 
 // Returns a copy of the skeleton that can be used for animations
-Skeleton* Model3DData::copySkelett() const
+Skeleton* Model3DData::copySkeleton() const
 {
     return skelett ? skelett->copySceleton() : 0;
 }
@@ -752,7 +752,7 @@ void Model3D::setModelData(Model3DData* data)
     model = data;
     if (model)
     {
-        skelett = model->copySkelett();
+        skelett = model->copySkeleton();
         this->ambientFactor = model->getAmbientFactor();
         this->specularFactor = model->getSpecularFactor();
         this->diffusFactor = model->getDiffusFactor();

+ 2 - 2
Model3D.h

@@ -190,7 +190,7 @@ namespace Framework
         DLLEXPORT void buildIndexBuffer();
         //! Sets a pointer to a default skeleton to use
         //! \param s The skeleton to use
-        DLLEXPORT void setSkelettZ(Skeleton* s);
+        DLLEXPORT void setSkeletonZ(Skeleton* s);
         //! Sets a pointer to a list of all vertices of the model
         //! \param vertexList An array of vertices
         //! \param anz The number of vertices in the array
@@ -249,7 +249,7 @@ namespace Framework
         //! is multiplied
         DLLEXPORT float getSpecularFactor() const;
         //! Returns a copy of the skeleton that can be used for animations
-        DLLEXPORT Skeleton* copySkelett() const;
+        DLLEXPORT Skeleton* copySkeleton() const;
         //! Returns the number of vertices
         DLLEXPORT int getVertexCount() const;
         //! Returns a buffer with all vertices of the model

+ 2 - 2
Point.cpp

@@ -11,13 +11,13 @@ using namespace Framework;
 inline Point Framework::ScreenSize(int mId) // Returns the screen size
 {
     Monitor m = getMonitor(mId);
-    return Point(m.Width, m.height);
+    return Point(m.width, m.height);
 }
 
 inline Point Framework::ScreenCenter(int mId) // Returns the screen center
 {
     Monitor m = getMonitor(mId);
-    return Point(m.x + m.Width / 2, m.y + m.height / 2);
+    return Point(m.x + m.width / 2, m.y + m.height / 2);
 }
 
 inline Point Framework::ScreenCenter(

+ 21 - 21
RenderThread.cpp

@@ -12,9 +12,9 @@ using namespace Framework;
 // Constructor
 RenderTh::RenderTh()
     : Thread(),
-      stoppen(0),
-      bildschirm(0),
-      zeit(new Timer()),
+      stop(0),
+      screen(0),
+      timer(new Timer()),
       renderTickTime(1 / 60),
       renderParameter(0),
       tickParameter(0),
@@ -29,8 +29,8 @@ RenderTh::RenderTh()
 RenderTh::~RenderTh()
 {
     terminate();
-    if (bildschirm) bildschirm->release();
-    zeit->release();
+    if (screen) screen->release();
+    timer->release();
 }
 
 // non-constant
@@ -47,8 +47,8 @@ void RenderTh::unlock()
 void RenderTh::setScreen(Screen* bildschirm) // sets the screen
 {
     lock();
-    if (this->bildschirm) this->bildschirm->release();
-    this->bildschirm = bildschirm;
+    if (this->screen) this->screen->release();
+    this->screen = bildschirm;
     unlock();
 }
 
@@ -56,20 +56,20 @@ void RenderTh::thread() // Render loop
 {
     int val = 0;
     double time = 0;
-    zeit->measureStart();
+    timer->measureStart();
     double ausgleich = 0;
-    while (!stoppen)
+    while (!stop)
     {
         lock();
-        if (bildschirm && !pause)
+        if (screen && !pause)
         {
             if (renderFunktion)
                 renderFunktion(
-                    renderParameter, this, bildschirm->zRenderImage());
-            bildschirm->render();
+                    renderParameter, this, screen->zRenderImage());
+            screen->render();
             val++;
             if (tickFunktion) tickFunktion(tickParameter, this, renderTickTime);
-            bildschirm->tick(renderTickTime);
+            screen->tick(renderTickTime);
             time += renderTickTime;
             unlock();
             if (time > 1)
@@ -89,22 +89,22 @@ void RenderTh::thread() // Render loop
         }
         ausgleich += 1.0 / maxFps - renderTickTime;
         if (ausgleich > 0) Sleep((int)(ausgleich * 1000));
-        zeit->measureEnd();
-        zeit->measureStart();
-        renderTickTime = zeit->getSekunden();
+        timer->measureEnd();
+        timer->measureStart();
+        renderTickTime = timer->getSekunden();
     }
-    zeit->measureEnd();
+    timer->measureEnd();
 }
 
 void RenderTh::beginn() // starts rendering
 {
-    stoppen = 0;
+    stop = 0;
     start();
 }
 
 void RenderTh::terminate() // terminates the thread
 {
-    stoppen = 1;
+    stop = 1;
     waitForThread(2000);
     if (run) ende();
 }
@@ -152,12 +152,12 @@ void RenderTh::setTickFunktionParameter(
 // constant
 Screen* RenderTh::getScreen() const // returns the screen
 {
-    return bildschirm ? dynamic_cast<Screen*>(bildschirm->getThis()) : 0;
+    return screen ? dynamic_cast<Screen*>(screen->getThis()) : 0;
 }
 
 Screen* RenderTh::zScreen() const
 {
-    return bildschirm;
+    return screen;
 }
 
 double RenderTh::getRenderTickZeit()

+ 7 - 7
RenderThread.h

@@ -9,17 +9,17 @@
 namespace Framework
 {
     class Screen; //! Screen.h
-    class Timer; //! Timer.h
-    class Image;       //! Image.h
+    class Timer;  //! Timer.h
+    class Image;  //! Image.h
 
     //! A thread that manages a screen. It calls the render() and
     //! tick() functions automatically
     class RenderTh : public Thread
     {
     private:
-        bool stoppen;
-        Screen* bildschirm;
-        Timer* zeit;
+        bool stop;
+        Screen* screen;
+        Timer* timer;
         double renderTickTime;
         void* renderParameter;
         void* tickParameter;
@@ -44,8 +44,8 @@ namespace Framework
         //! first has called unlock().
         DLLEXPORT void unlock();
         //! Sets the screen object to be managed
-        //! \param bildschirm The screen
-        DLLEXPORT void setScreen(Screen* bildschirm);
+        //! \param screen The screen
+        DLLEXPORT void setScreen(Screen* screen);
         //! The function that is automatically executed in a new thread
         DLLEXPORT void thread() override;
         //! Starts the render thread

+ 1 - 1
Screen.cpp

@@ -353,7 +353,7 @@ int MonitorEnum(HMONITOR m, HDC dc, LPRECT r, LPARAM p)
     mon->exists = 1;
     mon->x = r->left;
     mon->y = r->top;
-    mon->Width = r->right - r->left;
+    mon->width = r->right - r->left;
     mon->height = r->bottom - r->top;
     mon->name = info.szDevice;
     if (mon->x == 0 && mon->y == 0)

+ 1 - 1
Screen.h

@@ -64,7 +64,7 @@ namespace Framework
     //! A structure containing information about a monitor
     struct Monitor
     {
-        int x, y, Width,
+        int x, y, width,
             height;     //! Coordinates of the monitor and its resolution
         bool exists; //! Stores whether the monitor really exists
         Text name;

+ 4 - 4
TextField.cpp

@@ -444,13 +444,13 @@ int TextField::getTextHeight() const
         len = txtWithLineBreaks.getLength();
     }
     int max = 0;
-    int abstand = 0;
+    int distance = 0;
     for (int i = 0; i < len; i++)
     {
         if (text[i] == '\n')
         {
-            th += max + abstand;
-            abstand = 0;
+            th += max + distance;
+            distance = 0;
             max = 0;
             tm->nextStyle();
             continue;
@@ -460,7 +460,7 @@ int TextField::getTextHeight() const
         {
             int tmp = r->getRowHeight();
             max = max >= tmp ? max : tmp;
-            if (max == tmp) abstand = r->getLineSpacing();
+            if (max == tmp) distance = r->getLineSpacing();
         }
         tm->nextStyle();
     }

+ 16 - 16
Texture2D.cpp

@@ -38,17 +38,17 @@ void Texture2D::setCircularAnimation(bool ca)
 
 // sets a pointer to the texture (if not animated)
 //  textur: The pointer to the image
-void Texture2D::setTextureZ(Image* textur)
+void Texture2D::setTextureZ(Image* texture)
 {
     if (txt) txt->release();
-    txt = textur;
+    txt = texture;
 }
 
 // adds an animation
 //  textur: The pointer to the animation data
-void Texture2D::addAnimationZ(Animation2DData* textur)
+void Texture2D::addAnimationZ(Animation2DData* texture)
 {
-    animData->add(new Animation{textur, 0, 0});
+    animData->add(new Animation{texture, 0, 0});
 }
 
 // sets the current animation
@@ -58,8 +58,8 @@ void Texture2D::setAnimation(int index)
     if (animationIndex == index) return;
     if (animationIndex != -1)
     {
-        animData->get(animationIndex)->jetzt = 0;
-        animData->get(animationIndex)->ausgleich = 0;
+        animData->get(animationIndex)->now = 0;
+        animData->get(animationIndex)->compensation = 0;
     }
     animationIndex = index;
     int anz = animData->getEntryCount();
@@ -74,8 +74,8 @@ void Texture2D::nextAnimation()
 {
     if (animationIndex != -1)
     {
-        animData->get(animationIndex)->jetzt = 0;
-        animData->get(animationIndex)->ausgleich = 0;
+        animData->get(animationIndex)->now = 0;
+        animData->get(animationIndex)->compensation = 0;
     }
     animationIndex++;
     int anz = animData->getEntryCount();
@@ -92,21 +92,21 @@ bool Texture2D::tick(double t)
     if (animationIndex != -1)
     {
         Animation* a = animData->get(animationIndex);
-        a->ausgleich += t;
-        int tmp = a->jetzt;
+        a->compensation += t;
+        int tmp = a->now;
         int tmp2 = animationIndex;
         a->data->lock();
-        if (a->ausgleich >= 1.0 / a->data->getFPS())
+        if (a->compensation >= 1.0 / a->data->getFPS())
         {
-            a->ausgleich -= 1.0 / a->data->getFPS();
-            if (++(a->jetzt) >= a->data->getImageCount())
+            a->compensation -= 1.0 / a->data->getFPS();
+            if (++(a->now) >= a->data->getImageCount())
             {
-                a->jetzt = 0;
+                a->now = 0;
                 if (!a->data->isRepeating()) nextAnimation();
             }
         }
         a->data->unlock();
-        if (tmp != a->jetzt || tmp2 != animationIndex) return 1;
+        if (tmp != a->now || tmp2 != animationIndex) return 1;
     }
     return 0;
 }
@@ -116,6 +116,6 @@ Image* Texture2D::zTexture() const
 {
     if (animationIndex != -1)
         return animData->get(animationIndex)
-            ->data->zImage(animData->get(animationIndex)->jetzt);
+            ->data->zImage(animData->get(animationIndex)->now);
     return txt;
 }

+ 2 - 2
Texture2D.h

@@ -13,8 +13,8 @@ namespace Framework
         struct Animation
         {
             Animation2DData* data;
-            int jetzt;
-            double ausgleich;
+            int now;
+            double compensation;
         };
 
         bool circularAnimation;

+ 28 - 28
TriangleList.h

@@ -10,23 +10,23 @@ namespace Framework
     //! A corner of a triangle
     struct TriangleVertex
     {
-        T* punkt;
-        Vec2<float>* textur;
+        T* point;
+        Vec2<float>* texture;
 
         //! Constructor
-        //! \param punkt The coordinate of the corner
-        //! \param textur The coordinate in the texture
-        TriangleVertex(T* punkt, Vec2<float>* textur)
+        //! \param point The coordinate of the corner
+        //! \param texture The coordinate in the texture
+        TriangleVertex(T* point, Vec2<float>* texture)
         {
-            this->punkt = punkt;
-            this->textur = textur;
+            this->point = point;
+            this->texture = texture;
         }
 
         //! Destructor
         ~TriangleVertex()
         {
-            delete punkt;
-            delete textur;
+            delete point;
+            delete texture;
         }
     };
 
@@ -36,65 +36,65 @@ namespace Framework
     class TriangleList : public virtual ReferenceCounter
     {
     private:
-        Array<TriangleVertex<T>*>* punkte;
+        Array<TriangleVertex<T>*>* points;
 
     public:
         //! Constructor
         TriangleList()
             : ReferenceCounter()
         {
-            punkte = new Array<TriangleVertex<T>*>();
+            points = new Array<TriangleVertex<T>*>();
         }
 
         //! Destructor
         ~TriangleList()
         {
-            int anz = punkte->getEntryCount();
+            int anz = points->getEntryCount();
             for (int i = 0; i < anz; i++)
-                delete punkte->get(i);
-            punkte->release();
+                delete points->get(i);
+            points->release();
         }
 
         //! Adds a point to the list
         //! \param p The coordinates of the point
-        //! \param textur The coordinates in the texture
-        void addPoint(T* p, Vec2<float>* textur)
+        //! \param texture The coordinates in the texture
+        void addPoint(T* p, Vec2<float>* texture)
         {
-            punkte->add(new TriangleVertex<T>(p, textur));
+            points->add(new TriangleVertex<T>(p, texture));
         }
 
         //! Deletes the last point
         void removeLetztenPunkt()
         {
-            int i = punkte->getEntryCount() - 1;
-            if (!punkte->has(i)) return;
-            delete punkte->get(i);
-            punkte->remove(i);
+            int i = points->getEntryCount() - 1;
+            if (!points->has(i)) return;
+            delete points->get(i);
+            points->remove(i);
         }
 
         //! Deletes all corners
         void lehren()
         {
-            int anz = punkte->getEntryCount();
+            int anz = points->getEntryCount();
             for (int i = 0; i < anz; i++)
-                delete punkte->get(i);
-            punkte->clear();
+                delete points->get(i);
+            points->clear();
         }
 
         //! Returns the number of triangles
         int getTriangleCount() const
         {
-            return punkte->getEntryCount() - 2;
+            return points->getEntryCount() - 2;
         }
 
         //! Returns whether a texture is used
         bool hasTexture() const
         {
-            int anz = punkte->getEntryCount();
+            int anz = points->getEntryCount();
             bool ret = 1;
             for (int i = 0; i < anz; i++)
             {
-                if (punkte->has(i)) ret &= punkte->get(i)->textur;
+                if (points->has(i)) ret &= points->get(i)->textur;
             }
             return ret;
         }
@@ -102,7 +102,7 @@ namespace Framework
         //! Returns the list of points
         Array<TriangleVertex<T>*>* zListe() const
         {
-            return punkte;
+            return points;
         }
     };
 } // namespace Framework

+ 1 - 1
Vec2.h

@@ -201,7 +201,7 @@ namespace Framework
 
         //! Calculates the midpoint between two vectors
         //!  p2: The other vector
-        inline Vec2 mittelpunktMit(const Vec2& p2) const
+        inline Vec2 centerWith(const Vec2& p2) const
         {
             return Vec2((T)((x + p2.x) / 2.0), (T)((y + p2.y) / 2.0));
         }

+ 3 - 3
Vec3.h

@@ -113,7 +113,7 @@ namespace Framework
 
         //! Calculates the square of the distance between two vectors
         //! \param p The other vector
-        inline T abstandSq(const Vec3& p) const
+        inline T distanceSq(const Vec3& p) const
         {
             return (x - p.x) * (x - p.x) + (y - p.y) * (y - p.y)
                  + (z - p.z) * (z - p.z);
@@ -121,9 +121,9 @@ namespace Framework
 
         //! Calculates the distance between two vectors
         //! \param p The other vector
-        inline T abstand(const Vec3& p) const
+        inline T distance(const Vec3& p) const
         {
-            return sqrt(abstandSq(p));
+            return sqrt(distanceSq(p));
         }
 
         //! Returns a new vector that is the negation of this one

+ 3 - 3
VecN.h

@@ -112,7 +112,7 @@ namespace Framework
 
         //! Calculates the square of the distance between two vectors
         //! \param p The other vector
-        inline T abstandSq(const VecN& p) const
+        inline T distanceSq(const VecN& p) const
         {
             T sum = (T)0;
             for (int i = 0; i < N; i++)
@@ -122,9 +122,9 @@ namespace Framework
 
         //! Calculates the distance between two vectors
         //! \param p The other vector
-        inline T abstand(const VecN& p) const
+        inline T distance(const VecN& p) const
         {
-            return sqrt(abstandSq(p));
+            return sqrt(distanceSq(p));
         }
 
         //! Returns a new vector that is the negation of this one

+ 18 - 18
World2D.cpp

@@ -50,23 +50,23 @@ void Object2D::setPosition(float x, float y)
     position = Vertex(x, y);
 }
 
-void Object2D::setDrehungSpeed(float ds)
+void Object2D::setRotationSpeed(float ds)
 {
     rSpeed = ds;
 }
 
-void Object2D::setDrehung(float drehung)
+void Object2D::setRotation(float rotation)
 {
-    rotation = drehung;
+    rotation = rotation;
     while (rotation > PI * 2)
         rotation -= (float)PI * 2;
     while (rotation < 0)
         rotation += (float)PI * 2;
 }
 
-void Object2D::addDrehung(float drehung)
+void Object2D::addRotation(float rotation)
 {
-    rotation += drehung;
+    rotation += rotation;
     while (rotation > PI * 2)
         rotation -= (float)PI * 2;
     while (rotation < 0)
@@ -100,15 +100,15 @@ bool Object2D::handleCollision(Object2D* obj)
         // Velocity of the other object with rotation
         Vertex v2
             = obj->getSpeed()
-            + getWorldDir(obj->getObjectPos(hp).rotation(obj->getDrehungSpeed())
+            + getWorldDir(obj->getObjectPos(hp).rotation(obj->getRotationSpeed())
                           - obj->getObjectPos(hp));
         if ((hp - obj->getPosition()).getLengthSq()
                 > (hp + v1 * 0.03f - obj->getPosition()).getLengthSq()
             || (hp - getPosition()).getLengthSq()
                    > (hp + v2 * 0.03f - getPosition()).getLengthSq())
         { // only if they are moving towards each other
-            float m1 = getMasse() * v1.getLength();      // area of object 1
-            float m2 = obj->getMasse() * v2.getLength(); // area of object 2
+            float m1 = getMass() * v1.getLength();      // area of object 1
+            float m2 = obj->getMass() * v2.getLength(); // area of object 2
             if (m1 == 0 || m2 == 0)
                 return 0; // if an object has no mass, ignore the
                           // collision
@@ -116,7 +116,7 @@ bool Object2D::handleCollision(Object2D* obj)
             float nm2 = m2 / (m1 + m2); // coefficient for object 1
             // rSpeed *= nm1; // adjust rotation speed (object 1)
             // speed *= nm1; // adjust movement speed (object 1)
-            // obj->setDrehungSpeed( obj->getDrehungSpeed() * nm2 ); //
+            // obj->setRotationSpeed( obj->getRotationSpeed() * nm2 ); //
             // adjust rotation speed (object 2) obj->setSpeed(
             // obj->getSpeed() * nm2 ); // adjust movement speed
             // (object 2)
@@ -124,7 +124,7 @@ bool Object2D::handleCollision(Object2D* obj)
                 = getSpeed().getLength() + obj->getSpeed().getLength();
             rSpeed = 0;
             speed = Vertex();
-            obj->setDrehungSpeed(0);
+            obj->setRotationSpeed(0);
             obj->setSpeed(Vertex());
             if (v2.x || v2.y) impuls(hp - v2, v2);
             if (getSpeed().getLength() > 0)
@@ -155,15 +155,15 @@ bool Object2D::tick(const WorldInfo& info, double zeit)
     while (zeit > 1)
     {
         rSpeed -= rSpeed
-                - (rSpeed / (1 + info.airResistance * getLuftWiederstand()));
+                - (rSpeed / (1 + info.airResistance * getAirResistance()));
         speed -= speed
-               - (speed / (1 + info.airResistance * getLuftWiederstand()));
+               - (speed / (1 + info.airResistance * getAirResistance()));
         zeit -= 1;
     }
     rSpeed
-        -= (rSpeed - (rSpeed / (1 + info.airResistance * getLuftWiederstand())))
+        -= (rSpeed - (rSpeed / (1 + info.airResistance * getAirResistance())))
          * (float)zeit;
-    speed -= (speed - (speed / (1 + info.airResistance * getLuftWiederstand())))
+    speed -= (speed - (speed / (1 + info.airResistance * getAirResistance())))
            * (float)zeit;
     if (info.circular && info.hasSize && info.size.x && info.size.y)
     {
@@ -237,12 +237,12 @@ Vertex Object2D::getPosition() const
     return position;
 }
 
-float Object2D::getDrehungSpeed() const
+float Object2D::getRotationSpeed() const
 {
     return rSpeed;
 }
 
-float Object2D::getDrehung() const
+float Object2D::getRotation() const
 {
     return rotation;
 }
@@ -257,12 +257,12 @@ bool Object2D::calcHitPoint(Vertex pos, Vertex dir, Vertex& hitpoint) const
     return 0;
 }
 
-float Object2D::getLuftWiederstand() const
+float Object2D::getAirResistance() const
 {
     return 0;
 }
 
-float Object2D::getMasse() const
+float Object2D::getMass() const
 {
     return 0;
 }

+ 9 - 9
World2D.h

@@ -64,13 +64,13 @@ namespace Framework
         DLLEXPORT void setPosition(float x, float y);
         //! Sets the rotation speed in radians per second
         //! \param ds The new rotation speed
-        DLLEXPORT void setDrehungSpeed(float ds);
+        DLLEXPORT void setRotationSpeed(float ds);
         //! Sets the counter-clockwise rotation of the model
-        //! \param drehung The angle in radians
-        DLLEXPORT void setDrehung(float drehung);
+        //! \param rotation The angle in radians
+        DLLEXPORT void setRotation(float rotation);
         //! Adds to the current rotation angle
-        //! \param drehung The angle in radians to add
-        DLLEXPORT void addDrehung(float drehung);
+        //! \param rotation The angle in radians to add
+        DLLEXPORT void addRotation(float rotation);
         //! Sets the scaling of the model
         //! \param size The scaling factor
         DLLEXPORT void setSize(float size);
@@ -140,9 +140,9 @@ namespace Framework
         //! Returns the position of the object
         DLLEXPORT Vertex getPosition() const;
         //! Returns the rotation speed of the object
-        DLLEXPORT float getDrehungSpeed() const;
+        DLLEXPORT float getRotationSpeed() const;
         //! Returns the rotation of the object
-        DLLEXPORT float getDrehung() const;
+        DLLEXPORT float getRotation() const;
         //! Returns the scaling of the object
         DLLEXPORT float getSize() const;
         //! Returns a bounding box containing all points of the object
@@ -158,9 +158,9 @@ namespace Framework
             Vertex pos, Vertex dir, Vertex& hitpoint) const;
         //! Determines the area of the object perpendicular to the
         //! movement vector
-        DLLEXPORT virtual float getLuftWiederstand() const;
+        DLLEXPORT virtual float getAirResistance() const;
         //! Returns the mass of the object
-        DLLEXPORT virtual float getMasse() const;
+        DLLEXPORT virtual float getMass() const;
         //! Returns whether other objects can collide with this object
         //! \return 0 if no collisions exist
         DLLEXPORT bool canCollide();

+ 2 - 2
World3D.cpp

@@ -118,7 +118,7 @@ void World3D::doMouseEvent(MouseEvent3D& me)
     //{
     //     if( *i )
     //     {
-    //         distSq[ anz ] = me.pos.abstandSq( ( *i )->getPos() );
+    //         distSq[ anz ] = me.pos.distanceSq( ( *i )->getPos() );
     //         alphaVS[ anz ] = *i;
     //         anz++;
     //     }
@@ -129,7 +129,7 @@ void World3D::doMouseEvent(MouseEvent3D& me)
     //{
     //     if( *i )
     //     {
-    //         distSq[ anz ] = me.pos.abstandSq( ( *i )->getPos() );
+    //         distSq[ anz ] = me.pos.distanceSq( ( *i )->getPos() );
     //         alphaVS[ anz ] = *i;
     //         anz++;
     //     }