drobilla / ingen

A realtime modular synthesizer and/or effects processor
GNU Affero General Public License v3.0
30 stars 7 forks source link

Subgraphs when copied don't hold their attributes #15

Closed loki42 closed 3 years ago

loki42 commented 4 years ago

Add an rdfs:comment to a sub graph and the copy it using the server side copy. Generated file doesn't have the comment. If you add it to a block it persists.

I'm using it add details about what a patch is for, which is show to users.

drobilla commented 4 years ago

Oh, I think I know what this is. For graphs there is the concept of "context" that is either internal or external, which controls whether it's saved inside the graph, or in the parent (as a property of the node). Canvas position is the best example, it's saved on the node and makes no sense for the graph. This can be confusing/annoying sometimes but I'm not sure how to better deal with it.

If you save the parent graph I bet you'll see the comment on the node, but not in the subgraph. You can explicitly specify this with https://lv2plug.in/ns/ext/patch#context. The values are either ingen:internalContext or ingen:externalContext (see ingen.ttl).

loki42 commented 4 years ago

Ahh, I think I remember having to set internalContext because otherwise they wouldn't appear in the engine GUI. Maybe that was related to the earlier network issue though. I'll try externalContext. Is rdfs:comment the recommended attribute?

On Fri, 13 Mar 2020 at 20:31, David Robillard notifications@github.com wrote:

Oh, I think I know what this is. For graphs there is the concept of "context" that is either internal or external, which controls whether it's saved inside the graph, or in the parent (as a property of the node). Canvas position is the best example, it's saved on the node and makes no sense for the graph. This can be confusing/annoying sometimes but I'm not sure how to better deal with it.

If you save the parent graph I bet you'll see the comment on the node, but not in the subgraph. You can explicitly specify this with https://lv2plug.in/ns/ext/patch#context. The values are either ingen:internalContext or ingen:externalContext (see ingen.ttl).

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/drobilla/ingen/issues/15#issuecomment-598631344, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAISQBD5VI375YHYNLGNBEDRHH4N3ANCNFSM4LA26RWA .

drobilla commented 4 years ago

I think maybe the better design here would be to have /graphs/whatever and /main/someinstanceofwhatever be totally separate things, but... oh well.

Is rdfs:comment the recommended attribute?

I dunno, it depends. Reasonable default if it's just some text.

drobilla commented 3 years ago

What was the outcome of this?