Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Resolves #6924
Thanks to @rohanjulka19 for his prior work.
This PR is work in progress.
Changes:
clearTextures()
as a draft.Description:
These are some of the things that I'm not too sure about and would love to get some suggestions:
p5.Geometry
be decoupled?I am not too sure but I think there should be some separation between
p5.Geometry
or multiple objects and their properties such as material properties, diffuse colors, textures, etc.clearTextures()
might not be what we desire but it's just the idea of having it here. (ToDo)Seperation of Concerns in the
p5.Geometry
class:Class:
p5.Geometry
Focuses solely on the geometric data of the 3D object.
vertices
normals
faces
texCoords
, etc.and methods for the geometry data.
Class:
p5.Material
Manages material properties, colors, texture, mtl properties, etc.
Methods like: applyMaterial(
fill()
),clearColors()
,clearTextures()
, etc.A Grouping Structure:
Class:
p5.Group
: Combines multiplep5.Geometry
,p5.Material
and transform (global transformation on the entire group) and methods.PR Checklist
npm run lint
passes