Skip to content
This repository was archived by the owner on Feb 11, 2024. It is now read-only.

Shouldn't compound brush variables be public for Runtime CSG? #41

Closed
Henry00IS opened this issue Feb 17, 2018 · 1 comment
Closed

Shouldn't compound brush variables be public for Runtime CSG? #41

Henry00IS opened this issue Feb 17, 2018 · 1 comment
Labels
status: pull-request A pull request for the issue awaits approval. type: improvement The issue is an improvement suggestion.

Comments

@Henry00IS
Copy link
Collaborator

Henry00IS commented Feb 17, 2018

I have never tried using the Runtime CSG library before but one thing that always seemed odd is that we made all of the compound brush variables private like this:

        [SerializeField]
        float stepDepth = 0.2f;
        [SerializeField]
	float stepHeight = 0.1f;
        [SerializeField]
        float stepDepthSpacing = 0f;
        [SerializeField]
        float stepHeightSpacing = 0f;
        ...

Doesn't that make it extremely difficult if not nearly impossible to use compound brushes?
Should we make them public or add properties for them?

@sabresaurus
Copy link
Owner

PrimitiveBrush fields also are private, but yes we should add properties for them. I'm not a fan of making fields public except in data only classes as the interface and implementation should be kept separated. For example we may later decide that when another class sets stepHeightSpacing we want some code to run.

@Henry00IS Henry00IS added status: pull-request A pull request for the issue awaits approval. type: improvement The issue is an improvement suggestion. labels Mar 14, 2018
sabresaurus pushed a commit that referenced this issue Mar 14, 2018
Created public properties for primitive- and compound brushes. Fixes #41.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: pull-request A pull request for the issue awaits approval. type: improvement The issue is an improvement suggestion.
Projects
None yet
Development

No branches or pull requests

2 participants