[Scummvm-cvs-logs] SF.net SVN: scummvm:[41996] scummvm/branches/gsoc2009-draci/engines/draci

Robert Špalek rspalek at gmail.com
Wed Jul 1 18:11:59 CEST 2009


On Wed, Jul 1, 2009 at 9:00 AM, <dkasak13 at users.sourceforge.net> wrote:

> Revision: 41996
>          http://scummvm.svn.sourceforge.net/scummvm/?rev=41996&view=rev
> Author:   dkasak13
> Date:     2009-07-01 16:00:27 +0000 (Wed, 01 Jul 2009)
>
> Log Message:
> -----------
> Made coordinate specification mandatory when constructing objects of type
> Sprite and Class. Made transforming from columnwise a default (since it was
> done most of the time anyway). Changed coordinates to use uint instead of
> uint16.
>
> Modified: scummvm/branches/gsoc2009-draci/engines/draci/sprite.h
> ===================================================================
> --- scummvm/branches/gsoc2009-draci/engines/draci/sprite.h      2009-07-01
> 15:22:36 UTC (rev 41995)
> +++ scummvm/branches/gsoc2009-draci/engines/draci/sprite.h      2009-07-01
> 16:00:27 UTC (rev 41996)
> @@ -43,19 +43,19 @@
>        virtual uint16 getWidth() { return _width; }
>        virtual uint16 getHeight() { return _height; }


you still have it above


>  public:
> -       Sprite(byte *raw_data, uint16 width, uint16 height, uint16 x = 0,
> uint16 y = 0,
> -               bool columnwise = false);
> +       Sprite(byte *raw_data, uint16 width, uint16 height, uint x, uint y,
> +               uint z, bool columnwise = true);
> +
>
> -       Sprite(byte *sprite_data, uint16 length, uint16 x = 0, uint16 y =
> 0,
> -               bool columnwise = false);
> +       Sprite(byte *sprite_data, uint16 length, uint x, uint y,
> +               uint z, bool columnwise = true);


and here

I suggest you to use grep to find the other occurrences.  while it may still
make sense to keep uint16 in structs to save memory, these types probably
better shouldn't occur as parameters or return values, because the CPU's
simply don't like them.  AFAIK sending/returning an int is fastest and
everything else incurs extra conversion.

-- 
Robert Špalek <rspalek at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.scummvm.org/pipermail/scummvm-git-logs/attachments/20090701/59462a06/attachment.html>


More information about the Scummvm-git-logs mailing list