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

Function flipd1

examples/pentominoes.cpp:932–937  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

930 }
931 template<class CArray, class Array>
932 void flipd1(CArray t1, int w1, int h1, Array t2, int& w2, int& h2) {
933 w2 = h1; h2 = w1;
934 for (int h = 0; h < h1; ++h)
935 for (int w = 0; w < w1; ++w)
936 t2[pos(w, h, h2, w2)] = t1[pos(h, w, h1, w1)];
937 }
938 template<class CArray, class Array>
939 void flipd2(CArray t1, int w1, int h1, Array t2, int& w2, int& h2) {
940 w2 = h1; h2 = w1;

Callers

nothing calls this directly

Calls 1

posFunction · 0.70

Tested by

no test coverage detected