Remove unnecessary linking hack, compilation works fine without.
[mplayer/glamo.git] / libvo / aspecttest.c
blob9beebcf7662d36ceb83aacfa76e39cf33330ff88
1 /*
2 * test app for aspect.[ch] by Atmos
4 * This file is part of MPlayer.
6 * MPlayer is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * MPlayer is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License along
17 * with MPlayer; if not, write to the Free Software Foundation, Inc.,
18 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
21 #include <stdio.h>
22 #include <stdlib.h>
24 #include "aspect.h"
26 /* default zoom state 0 off, 1 on */
27 #define DEF_ZOOM 1
29 extern float monitor_aspect;
30 int vo_fs;
31 float vo_panscan;
33 int main(int argc, char *argv[]) {
34 int w,h,z=DEF_ZOOM;
35 //printf("argc: %d\n",argc);
36 switch(argc) {
37 case 10:
38 z = atoi(argv[9]);
39 case 9:
40 monitor_aspect = (float)atoi(argv[7])/(float)atoi(argv[8]);
41 case 7:
42 aspect_save_prescale(atoi(argv[5]),atoi(argv[6]));
43 printf("prescale size: %sx%s\n",argv[5],argv[6]);
44 case 5:
45 aspect_save_screenres(atoi(argv[1]),atoi(argv[2]));
46 printf("screenres: %sx%s\n",argv[1],argv[2]);
47 aspect_save_orig(atoi(argv[3]),atoi(argv[4]));
48 printf("original size: %sx%s\n",argv[3],argv[4]);
49 w=atoi(argv[3]); h=atoi(argv[4]);
50 break;
51 default:
52 printf("USAGE: %s <screenw> <screenh> <origw> <origh>\n[<prescalew> "
53 "<prescaleh>] [<screenaspectw> <screenaspecth>] [<zoom 0/1>]\n",
54 argv[0]);
55 return 1;
57 printf("monitor_aspect: %f\n",monitor_aspect);
58 aspect(&w,&h,z);
59 printf("new size: %dx%d\n",w,h);
60 return 0;