MCPcopy Create free account
hub / github.com/Gecode/gecode / flipx

Function flipx

examples/pentominoes.cpp:918–923  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

916 }
917 template<class CArray, class Array>
918 void flipx(CArray t1, int w1, int h1, Array t2, int& w2, int& h2) {
919 w2 = w1; h2 = h1;
920 for (int h = 0; h < h1; ++h)
921 for (int w = 0; w < w1; ++w)
922 t2[pos(h, w2-w-1, h2, w2)] = t1[pos(h, w, h1, w1)];
923 }
924 template<class CArray, class Array>
925 void flipy(CArray t1, int w1, int h1, Array t2, int& w2, int& h2) {
926 w2 = w1; h2 = h1;

Callers

nothing calls this directly

Calls 1

posFunction · 0.70

Tested by

no test coverage detected