#define EXTRA_NAME "@cornermirror."#include "loadbmp.h"
void CornerMirror(){int x,y;BYTE *lpTemp=new BYTE[nByteWidth*nHeight];for(y=0;y<nHeight;y++){for(x=0;x<nWidth;x++){lpTemp[x*3+y*nByteWidth]=lpBits[(nWidth-1-x)*3+(nHeight-y-1)*nByteWidth];lpTemp[x*3+1+y*nByteWidth]=lpBits[(nWidth-1-x)*3+1+(nHeight-y-1)*nByteWidth];lpTemp[x*3+2+y*nByteWidth]=lpBits[(nWidth-1-x)*3+2+(nHeight-y-1)*nByteWidth];}}lpBits=lpTemp;}
void main(int argc, char *argv[]){if(argc==2)FileName=argv[1];elsereturn;OpenFile();CornerMirror();SaveAs();}
void CornerMirror(){int x,y;BYTE *lpTemp=new BYTE[nByteWidth*nHeight];for(y=0;y<nHeight;y++){for(x=0;x<nWidth;x++){lpTemp[x*3+y*nByteWidth]=lpBits[(nWidth-1-x)*3+(nHeight-y-1)*nByteWidth];lpTemp[x*3+1+y*nByteWidth]=lpBits[(nWidth-1-x)*3+1+(nHeight-y-1)*nByteWidth];lpTemp[x*3+2+y*nByteWidth]=lpBits[(nWidth-1-x)*3+2+(nHeight-y-1)*nByteWidth];}}lpBits=lpTemp;}
void main(int argc, char *argv[]){if(argc==2)FileName=argv[1];elsereturn;OpenFile();CornerMirror();SaveAs();}