Volumes Of Fun

Cubic - How to switch colordithering off?
Page 1 of 1

Author:  zprg [ Mon Dec 16, 2013 9:27 am ]
Post subject:  Cubic - How to switch colordithering off?


tried a look to cubiquity - thank you for the new toy.
excuse if i was to blind to find but wondered wheres the switch to stop the colordithering in cubic version please?

with kind regards

Author:  David Williams [ Mon Dec 16, 2013 7:27 pm ]
Post subject:  Re: Cubic - How to switch colordithering off?

At the moment you have to turn it off by editing the shader: https://bitbucket.org/volumesoffun/cubi ... ster#cl-41

Setting the noise value to zero should do it:

//Add noise - we use model space to prevent noise scrolling if the volume moves.
float noise = 0.0; //positionBasedNoise(float4(IN.modelPos.xyz, 0.1)); <-- Edit this line

Of course it would be nice if there was a simple check box somewhere, maybe in the future.

Be aware that you can not turn off the quantization, so please check the QuantizedColor docs if you are not clear what this is doing.

Author:  zprg [ Wed Dec 25, 2013 6:20 pm ]
Post subject:  Re: Cubic - How to switch colordithering off?


now i found time to test and unity and c# are new but thats right it works without the colordithering, thx.
test with primitive functionplotter:

      float z = 0.0f;
      for(float y = -3.0f; y < 3.0f; y=y+0.1f)
         for(float x = -3.0f; x < 3.0f; x=x+0.1f)
            z=Mathf.Sin(x)* Mathf.Cos(y);
            coloredCubesVolume.data.SetVoxel((int)(x*10+20), (int)(z*10+20), (int)(y*10+20), new QuantizedColor((byte)(z*125+125),0,0,255));

merry xmas and a happy new year 2014 for the community and the Sirs Williams!

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group