Rework permission system
Session and layer permissions need some rethinking. Some rough thoughts on what's to be done, needs to be fleshed out further and a UI thought up for it:
-
Make layer permissions interact with layer groups. Basically, there needs to be an "inherit" option, which means to use whatever permissions come from the parent layer, which you can then override with a more specific permission per layer or group.
-
Limits for the number of layers someone can create.
-
Brush size limit. Currently anyone can use any size brush, which can be disruptive in public sessions.
-
Transform size limits. Currently this is hard-coded to 8K arbitrarily.
-
Maybe an "exclusive" mode for sessions? A lot of sessions work by making users create their own layers, this mode would automatically make them create a new group and layer for themselves when they join a session.
About exclusive mode. The more layers there is the longer resets take. Though probably it probably won't be more than 10-30 layers, and animations can get to 200 layers. It would still make resets irritatingly longer the more users there are.
When users leaves, their layer will stay. and no one else can use it so it would leave a useless layer. having a layer for each user would also make deleting art difficult since you would need to look for the layer, and pick it.at least until selections can select multiple layers via group. (Would need for all user layers and groups to be put in one big group.)
if It deletes itself when a user leaves then their artwork is lost whenever they leave. if it deleted itself after like amount of a time of inactivity (Like 2 hours.) could be interesting though, since it would allow for automatic board cleaning. Usually operators clean boards themselves for space, but this would make it automatic.
Animations can get to 200 layers. It would still make resets irritatingly longer the more users there are.
We hope to address and improve this in the animation overhaul.
When users leaves, their layer will stay. and no one else can use it so it would leave a useless layer. if It deletes itself when a user leaves then their artwork is lost whenever they leave. if it deleted itself after like amount of time.
Would a search function for layers with the option to sort results by recent activity, and of course mass selection, alleviate this?
"Exclusive mode" would be to support how private sessions usually work in practice. You get together, everyone makes their own layers and you fill the canvas for a few hours. Those kinds of sessions don't ever "clean up" art, they just extend the canvas if needed and end when everyone's done drawing. It'd be nice if the program support this way of working properly, rather than having to make a layer called "make your own layers" and hoping everyone remembers to do that.
Public or perpetual sessions wouldn't use this mode, it doesn't make sense for them for the reasons you stated. They have a need to move stuff around or clean up art to keep the session usable beyond a single canvas filling.
The more layers there is the longer resets take.
More layers do not cause resets to get longer. More pixels do.
The command to create a layer is tiny, a single brush stroke is many times larger. The content of those layers is the bulk of a reset. So the difference between two users sharing a layer and drawing in different places on it versus making their own layers is minuscule, it still has to transmit the same amount of pixels.
We hope to address and improve this in the animation overhaul.
Animations obviously have more pixel content, so they make resets longer. That's inevitable and wouldn't be solved by any overhaul. But the resets could be made less annoying by #1247 and/or #1248.
More layers do not cause resets to get longer. More pixels do.
Animations obviously have more pixel content, so they make resets longer. That's inevitable and wouldn't be solved by any overhaul. But the resets could be made less annoying by https://github.com/drawpile/Drawpile/issues/1247 and/or https://github.com/drawpile/Drawpile/issues/1248.
From what I have seen resets work by rendering each layer individually bottom layers to top. :0 thought the more layers there is the longer it is since layer 30 would need to wait for layer 29 to be rendered and layer 31 needs to wait for layer 30 Etc. And the whole canvas gets rendered each layer would be a whole canvas render. This is how I think they work which is why I thought each layer would make a reset longer. :0
"Exclusive mode" would be to support how private sessions usually work in practice. You get together, everyone makes their own layers and you fill the canvas for a few hours. Those kinds of sessions don't ever "clean up" art, they just extend the canvas if needed and end when everyone's done drawing. It'd be nice if the program support this way of working properly, rather than having to make a layer called "make your own layers" and hoping everyone remembers to do that.
Public or perpetual sessions wouldn't use this mode, it doesn't make sense for them for the reasons you stated. They have a need to move stuff around or clean up art to keep the session usable beyond a single canvas filling.
I see, I dunno if it's really needed, since users might prefer customising their own layer anyhow, if they're making a layer for their own. I do see a few benefits from it in public servers, trolls won't be able to mess with other people's art. Since everyone has their own layer and group automatically. + Automatic cleaning could be a thing. But outside of that the mode could confuse people. I see the mode being mostly confusing and not all that useful. But a / command could be neat. Like /Layer-for-all-users command.
That's just because of the order of commands in the reset image, it contains the command to create a layer, then commands to fill it with pixel data, always alternating like that. What's taking time is that pixel data in between them.
It being confusing is definitely one of the concerns, which is why it's just a "maybe". It's also something that could be added later, since it's really just the client doing something if it sees a flag, so it's not necessary to include in the initial design. Older clients would just not create those layers automatically, so no big deal.
Mockup of the UI.
Options are placeholder and don't reflect how it's going to be implemented.
Second mockup by Bluestrings.