summaryrefslogtreecommitdiff
path: root/src/video/sdl_v.cpp
AgeCommit message (Collapse)Author
2010-01-15(svn r18809) -Codechange/Cleanup: remove unneeded headers from some files, ↵rubidium
if a header require a header make it include that header
2010-01-13(svn r18796) -Fix [FS#3521]: [SDL] possible deadlock when killing OpenTTD ↵rubidium
while starting it
2010-01-12(svn r18790) -Revert (r18001,r18177,FS#3515): Viewport could still jump ↵peter1138
under high CPU load. Revert as change caused more problems than it fixed.
2010-01-04(svn r18709) -Fix (r10227,FS#3464): Animation buffer for 32bpp-anim blitter ↵peter1138
was only validated during sprite blitting, other drawing operations didn't check it. Initial startup and window resize could therefore lead to crash.
2009-12-19(svn r18547) -Fix [FS#3388]: missing thread synchronisation when changing ↵rubidium
the resolution for SDL via the in game menu
2009-12-19(svn r18545) -Fix [FS#3292]: Assign '_screen.dst_ptr' as soon as it is ↵frosch
allocated.
2009-12-03(svn r18390) -Fix (r17776): [SDL] Reinstate pointer update on 'idle' loop.peter1138
2009-11-18(svn r18177) -Fix (r18001): [SDL] Viewport could jump when mouse moved and ↵peter1138
right button pressed at the same time.
2009-11-09(svn r18031) -Codechange: since basically r7157 adding up 'all' mouse ↵rubidium
movement isn't needed anymore because after each even that movement is handled and the counter is reset. As such simply assigning instead of adding works.
2009-11-07(svn r18001) -Codechange: [SDL] When the mouse cursor is locked into ↵peter1138
position when scrolling a viewport, warp the mouse pointer to the centre of the window. This gives maximum freedom of movement. The pointer position is restored when the lock is removed. Visually the mouse cursor stays where it was.
2009-11-02(svn r17950) -Fix (r17776): _draw_mutex was never destroyed, _draw_thread ↵smatz
was never joined
2009-11-02(svn r17949) -Fix (r17776): unlock mutex before deleting it when creating ↵smatz
drawing thread failed
2009-10-19(svn r17815) -Fix [SDL]: asynchronious drawing caused extra unresponsiveness ↵rubidium
during map generation; disable the threading while generating a map
2009-10-15(svn r17776) -Codechange: [SDL] make "update the video card"-process ↵rubidium
asynchronious. Profiling with gprof etc. hasn't shown us that DrawSurfaceToScreen takes a significant amount of CPU; only using TIC/TOC it became apparant that it was a heavy CPU-cycle user or that it was waiting for something. The benefit of making this function asynchronious ranges from 2%-25% (real time) during fast forward on dual core/hyperthreading-enabled CPUs; 8bpp improvements are, in my test cases, significantly smaller than 32bpp improvements. On single core non-hyperthreading-enabled CPUs the extra locking/scheduling costs up to 1% extra realtime in fast forward. You can use -v sdl:no_threads to disable threading and undo this loss. During normal non-fast-forwarded games the benefit/costs are negligable except when the gameloop takes more than about 90% of the time of a tick. Note that allegro's performance does not improve with this system, likely due to their way of getting data to the video card. It is not implemented for the OS X/Windows video backends, unless (ofcourse) SDL is used there. Funny is that the performance of the 32bpp(-anim) blitter is, at least in some test cases, significantly faster (more than 10%) than the 8bpp(-optimized) blitter when looking at real time in fast forward on a dual core CPU; it was slower. The idea comes from a paper/report by Idar Borlaug and Knut Imar Hagen.
2009-08-21(svn r17248) -Fix: add GPL license notice where appropriaterubidium
2009-06-30(svn r16699) -Fix [FS#3001]: if SDL fails to allocate a surface due to it ↵rubidium
being too large (and SDL doesn't crash!) fall back to another video driver.
2009-06-27(svn r16677) -Codechange: Dimension width and height are unsigned.alberth
2009-05-06(svn r16242) -Codechange: rework pausingrubidium
-Fix [FS#2864]: autopause and manual pausing conflict with eachother -Fix: new game + pause on new game + autopause make the game not unpause on the first join
2009-01-31(svn r15299) -Cleanup: remove many redundant includessmatz
2009-01-23(svn r15233) -Fix (r15231): compilation with SDL broken on win32glx
2009-01-23(svn r15232) -Codechange: sprinklin' of coding stylerubidium
2009-01-23(svn r15231) -Change: (sdl) check the full screen resolutions to determine ↵rubidium
what 'valid' resolutions we've got
2008-11-29(svn r14641) -Change [Allegro]: when making a debug build revert Allegro's ↵rubidium
hooks on SIGSEGV/SIGABRT so one can actually use gdb. -Change: make it more clear that Allegro's failing to find a driver.
2008-09-07(svn r14260) -Fix [FS#2277]: merge keycode for "normal" 0-9 keys and keypad ↵rubidium
0-9 keys so people don't get confused that the keypad doesn't work as expected.
2008-08-11(svn r14047) -Codechange: move chatmessage handling to the network directory ↵rubidium
as that's the only case chat messages are used. Furthermore remove any trace of chatmessages when compiling without network support.
2008-06-16(svn r13537) -Fix [FS#2090](r13523): QSortT won't work this way, use ↵smatz
Dimension instead of uint16[2] for resolutions
2008-06-05(svn r13390) -Codechange: introduce usererror() for fatal but not openttd ↵glx
related errors. Now all error() will 'crash' openttd after showing the message in win32 releases (MSVC), creating a crash.log and crash.dmp (like the '!' hack used before). On the other hand, usererror() will just close the game. So use error() only when it can be helpful to debugging, else use usererror().
2008-05-06(svn r12977) -Codechange: remove quite some redundant (duplicate) function ↵rubidium
declarations.
2008-05-06(svn r12971) -Documentation: add @file in files that missed them and add ↵rubidium
something more than whitespace as description of files that don't have a description.
2008-05-04(svn r12944) -Codechange: use rev.h instead of externs at many placessmatz
2008-04-18(svn r12779) -Codechange: remove a few constants from openttd.h.rubidium
2008-02-17(svn r12167) -Feature(tte): change colour of autorail and autoroad selection ↵smatz
when Ctrl is pressed
2008-01-29(svn r12003) -Codechange: don't declare InteractiveRandom[Range] in multiple ↵rubidium
places.
2008-01-11(svn r11811) -Fix: make compilation without networking work again (and thus ↵rubidium
move the debugdumpcommand stuff out of the network 'area').
2008-01-01(svn r11734) -Change: Allow ToggleFullScreen to return the result of the ↵belugas
operation' attempt. Previously, only visual clues were available. -Fix[FS#1519]: When you can not use this resolution at full screen, now you'll know that it failed. As for the reason it did not work, each computer/OS has its reason.
2007-12-25(svn r11692) -Codechange: move some functions from 'functions.h' to a more ↵rubidium
logical place and remove about 50% of the includes of 'functions.h'
2007-12-23(svn r11684) -Codechange: split gfx.h in a type and functional header.rubidium
2007-12-22(svn r11682) -Codechange: move some 'generic' geometry related types into a ↵rubidium
single file and do not include gfx.h everywhere to get a Point type.
2007-12-21(svn r11674) -Codechange: refactor some functions out of macros.h into more ↵rubidium
logical locations.
2007-12-19(svn r11667) -Codechange: split window.h into a header that defines some ↵rubidium
'global' window related types, on that defined 'global' window functions and one that defines functions and types only used by *_gui.cpps.
2007-11-24(svn r11510) -Codechange: merge the IS_*INSIDE* functions and rename them ↵skidd13
fitting to the naming style
2007-11-19(svn r11475) -Codechange: rename clamp and clampu to Clamp and ClampU to fit ↵skidd13
with the coding style
2007-08-19(svn r10932) -Codechange: replace "text" with "chat" for the chat related ↵rubidium
function and variables.
2007-07-23(svn r10663) -Fix r10662: bad me, didn't comply with coding style, as ↵truelight
penalty I updated the surrounding code to comply with coding style too; I will never do it again (I hope :p)
2007-07-23(svn r10662) -Add: added 'V' as new shortcut for new viewport (bilbo)truelight
-Add: added 'M' as new shortcut for smallmap (bilbo) -Add: added '+' and '-' as shortcuts to zoom in the mainview (bilbo) -Add: added support for other keycodes to be possible used in the future (bilbo)
2007-07-05(svn r10444) -Codechange: switch to c++ classes and inheritance for ↵peter1138
sound/music/video drivers, using self-registration based on the blitter-model.
2007-06-22(svn r10278) -Fix r10276: make the _realtime_tick less demanding on the CPUtruelight
2007-06-22(svn r10276) -Codechange: made a counter based on milliseconds and ↵truelight
independent of the game-state to base double-click and TGP Generation Process on -Codechange: renamed _timer_counter to _palette_animation_counter, as that is what it is
2007-06-21(svn r10255) -Codechange: remove some old debug code nobody was using anymoretruelight
2007-06-19(svn r10217) -Fix r10216: forgot to declare 'blitter' in win32 and cocoa ↵truelight
driver (tnx glx)