psychopy
psychopy copied to clipboard
Adding backgroundColorOffset to GratingStim
Hello,
I am trying to convert some matlab PsychoToolbox-3.0 code to PsychoPy.
In my matlab code I am using the function CreateProceduralGabor
, with the parameter backgroundColorOffset
, used to add a constant shift to the color of the texture.
I tried to replace the call using the GratingStim
, but unfortunately it doesn't have yet a similar option.
I saw that there is an unused variable called rgbPedestal
, was it intended for this use?
I would happily add this feature myself, are there any guidelines I should follow? Thanks!
If you can see how to implement this variable the by all means feel free to pop in a pull request, we're always happy to see contributions! You can find guides for developers contributing to PsychoPy here: https://www.psychopy.org/developers/index.html
Hi @hovavalon just circling back this. For info, yes, rgbPedestal did do exactly that. Possibly that feature got lost in the refactoring of the color spaces into a color class object if that attribute isn't currently working(?). It does need applying separately to the color. Did you make any progress looking into it?
Hi @peircej , I did look into it a little bit, but unfortunately I had no time to write a PR. In case I ever get to it, do you have any recommendations about the general structure of such a PR? Thanks!
There's details on good practice for PR's in the CONTRIBUTING.md document :) https://github.com/psychopy/psychopy/blob/dev/CONTRIBUTING.md