MCPcopy Create free account
hub / github.com/creatale/node-dv / sign

Function sign

deps/tesseract/ccstruct/points.cpp:55–60  ·  view source on GitHub ↗

The fortran/basic sgn function returns -1, 0, 1 if x < 0, x == 0, x > 0 respectively.

Source from the content-addressed store, hash-verified

53// The fortran/basic sgn function returns -1, 0, 1 if x < 0, x == 0, x > 0
54// respectively.
55static int sign(int x) {
56 if (x < 0)
57 return -1;
58 else
59 return x > 0 ? 1 : 0;
60}
61
62// Writes to the given file. Returns false in case of error.
63bool ICOORD::Serialize(FILE* fp) const {

Callers 1

setup_renderMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected