Ignore:
Timestamp:
05/22/15 13:21:44 (10 years ago)
Author:
epyon
Message:
  • removed all std headers (except cassert) from common.hh
  • sized int types in common.hh with static_assert checks
  • char8 -> uchar8/schar8 and 16/32
  • omitted core->stl includes fixed
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lua/lua_map_tile.cc

    r368 r369  
    2020struct map_tile
    2121{
    22         nv::uint8* data;
    23         nv::char8* ascii;
    24         nv::uint16 size_x;
    25         nv::uint16 size_y;
     22        nv::uint8*  data;
     23        nv::uchar8* ascii;
     24        nv::uint16  size_x;
     25        nv::uint16  size_y;
    2626};
    2727
     
    6666        }
    6767        tile.data  = new nv::uint8[ tile.size_x * tile.size_y ];
    68         tile.ascii = ( ascii ? new nv::char8[ tile.size_x * tile.size_y ] : nullptr );
     68        tile.ascii = ( ascii ? new nv::uchar8[ tile.size_x * tile.size_y ] : nullptr );
    6969
    7070        nv::uint8 translation[256] = { 0 };
     
    8989                for ( nv::uint16 row = 0; row < tile.size_y; row++ )
    9090                {
    91                         nv::char8 gylph = (nv::char8)code[ row * ( tile.size_x + 1 ) + line ];
     91                        nv::uchar8 gylph = (nv::uchar8)code[ row * ( tile.size_x + 1 ) + line ];
    9292                        // TODO: check for errors
    9393                        tile.data[ row * tile.size_x + line ] = translation[ gylph ];
     
    110110        if ( old_tile->ascii )
    111111        {
    112                 new_tile->ascii = new nv::char8[ size ];
     112                new_tile->ascii = new nv::uchar8[ size ];
    113113        }
    114114        std::copy( old_tile->data, old_tile->data + size, new_tile->data );
Note: See TracChangeset for help on using the changeset viewer.