C / graphics.h / setaspectratio
arc, bar, bar3d, circle, cleardevice, clearviewport, closegraph, detectgraph, drawpoly, ellipse, fillellipse, fillpoly, floodfill, getarccoords, getaspectratio, getbkcolor, getcolor, getdefaultpalette, getdrivername, getfillpattern, getfillsettings, getgraphmode, getimage, getlinesettings, getmaxcolor, getmaxmode, getmaxx, getmaxy, getmodename, getmoderange, getpalette, getpalettesize, getpixel, gettextsettings, getviewsettings, getx, gety, graphdefaults, grapherrormsg, _graphfreemem, _graphgetmem, graphresult, imagesize, initgraph, installuserdriver, installuserfont, line, linerel, lineto, moverel, moveto, outtext, outtextxy, pieslice, putimage, putpixel, rectangle, registerbgidriver, registerbgifont, restorecrtmode, sector, setactivepage, setallpalette, » setaspectratio, setbkcolor, setfillpattern, setfillstyle, setgraphbufsize, setgraphmode, setlinestyle, setpalette, setrgbpalette, settextjustify, settextstyle, setusercharsize, setviewport, setvisualpage, setwritemode, textheight, textwidth,
Funcion: setaspectratio()
Sintaxis:
void far setaspectratio(int x_proporcion, int y_proporcion);

Descripcion: Esta función es usada para modificar la proporción anchura-altura del modo gráfico actual. La proporción anchura-altura puede definirse como la proporción de la anchura del píxel del modo gráfico y la altura del píxel. Esta proporción es usada por el sistema gráfico para calcular círculos y arcos. Por ello, alterando la proporción anchura-altura afectará la visualización de estas funciones. La función getaspectratio puede ser usada para obtener las opciones por defecto del modo actual anteriormente a ser modificados.


Ejemplo:
#include <graphics.h>
#include <conio.h>
 
int main() {
   int gdriver = EGA;
   int gmodo = EGAHI;
   int x_proporcion, y_proporcion;
 
/* Si has registrado los dispositivos para que formen parte de graphics.lib
** entonces usa estas sentencias:
 
   registerbgidriver( EGAVGA_driver );
   initgraph( &gdriver, &gmodo, "" );
*/
 
/* Si no, entonces has de "decir" d&oacute;nde se encuentra el dispositivo gr&aacute;fico */
 
   initgraph( &gdriver, &gmodo, "C:\\BC5\\BGI" );
 
   getaspectratio( &x_proporcion, &y_proporcion );
 
   circle( 300, 150, 50 );
   getch();    /* Pausa */
 
   setaspectratio( 2*x_proporcion, y_proporcion );
   circle( 300, 150, 50 );
 
   getch();    /* Pausa */
   closegraph();
 
   return 0;
}

Librerias C

Librerias ANSI C
   string.hcstring
   math.hcmath
   stdio.hcstdio
   time.hctime
   stdlib.hcstdlib
   ctype.hcctype
   locale.hclocale
   signal.hcsignal
   setjmp.hcsetjmp

Librerias Borland
   conio.h
   graphics.h