MCPcopy Create free account
hub / github.com/OneLoneCoder/olcPixelGameEngine / Shear

Method Shear

extensions/olcPGEX_Graphics2D.h:241–248  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

239 }
240
241 void olc::GFX2D::Transform2D::Shear(float sx, float sy)
242 {
243 // Construct Shear Matrix
244 matrix[2][0][0] = 1.0f; matrix[2][1][0] = sx; matrix[2][2][0] = 0.0f;
245 matrix[2][0][1] = sy; matrix[2][1][1] = 1.0f; matrix[2][2][1] = 0.0f;
246 matrix[2][0][2] = 0.0f; matrix[2][1][2] = 0.0f; matrix[2][2][2] = 1.0f;
247 Multiply();
248 }
249
250 void olc::GFX2D::Transform2D::Translate(float ox, float oy)
251 {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected