Skip to content
Permalink
Browse files

Noise: Correct noise objects created with invalid dimensions

  • Loading branch information
kwolekr committed Apr 20, 2015
1 parent 386d695 commit 687d969c9c50be98597ee9f383280517f1f8cd97
Showing with 7 additions and 0 deletions.
  1. +7 −0 src/noise.cpp
@@ -485,6 +485,13 @@ Noise::~Noise()

void Noise::allocBuffers()
{
if (sx < 1)
sx = 1;
if (sy < 1)
sy = 1;
if (sz < 1)
sz = 1;

this->noise_buf = NULL;
resizeNoiseBuf(sz > 1);

0 comments on commit 687d969

Please sign in to comment.
You can’t perform that action at this time.