diff options
| author | Sven Hesse | 2012-07-30 01:50:39 +0200 | 
|---|---|---|
| committer | Sven Hesse | 2012-07-30 01:50:59 +0200 | 
| commit | d80d08128b2a030a65ce4f48776f5c63370ac598 (patch) | |
| tree | 8e219014f2ccde916ae8ce5a32754026b3ff0e98 /engines/gob/surface.cpp | |
| parent | e8fd51e56b9eb4eecd09711757b2d851d5bafafc (diff) | |
| parent | b001168658f57b845bae81df0ca85240c796e74e (diff) | |
| download | scummvm-rg350-d80d08128b2a030a65ce4f48776f5c63370ac598.tar.gz scummvm-rg350-d80d08128b2a030a65ce4f48776f5c63370ac598.tar.bz2 scummvm-rg350-d80d08128b2a030a65ce4f48776f5c63370ac598.zip  | |
Merge branch 'pregob' (WIP Once Upon A Time)
This is some in-progress work for supporting the mostly hard-coded
Once Upon A Time titles Abracadabra and Baba Yaga.
Diffstat (limited to 'engines/gob/surface.cpp')
| -rw-r--r-- | engines/gob/surface.cpp | 6 | 
1 files changed, 6 insertions, 0 deletions
diff --git a/engines/gob/surface.cpp b/engines/gob/surface.cpp index 3eaf741be2..afbb7c3bae 100644 --- a/engines/gob/surface.cpp +++ b/engines/gob/surface.cpp @@ -684,6 +684,12 @@ void Surface::shadeRect(uint16 left, uint16 top, uint16 right, uint16 bottom,  } +void Surface::recolor(uint8 from, uint8 to) { +	for (Pixel p = get(); p.isValid(); ++p) +		if (p.get() == from) +			p.set(to); +} +  void Surface::putPixel(uint16 x, uint16 y, uint32 color) {  	if ((x >= _width) || (y >= _height))  		return;  | 
