Sponsored Content
Full Discussion: FrameRate en Allegro
Top Forums Programming FrameRate en Allegro Post 302369210 by LoboOscuro on Friday 6th of November 2009 10:56:57 PM
Old 11-06-2009
Question FrameRate en Allegro

Hola, en windows no tengo este problema, pero estoy programando en linux y aca no se como hacer que no vaya tan rapido la velocidad de refresco, estoy tratando de poner a 60Hz como hacia en windows con request_refresh_rate(60); y vsync();, pero estas funciones no sirven en linux, ni en ventanas ni a pantalla completa.
pienso que puede ser por la configuracion que ya tiene linux en el entorno grafico, pero solo puedo cambiar su resolucion y profundidad cuando pongo a pantalla completa, pero no la velocidad de refresco (esto no se si afecta), pero vsync() no me lo toma para nada.
alguien tiene alguna idea de como solucionarlo? agradezco cualquier ayuda.

PD: Puede que me haya equivocado de topic, pero entre tanto ingles no entiendo nada.
 
get_desktop_resolution(3alleg4) 				  Allegro manual				   get_desktop_resolution(3alleg4)

NAME
get_desktop_resolution - Finds out the desktop resolution. Allegro game programming library. SYNOPSIS
#include <allegro.h> int get_desktop_resolution(int *width, int *height); DESCRIPTION
Finds out the currently selected desktop resolution. You can use this information to avoid creating windows bigger than the current resolu- tion. This is especially important for some windowed drivers which are unable to create windows bigger than the desktop. Each parameter is a pointer to an integer where one dimension of the screen will be stored. Under some OSes, switching to a full screen graphics mode may automatically change the desktop resolution. You have, therefore, to call this function before setting any graphics mode in order to retrieve the real desktop resolution. Example: int width, height; allegro_init(); ... if (get_desktop_resolution(&width, &height) == 0) { /* Got the resolution correctly */ } RETURN VALUE
Returns zero on success, or a negative number if this information is not available or does not apply, in which case the values stored in the variables you provided for `width' and `height' are undefined. SEE ALSO
desktop_color_depth(3alleg4), set_gfx_mode(3alleg4) Allegro version 4.4.2 get_desktop_resolution(3alleg4)
All times are GMT -4. The time now is 03:09 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy