Skip to content

Conversation

@JansenSmith
Copy link

- [x] fix tessellate typo  
- [x] make the arg oddRowYOffset into oddColYOffset 
- [x] add oddRowXOffset arg 
- [x] add z layering
- [x] buncha helper methods
- [ ] more helper methods 
- [ ] hex tessellation in new system
- [ ] doxygen documentation 
- [ ] testing

@JansenSmith JansenSmith self-assigned this Jul 31, 2024
@JansenSmith
Copy link
Author

I'm really struggling to get it any more tested than it is, until it's in a release. need to work on my framework's build env.

@JansenSmith
Copy link
Author

shifting to doxygen

@JansenSmith JansenSmith marked this pull request as ready for review July 31, 2024 19:39
@JansenSmith
Copy link
Author

This set of methods provides various ways to tessellate a given CSG object into either a 3D grid (using tessellate) or a 2D grid (using tessellateXY), by specifying the number of steps (iterations) and grid spacing, with optional offsets for odd rows, columns, and layers.
The methods together offer flexibility in input parameteres, incl grid spacing, optional offsets, and offsets being given as either more arguments or a matrix of the appropriate size.

@madhephaestus
Copy link
Member

Hmm, how might you represent a Ca2SiO4-Mg2SiO4-Fe2SiO4 crystal? I assume each element would be its own shape, but how would the regular crystal shape be represented?

@madhephaestus madhephaestus merged commit 208ee06 into NeuronRobotics:development Jul 31, 2024
@madhephaestus
Copy link
Member

For testing static methods like this, just making methods in a Groovy script and calling them is enough to demonstrate that they work. In the future link the testing repo to the PR for future folks reading it.

@JansenSmith
Copy link
Author

Hmm, how might you represent a Ca2SiO4-Mg2SiO4-Fe2SiO4 crystal? I assume each element would be its own shape, but how would the regular crystal shape be represented?

@madhephaestus nerdiest and cutest question ever!
huh, that one's a doozy... well, it's orthorhombic, so there IS hope that this version of tessellate can do it. i'd need to do LOTS of math to figure out where the octohedra edges need to be, so they are overlapping. lemme think about this.

@madhephaestus
Copy link
Member

Maybe make a helper method like the hex ones once you work it out?

@JansenSmith
Copy link
Author

yeah, a basic crystal lattice helper that does stacking was something i wanted to do, but i ran out of steam. hmm.

@madhephaestus
Copy link
Member

you dont need to over-generalize it, just make a few specific ones as examples and folks will work out for themselves how to use it and extend it if needed. What might be useful would be to have it hull between shapes to represent "bonds". then if you make a diamond lattuce, and tell it to hull the bonds, it actually makes a volumetrically strong and sparse structure that is actually useful...

@madhephaestus
Copy link
Member

this is also getting into an area where OO becomes helpful, to represent the molicules and thier relative bonding angles...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants