]> git.xonotic.org Git - xonotic/netradiant.git/blobdiff - radiant/brush.h
Q3map2:
[xonotic/netradiant.git] / radiant / brush.h
index 0fb6ffe225c2b0d3dbe45d0a8b3d5fb08a07079f..5504f954a5531a76005f844128e457a8e424e414 100644 (file)
@@ -598,6 +598,14 @@ void fit( const Vector3& normal, const Winding& winding, float s_repeat, float t
        Texdef_FitTexture( m_projection, m_shader.width(), m_shader.height(), normal, winding, s_repeat, t_repeat );
 }
 
+void fitW( const Vector3& normal, const Winding& winding, float s_repeat, float t_repeat ){
+       Texdef_FitTextureW( m_projection, m_shader.width(), m_shader.height(), normal, winding, s_repeat, t_repeat );
+}
+
+void fitH( const Vector3& normal, const Winding& winding, float s_repeat, float t_repeat ){
+       Texdef_FitTextureH( m_projection, m_shader.width(), m_shader.height(), normal, winding, s_repeat, t_repeat );
+}
+
 void emitTextureCoordinates( Winding& winding, const Vector3& normal, const Matrix4& localToWorld ){
        Texdef_EmitTextureCoordinates( m_projection, m_shader.width(), m_shader.height(), winding, normal, localToWorld );
 }
@@ -1199,6 +1207,18 @@ void FitTexture( float s_repeat, float t_repeat ){
        texdefChanged();
 }
 
+void FitTextureW( float s_repeat, float t_repeat ){
+       undoSave();
+       m_texdef.fitW( m_plane.plane3().normal(), m_winding, s_repeat, t_repeat );
+       texdefChanged();
+}
+
+void FitTextureH( float s_repeat, float t_repeat ){
+       undoSave();
+       m_texdef.fitH( m_plane.plane3().normal(), m_winding, s_repeat, t_repeat );
+       texdefChanged();
+}
+
 void EmitTextureCoordinates(){
        Texdef_EmitTextureCoordinates( m_texdefTransformed, m_shader.width(), m_shader.height(), m_winding, plane3().normal(), g_matrix4_identity );
 }