Changeset 487 for trunk/src/gfx
- Timestamp:
- 03/08/16 08:05:51 (9 years ago)
- Location:
- trunk/src/gfx
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/gfx/image.cc
r406 r487 26 26 : m_size( size ), m_depth( depth ), m_data( nullptr ) 27 27 { 28 NV_ASSERT( size.x >= 0 && size.y >= 0, "bad parameters passed to image!" ); 28 29 sint32 bsize = m_size.x * m_size.y * static_cast<sint32>( m_depth ); 29 m_data = new uint8[ bsize];30 m_data = new uint8[ size_t( bsize ) ]; 30 31 31 32 if ( reversed ) -
trunk/src/gfx/mesh_creator.cc
r482 r487 265 265 delete[] tangents2; 266 266 267 uint32 n_channel_index = m_data->get_channel_index( slot::NORMAL ); 268 data_channel_set_creator( m_data ).set_channel( n_channel_index, merge_channels( *m_nrm_channel, g_channel ) ); 267 int n_channel_index = m_data->get_channel_index( slot::NORMAL ); 268 NV_ASSERT( n_channel_index >= 0, "Normal channel not found!" ); 269 data_channel_set_creator( m_data ).set_channel( uint32( n_channel_index ), merge_channels( *m_nrm_channel, g_channel ) ); 269 270 initialize(); 270 271 } -
trunk/src/gfx/texture_font.cc
r471 r487 80 80 static uint8* convert_to_rgba(uint8* rgb, const int lines, const int line_count, const int line_bpitch ) 81 81 { 82 uint8* result = new uint8[ lines * line_count * 4];82 uint8* result = new uint8[ static_cast< uint32 >( lines * line_count * 4 ) ]; 83 83 uint8* rgba = result; 84 84 for(int l=0; l<lines; ++l)
Note: See TracChangeset
for help on using the changeset viewer.