Skip to content

textureSampleStep is not reset on clear #8

@athomschke

Description

@athomschke

When calling clear on a Ploma instance, textureSampleStep is not reset.

I am using Ploma in a way where randomization is not desired: I want to plug undo and redo onto it. There it is essential that the sequence "undo redo" restores the initial image. I can achieve that by simply overwriting Math.random with a function that returns an arbitrary chosen value. One could see this value as a representation of the unique structure of paper. However, since textureSampleStep is not being reset, the result after undoing and redoing is still distinct if I don't use a completely new Ploma instance.

In my opinion, textureSampleStep should be reset to 0 in this.clear routine.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions