45 for (
int i = 0; i < 3; i++) {
52 t[i][0] = tintN.
getUint(
"r", t[i][0] * 255) / 255.0f;
53 t[i][1] = tintN.
getUint(
"g", t[i][1] * 255) / 255.0f;
54 t[i][2] = tintN.
getUint(
"b", t[i][2] * 255) / 255.0f;
55 t[i][3] = tintN.
getUint(
"a", t[i][3] * 255) / 255.0f;
Handling version V3.2/V3.3 of BioWare's GFFs (generic file format).
Neverwinter Nights 2 utility functions.
A class holding an UTF-8 string.
bool hasField(const Common::UString &field) const
Does this specific field exist?
uint64 getUint(const Common::UString &field, uint64 def=0) const
utf8::iterator< std::string::const_iterator > iterator
static UString format(const char *s,...) GCC_PRINTF(1
Print formatted data into an UString object, similar to sprintf().
bool readTint(const Aurora::GFF3Struct &gff, float t[3][4])
const GFF3Struct & getStruct(const Common::UString &field) const
Common::UString createDisplayName(const Common::UString &name)
Strip text enclosed in {} from a string.