Menu

#42 FluxObject, FluxPrimitive, ... are not Serializable

v1.0 (example)
open
nobody
None
5
2020-06-21
2020-06-21
No

Hi,

I am trying to transform my scene build with Normal Boxes to a scene using the FluxPrimitives, so that I can use the FluxPhongShader.

My first try was this:

module Leaf(String shaderName, FluxPhongShader leafShader) extends FluxBox(new Cube())
{
    {
        setFluxShader(leafShader);
        //setShader(shader(shaderName));
    }
}

However, this presents my with a

Unexpected Exception
FatalPersistenceException: java.io.NotSerializableException: VaidationSetup$Leaf
Caused by NotSerializableException: VaidationSetup$Leaf

If I understand correctly, the FluxBox and FluxPhongShader (or FluxObjects in general) would have to implement java.io.Serializable like mentioned in Ticket #9. This is not the case.

Am I using the Flux Components wrong?
Or is there a workarount?

Discussion


Log in to post a comment.

MongoDB Logo MongoDB