rename TEXDEFTYPEID_HALFLIFE -> TEXDEFTYPEID_VALVE for consistency
This commit is contained in:
parent
944f490a65
commit
62a5122ff8
|
|
@ -893,7 +893,7 @@ inline TexdefTypeId BrushType_getTexdefType( EBrushType type ){
|
||||||
return TEXDEFTYPEID_BRUSHPRIMITIVES;
|
return TEXDEFTYPEID_BRUSHPRIMITIVES;
|
||||||
case eBrushTypeValve220:
|
case eBrushTypeValve220:
|
||||||
case eBrushTypeQuake3Valve220:
|
case eBrushTypeQuake3Valve220:
|
||||||
return TEXDEFTYPEID_HALFLIFE;
|
return TEXDEFTYPEID_VALVE;
|
||||||
default:
|
default:
|
||||||
return TEXDEFTYPEID_QUAKE;
|
return TEXDEFTYPEID_QUAKE;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -241,7 +241,7 @@ void Texdef_basisForNormal( const TextureProjection& projection, const Vector3&
|
||||||
matrix4_transpose( basis );
|
matrix4_transpose( basis );
|
||||||
//DebugAxisBase( normal );
|
//DebugAxisBase( normal );
|
||||||
}
|
}
|
||||||
else if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_HALFLIFE ) {
|
else if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_VALVE ) {
|
||||||
basis = g_matrix4_identity;
|
basis = g_matrix4_identity;
|
||||||
vector4_to_vector3( basis.x() ) = projection.m_basis_s;
|
vector4_to_vector3( basis.x() ) = projection.m_basis_s;
|
||||||
vector4_to_vector3( basis.y() ) = vector3_negated( projection.m_basis_t );
|
vector4_to_vector3( basis.y() ) = vector3_negated( projection.m_basis_t );
|
||||||
|
|
@ -1191,7 +1191,7 @@ void Texdef_Assign( TextureProjection& projection, const TextureProjection& othe
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Texdef_Assign( projection.m_texdef, other.m_texdef );
|
Texdef_Assign( projection.m_texdef, other.m_texdef );
|
||||||
if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_HALFLIFE ) {
|
if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_VALVE ) {
|
||||||
projection.m_basis_s = other.m_basis_s;
|
projection.m_basis_s = other.m_basis_s;
|
||||||
projection.m_basis_t = other.m_basis_t;
|
projection.m_basis_t = other.m_basis_t;
|
||||||
}
|
}
|
||||||
|
|
@ -1204,7 +1204,7 @@ void Texdef_Assign( TextureProjection& projection, const float* hShift, const fl
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ( rotation && g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_HALFLIFE ) {
|
if ( rotation && g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_VALVE ) {
|
||||||
Valve220_rotate( projection, *rotation - projection.m_texdef.rotate );
|
Valve220_rotate( projection, *rotation - projection.m_texdef.rotate );
|
||||||
}
|
}
|
||||||
Texdef_Assign( projection.m_texdef, hShift, vShift, hScale, vScale, rotation );
|
Texdef_Assign( projection.m_texdef, hShift, vShift, hScale, vScale, rotation );
|
||||||
|
|
@ -1237,7 +1237,7 @@ void Texdef_Rotate( TextureProjection& projection, float angle ){
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_HALFLIFE ) {
|
if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_VALVE ) {
|
||||||
Valve220_rotate( projection, angle );
|
Valve220_rotate( projection, angle );
|
||||||
}
|
}
|
||||||
Texdef_Rotate( projection.m_texdef, angle );
|
Texdef_Rotate( projection.m_texdef, angle );
|
||||||
|
|
@ -1482,7 +1482,7 @@ void Texdef_transformLocked_original( TextureProjection& projection, std::size_t
|
||||||
Texdef_basisForNormal( projection, plane.normal(), identity2stIdentity );
|
Texdef_basisForNormal( projection, plane.normal(), identity2stIdentity );
|
||||||
//globalOutputStream() << "identity2stIdentity: " << identity2stIdentity << "\n";
|
//globalOutputStream() << "identity2stIdentity: " << identity2stIdentity << "\n";
|
||||||
|
|
||||||
if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_HALFLIFE ) {
|
if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_VALVE ) {
|
||||||
matrix4_transform_direction( maa, projection.m_basis_s );
|
matrix4_transform_direction( maa, projection.m_basis_s );
|
||||||
matrix4_transform_direction( maa, projection.m_basis_t );
|
matrix4_transform_direction( maa, projection.m_basis_t );
|
||||||
}
|
}
|
||||||
|
|
@ -1769,7 +1769,7 @@ void Texdef_transformLocked( TextureProjection& projection, std::size_t width, s
|
||||||
Texdef_normalise( projection, (float)width, (float)height );
|
Texdef_normalise( projection, (float)width, (float)height );
|
||||||
// globalOutputStream() << "AP new: scale( " << projection.m_texdef.scale[0] << " " << projection.m_texdef.scale[1] << " ) shift( " << projection.m_texdef.shift[0] << " " << projection.m_texdef.shift[1] << " ) rotate: " << projection.m_texdef.rotate << "\n";
|
// globalOutputStream() << "AP new: scale( " << projection.m_texdef.scale[0] << " " << projection.m_texdef.scale[1] << " ) shift( " << projection.m_texdef.shift[0] << " " << projection.m_texdef.shift[1] << " ) rotate: " << projection.m_texdef.rotate << "\n";
|
||||||
}
|
}
|
||||||
else{ //TEXDEFTYPEID_HALFLIFE
|
else{ //TEXDEFTYPEID_VALVE
|
||||||
// globalOutputStream() << "AP: scale( " << projection.m_texdef.scale[0] << " " << projection.m_texdef.scale[1] << " ) shift( " << projection.m_texdef.shift[0] << " " << projection.m_texdef.shift[1] << " ) rotate: " << projection.m_texdef.rotate << "\n";
|
// globalOutputStream() << "AP: scale( " << projection.m_texdef.scale[0] << " " << projection.m_texdef.scale[1] << " ) shift( " << projection.m_texdef.shift[0] << " " << projection.m_texdef.shift[1] << " ) rotate: " << projection.m_texdef.rotate << "\n";
|
||||||
// globalOutputStream() << "220: projection.m_basis_s: " << projection.m_basis_s << " projection.m_basis_t: " << projection.m_basis_t << "\n";
|
// globalOutputStream() << "220: projection.m_basis_s: " << projection.m_basis_s << " projection.m_basis_t: " << projection.m_basis_t << "\n";
|
||||||
//globalOutputStream() << "identity2transformed: " << identity2transformed << "\n";
|
//globalOutputStream() << "identity2transformed: " << identity2transformed << "\n";
|
||||||
|
|
@ -1912,7 +1912,7 @@ void Texdef_ProjectTexture( TextureProjection& projection, std::size_t width, st
|
||||||
Texdef_Construct_local2tex4projection( texdef, width, height, plane.normal(), direction, local2tex );
|
Texdef_Construct_local2tex4projection( texdef, width, height, plane.normal(), direction, local2tex );
|
||||||
BPTexdef_fromST011( projection, plane, local2tex );
|
BPTexdef_fromST011( projection, plane, local2tex );
|
||||||
}
|
}
|
||||||
else if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_HALFLIFE ) {
|
else if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_VALVE ) {
|
||||||
Texdef_Assign( projection.m_texdef, texdef );
|
Texdef_Assign( projection.m_texdef, texdef );
|
||||||
if( direction ){ //arbitrary
|
if( direction ){ //arbitrary
|
||||||
ComputeAxisBase( *direction, projection.m_basis_s, projection.m_basis_t );
|
ComputeAxisBase( *direction, projection.m_basis_s, projection.m_basis_t );
|
||||||
|
|
@ -1937,7 +1937,7 @@ void Texdef_ProjectTexture( TextureProjection& projection, std::size_t width, st
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Texdef_Assign( projection.m_texdef, other_proj.m_texdef );
|
Texdef_Assign( projection.m_texdef, other_proj.m_texdef );
|
||||||
if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_HALFLIFE ) {
|
if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_VALVE ) {
|
||||||
projection.m_basis_s = other_proj.m_basis_s;
|
projection.m_basis_s = other_proj.m_basis_s;
|
||||||
projection.m_basis_t = other_proj.m_basis_t;
|
projection.m_basis_t = other_proj.m_basis_t;
|
||||||
}
|
}
|
||||||
|
|
@ -1960,7 +1960,7 @@ void Texdef_Convert( TexdefTypeId in, TexdefTypeId out, const Plane3& plane, Tex
|
||||||
BPTexdef_normalise( projection.m_brushprimit_texdef, (float)width, (float)height );
|
BPTexdef_normalise( projection.m_brushprimit_texdef, (float)width, (float)height );
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case TEXDEFTYPEID_HALFLIFE:
|
case TEXDEFTYPEID_VALVE:
|
||||||
if( in == TEXDEFTYPEID_QUAKE ) {
|
if( in == TEXDEFTYPEID_QUAKE ) {
|
||||||
Matrix4 basis;
|
Matrix4 basis;
|
||||||
Normal_GetTransform( plane.normal(), basis );
|
Normal_GetTransform( plane.normal(), basis );
|
||||||
|
|
|
||||||
|
|
@ -123,7 +123,7 @@ enum TexdefTypeId
|
||||||
{
|
{
|
||||||
TEXDEFTYPEID_QUAKE,
|
TEXDEFTYPEID_QUAKE,
|
||||||
TEXDEFTYPEID_BRUSHPRIMITIVES,
|
TEXDEFTYPEID_BRUSHPRIMITIVES,
|
||||||
TEXDEFTYPEID_HALFLIFE,
|
TEXDEFTYPEID_VALVE,
|
||||||
};
|
};
|
||||||
|
|
||||||
struct bp_globals_t
|
struct bp_globals_t
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user