Closed anufrievroman closed 9 months ago
Another idea is to have an option to not generate phonons in sources if they are inside a hole. This way holes could extend into sources without having to place the sources around the holes.
Yes, that's definitely a good idea!
The phonon generation inside holes is fixed. And the original idea I actually reconsidered and thought that it's an unnecessary complication which breaks backwards compatibility, so I'll close this issue.
I partly disagree. Adding a direction parameter that simply adds a certain angle onto every generated phonon does not break backwards compatability (if the default value is set to 0) and still permits the source to be rotated.
Well, I mean, I'd have to replace random_up
to random
+ angle = 0
but maybe it's okay, we always break this kind of compatibility anyways. I gave up on the idea of making separate classes for distributions, but decided to add angle parameter or Source
object, and rename the distributions then.
Implemented in ed005e289894412380b33505d353f9660e6147ef
So, final version of the sources is like that. I'll close this issue then,
Instead of hard-coding the distributions, they could be objects like
random
,lambert
,directional
etc with the propertydirection
.