- replaced several explicit allocations with TArrays.
This commit is contained in:
parent
d68cd3aa80
commit
a73c065811
10 changed files with 66 additions and 115 deletions
|
|
@ -83,7 +83,7 @@ TArray<uint8_t> FVoxelTexture::CreatePalettedPixels(int conversion)
|
|||
{
|
||||
// GetPixels gets called when a translated palette is used so we still need to implement it here.
|
||||
TArray<uint8_t> Pixels(256, true);
|
||||
uint8_t *pp = SourceVox->Palette;
|
||||
uint8_t *pp = SourceVox->Palette.Data();
|
||||
|
||||
if(pp != NULL)
|
||||
{
|
||||
|
|
@ -120,9 +120,9 @@ int FVoxelTexture::CopyPixels(FBitmap *bmp, int conversion)
|
|||
{
|
||||
PalEntry pe[256];
|
||||
uint8_t bitmap[256];
|
||||
uint8_t *pp = SourceVox->Palette;
|
||||
uint8_t *pp = SourceVox->Palette.Data();
|
||||
|
||||
if(pp != NULL)
|
||||
if(pp != nullptr)
|
||||
{
|
||||
for(int i=0;i<256;i++, pp+=3)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue