Clean warnings
This commit is contained in:
parent
e401136b4d
commit
550cacef3f
|
|
@ -156,7 +156,6 @@ static void Base64EncodeTo(const uint8_t *data, size_t in_len, T p)
|
|||
if (in_len == 0)
|
||||
return;
|
||||
|
||||
size_t out_len = 4 * ((in_len + 2) / 3);
|
||||
size_t i;
|
||||
|
||||
if (in_len == 1) {
|
||||
|
|
|
|||
|
|
@ -556,9 +556,6 @@ void CalculateVertexNormals(const mbsp_t *bsp)
|
|||
const qvec3f f_norm = Face_Normal(bsp, &f); // get the face normal
|
||||
|
||||
// face tangent
|
||||
auto texinfo = BSP_GetTexinfo(bsp, f.texinfo);
|
||||
auto miptex = Face_RgbaMiptex(bsp, &f);
|
||||
|
||||
auto t1 = TexSpaceToWorld(bsp, &f);
|
||||
std::tuple<qvec3f, qvec3f> tangents(t1.col(0).xyz(), qv::normalize(qv::cross(f_norm, t1.col(0).xyz())));
|
||||
|
||||
|
|
@ -577,9 +574,6 @@ void CalculateVertexNormals(const mbsp_t *bsp)
|
|||
const qvec3f f2_norm = Face_Normal(bsp, f2);
|
||||
|
||||
// f2 face tangent
|
||||
auto f2_texinfo = BSP_GetTexinfo(bsp, f2->texinfo);
|
||||
auto f2_miptex = Face_RgbaMiptex(bsp, f2);
|
||||
|
||||
auto t2 = TexSpaceToWorld(bsp, f2);
|
||||
std::tuple<qvec3f, qvec3f> f2_tangents(t2.col(0).xyz(), qv::normalize(qv::cross(f2_norm, t2.col(0).xyz())));
|
||||
|
||||
|
|
|
|||
|
|
@ -280,13 +280,13 @@ void FixRotateOrigin(mapentity_t *entity)
|
|||
SetKeyValue(entity, "origin", qv::to_string(offset).c_str());
|
||||
}
|
||||
|
||||
static bool DiscardHintSkipFace_Q1(const int hullnum, const hullbrush_t *hullbrush, const mtexinfo_t &texinfo)
|
||||
static bool DiscardHintSkipFace_Q1(const mtexinfo_t &texinfo)
|
||||
{
|
||||
// anything texname other than "hint" in a hint brush is treated as "hintskip", and discarded
|
||||
return !string_iequals(map.miptexTextureName(texinfo.miptex), "hint");
|
||||
}
|
||||
|
||||
static bool DiscardHintSkipFace_Q2(const int hullnum, const hullbrush_t *hullbrush, const mtexinfo_t &texinfo)
|
||||
static bool DiscardHintSkipFace_Q2(const mtexinfo_t &texinfo)
|
||||
{
|
||||
// any face in a hint brush that isn't HINT are treated as "hintskip", and discarded
|
||||
return !(texinfo.flags.native & Q2_SURF_HINT);
|
||||
|
|
@ -321,7 +321,7 @@ static face_t *CreateBrushFaces(const mapentity_t *src, hullbrush_t *hullbrush,
|
|||
/* Don't generate hintskip faces */
|
||||
const mtexinfo_t &texinfo = map.mtexinfos.at(mapface.texinfo);
|
||||
|
||||
if (DiscardHintSkipFace(hullnum, hullbrush, texinfo))
|
||||
if (DiscardHintSkipFace(texinfo))
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue