For now I'm remapping the values to positive numbers. 255 is arbitrary and causes rounding errors similar to the vertex rounding you see in playstation games. The resulting textures are "white" but contain the animation data.
float Remap(float aValue) { float normal = Mathf.InverseLerp(-255, 255, aValue); return Mathf.Lerp(0, 255, normal); }
And remapping the pixel.
pixel.r = Remap(position.x); pixel.g = Remap(position.y); pixel.b = Remap(position.z);
I've rewritten the ShaderGraph as a standard surface shader, and to account for this 255 value I'm doing this.
position -= float3(255/2, 255/2, 255/2);
For now I'm remapping the values to positive numbers. 255 is arbitrary and causes rounding errors similar to the vertex rounding you see in playstation games. The resulting textures are "white" but contain the animation data.
float Remap(float aValue) { float normal = Mathf.InverseLerp(-255, 255, aValue); return Mathf.Lerp(0, 255, normal); }And remapping the pixel.
pixel.r = Remap(position.x); pixel.g = Remap(position.y); pixel.b = Remap(position.z);I've rewritten the ShaderGraph as a standard surface shader, and to account for this 255 value I'm doing this.
position -= float3(255/2, 255/2, 255/2);