|Reported by:||eriktorbjorn||Owned by:||SF/ender|
|Cc:||Game:||Sam and Max|
This is an attempt at rewriting drawBomp() so that it handles scaling (needed for the highway surfing in Sam & Max) and blending (needed for the inventory and command menus in The Dig).
The scaling algorithm is pretty stupid, but as long as it's only used for things that go by pretty quickly, it should be good enough. The blending will need some tuning since all I have to compare it to is the stamp-sized screenshot in the Dig manual.
Unlike the current version of drawBomp(), this version assumes it always has to take scaling, clipping, etc. into consideration, so it's slower. Maybe noticeably so. But I don't want to add optimizations of questionable worth until I'm pretty sure the basics are working correctly.
A more noticeable optimization would probably be if it could be taught to only redraw the dirty areas of the screen. For instance, when looking at the inventory in The Dig it appears the entire inventory window is redrawn every scummLoop iteration. Without a blend cache this would be painfully slow.
(Speaking of which, with this patch drawBlastObject() probably dirties too much of the screen in the scaled case. How come drawBomp() isn't the one responsible for calling updateDirtyRect()?)
Ticket imported from: #609563. Ticket imported from: patches/154.