Hi guys,
This is the definition for SDL_FULLSCREEN :
SDL will attempt to use a fullscreen mode. If a hardware resolution change
is not possible (for whatever reason), the next higher resolution will be
used and the display window centered on a black background. http://sdl.beuc.net/sdl.wiki/SDL_SetVideoMode
I use SDL on a Debian machine. this machine works on 800x600 resolution
very well but when i run my SDL program, it creates a full screen window
that my 800x600 program is 3/4 of the screen and another areas are black.
what’s the solution for this problem? by the way i have tried another video
mode like :
SDL_SWSURFACE
Create the video surface in system memory
SDL_HWSURFACE
Create the video surface in video memory
SDL_ASYNCBLIT
Enables the use of asynchronous updates of the display surface. This will
usually slow down blitting on single CPU machines, but may provide a speed
increase on SMP systems.
SDL_ANYFORMAT
Normally, if a video surface of the requested bits-per-pixel (bpp) is not
available, SDL will emulate one with a shadow surface. Passing
SDL_ANYFORMAT prevents
this and causes SDL to use the video surface, regardless of its pixel depth.
but they all have the same result.
thanks.
-------------- next part --------------
A non-text attachment was scrubbed…
Name: mm
Type: application/octet-stream
Size: 4559 bytes
Desc: not available
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20120612/e2938b4b/attachment.obj
SDL will attempt to use a fullscreen mode. If a hardware resolution change
is not possible (for whatever reason), the next higher resolution will be
used and the display window centered on a black background. http://sdl.beuc.net/sdl.wiki/SDL_SetVideoMode
I use SDL on a Debian machine. this machine works on 800x600 resolution
very well but when i run my SDL program, it creates a full screen window
that my 800x600 program is 3/4 of the screen and another areas are black.
what’s the solution for this problem?
Did you try some of the official
SDL examples like testsprite to
make sure it is not a problem in your code ?
Compile testsprite.c in the test directory and execute
it with your wanted flags, for width and height and fullscreen,
to see if it shows the same problem as your code.
You do not need to change testsprite in any way, it provides nice
commandline options.
Hi guys,
This is the definition for SDL_FULLSCREEN :
SDL will attempt to use a fullscreen mode. If a hardware resolution change
is not possible (for whatever reason), the next higher resolution will be
used and the display window centered on a black background. http://sdl.beuc.net/sdl.wiki/SDL_SetVideoMode
I use SDL on a Debian machine. this machine works on 800x600 resolution
very well but when i run my SDL program, it creates a full screen window
that my 800x600 program is 3/4 of the screen and another areas are black.
what’s the solution for this problem? by the way i have tried another video
mode like :
What numbers are you passing into SDL_SetVideoMode?
If the screen doesn’t support 800x600, then there is no simple
solution. One solution is to make your program support more video
modes. This will be lots of extra effort and you probably will find
that you can’t support every possible resolution. The other solution
is that if your desired resolution isn’t supported, render to an
off-screen buffer and then stretch (or shrink!) it into place. This
could be slow and result in significant artifacts depending on your
art style.
SDL’s documented behaviour is the simplest way for your program to
"just work" on a wide variety of resolutions, including those that
aren’t in commercial consumer hardware yet.>> I use SDL on a Debian machine. this machine works on 800x600 resolution
very well but when i run my SDL program, it creates a full screen window
that my 800x600 program is 3/4 of the screen and another areas are black.
what’s the solution for this problem?
It seems like your monitor does not support 800x600 (SDL_ListModes() is one
way to see that if you don’t have a tool already). Some programs (like
your window/desktop manager) can easily stretch or adapt to any resolution,
but SDL won’t do magic for you.
If you’re willing to add an OpenGL dependency, you can try SDL_gpu ( http://code.google.com/p/sdl-gpu). SDL_gpu has a virtual resolution
feature so you can write your program in 800x600 but scale it automatically
to any resolution, like whatever your monitor has natively.
with all flags it says:
Couldn’t set 640x480 video mode: Couldn’t set console screen info
and after changing width and height :
Couldn’t set 800x600 video mode: Couldn’t set console screen infoOn Tue, Jun 12, 2012 at 5:25 PM, Torsten Giebl wrote:
Hello !
This is the definition for SDL_FULLSCREEN :
SDL will attempt to use a fullscreen mode. If a hardware resolution
change
is not possible (for whatever reason), the next higher resolution will be
used and the display window centered on a black background. http://sdl.beuc.net/sdl.wiki/SDL_SetVideoMode
I use SDL on a Debian machine. this machine works on 800x600 resolution
very well but when i run my SDL program, it creates a full screen window
that my 800x600 program is 3/4 of the screen and another areas are black.
what’s the solution for this problem?
Did you try some of the official
SDL examples like testsprite to
make sure it is not a problem in your code ?
Compile testsprite.c in the test directory and execute
it with your wanted flags, for width and height and fullscreen,
to see if it shows the same problem as your code.
You do not need to change testsprite in any way, it provides nice
commandline options.
SDL_SetVideoMode(800,600,32,SDL_FULLSCREEN);
SDL_SetVideoMode(800,600,32,SDL_HWSURFACE);
SDL_SetVideoMode(800,600,32,SDL_SWSURFACE);On Tue, Jun 12, 2012 at 5:24 PM, Gordon Henderson <gordon+sdl at drogon.net>wrote:
I use SDL on a Debian machine. this machine works on 800x600 resolution
very well but when i run my SDL program, it creates a full screen window
that my 800x600 program is 3/4 of the screen and another areas are black.
what’s the solution for this problem? by the way i have tried another
video
mode like :
What numbers are you passing into SDL_SetVideoMode?
I can change resolution in Monitor Preferences settings to this resolution :
1024x768
800x600
640x480
720x400
but SDL have problem!On Tue, Jun 12, 2012 at 5:48 PM, Brian Barrett <brian.ripoff at gmail.com>wrote:
If the screen doesn’t support 800x600, then there is no simple
solution. One solution is to make your program support more video
modes. This will be lots of extra effort and you probably will find
that you can’t support every possible resolution. The other solution
is that if your desired resolution isn’t supported, render to an
off-screen buffer and then stretch (or shrink!) it into place. This
could be slow and result in significant artifacts depending on your
art style.
SDL’s documented behaviour is the simplest way for your program to
"just work" on a wide variety of resolutions, including those that
aren’t in commercial consumer hardware yet.
I use SDL on a Debian machine. this machine works on 800x600 resolution
very well but when i run my SDL program, it creates a full screen window
that my 800x600 program is 3/4 of the screen and another areas are
black.
It seems like your monitor does not support 800x600 (SDL_ListModes() is
one way to see that if you don’t have a tool already). Some programs (like
your window/desktop manager) can easily stretch or adapt to any resolution,
but SDL won’t do magic for you.
If you’re willing to add an OpenGL dependency, you can try SDL_gpu ( http://code.google.com/p/sdl-gpu). SDL_gpu has a virtual resolution
feature so you can write your program in 800x600 but scale it automatically
to any resolution, like whatever your monitor has natively.
with all flags it says:
Couldn’t set 640x480 video mode: Couldn’t set console screen info
and after changing width and height :
Couldn’t set 800x600 video mode: Couldn’t set console screen info
So you tried the testsprite example and these were the results ?
If not, please try it.
Can you give use some infos about your machine ?
Which OS, if Linux, which distribution, which GFX driver ( ATI, INTEL, NVIDIA, … ), …
Embedded Intel? Atom? N455 Single Core/ D525 Dual Core processor +
ICH8M, DDR3 memory support
Intel Gen 3.5 DX9, MPEG2 Decode in HW, multiple display: 18/24-bit
LVDS, VGA or 1080P HDMI
Supports 12V input power for PCM-9363, easy for power integration
2 Intel GbE support, Rich I/O interface with 3COM, 2 SATA, 6 USB and
GPIO
Supports embedded software APIs and Utilities
Supports embedded OS: Windows CE 6.0 , Windows XP Embedded, WES 7,
Linux, QNX, VxWorks-
On Wed, Jun 13, 2012 at 2:30 PM, Torsten Giebl wrote:
Hello !
with all flags it says:
Couldn’t set 640x480 video mode: Couldn’t set console screen info
and after changing width and height :
Couldn’t set 800x600 video mode: Couldn’t set console screen info
So you tried the testsprite example and these were the results ?
If not, please try it.
Can you give use some infos about your machine ?
Which OS, if Linux, which distribution, which GFX driver ( ATI, INTEL,
NVIDIA, … ), …