MCPcopy Index your code
hub / github.com/MapServer/MapServer / msHexToInt

Function msHexToInt

mapstring.c:1527–1535  ·  view source on GitHub ↗

** Converts a 2 character hexidecimal string to an integer. */

Source from the content-addressed store, hash-verified

1525** Converts a 2 character hexidecimal string to an integer.
1526*/
1527int msHexToInt(char *hex) {
1528 int number;
1529
1530 number = (hex[0] >= 'A' ? ((hex[0] & 0xdf) - 'A')+10 : (hex[0] - '0'));
1531 number *= 16;
1532 number += (hex[1] >= 'A' ? ((hex[1] & 0xdf) - 'A')+10 : (hex[1] - '0'));
1533
1534 return(number);
1535}
1536
1537
1538/*

Callers 8

msSLDParseStrokeFunction · 0.85
msSLDParsePolygonFillFunction · 0.85
msSLDParseTextParamsFunction · 0.85
msSLDSetColorObjectFunction · 0.85
loadColorFunction · 0.85
loadColorWithAlphaFunction · 0.85
bindColorAttributeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected