* Load a Palette from a location in the loaded data */
| 75 | * Load a Palette from a location in the loaded data |
| 76 | */ |
| 77 | void LoadPalette(size_t pFrom, const size_t pCount, const size_t pStartColorID = 0) { |
| 78 | |
| 79 | auto Buffer = mData->data(); |
| 80 | |
| 81 | for (size_t ColorID = pStartColorID; ColorID < pStartColorID + pCount; ColorID++) { |
| 82 | |
| 83 | // Get the next color values |
| 84 | mPalette[ColorID].mRed = *(Buffer + pFrom++); |
| 85 | mPalette[ColorID].mGreen = *(Buffer + pFrom++); |
| 86 | mPalette[ColorID].mBlue = *(Buffer + pFrom++); |
| 87 | } |
| 88 | } |
| 89 | |
| 90 | /** |
| 91 | * Load a Palette from a buffer (BIG ENDIAN) |
no outgoing calls
no test coverage detected