Zorba the Hutt (zorbathut) wrote,
Zorba the Hutt
zorbathut

  • Mood:
edges[ 2 ] = edges[ 0 ];
for( int i = 0; i < edges[ 2 ].size(); i++ )
    edges[ 2 ][ i ].second = height - edges[ 2 ][ i ].second - 1;

for( int j = 0; j < 2; j++ ) {
    edges[ 4 + j * 2 ] = edges[ j * 2 ];
    for( int i = 0; i < edges[ 4 + j * 2 ].size(); i++ )
        edges[ 4 + j * 2 ][ i ].second = height - edges[ 4 + j * 2 ][ i ].second - 1;
};

for( int j = 0; j < 4; j++ ) {
    edges[ 1 + j * 2 ] = edges[ j * 2 ];
    for( int i = 0; i < edges[ 1 + j * 2 ].size(); i++ )
        swap( edges[ 1 + j * 2 ][ i ].first, edges[ 1 + j * 2 ][ i ].second );
};

and here I thought that MAYBE I COULD FINALLY STOP WRITING ROTATION/MIRRORING CODE

(it never ends!)
Subscribe
  • Post a new comment

    Error

    default userpic

    Your IP address will be recorded 

    When you submit the form an invisible reCAPTCHA check will be performed.
    You must follow the Privacy Policy and Google Terms of use.
  • 1 comment