mirror of
https://github.com/psychopy/psychojs.git
synced 2025-05-10 18:50:54 +00:00
CU-1yn08hm - added contrast support;
This commit is contained in:
parent
8f8867a560
commit
496154442f
@ -52,6 +52,7 @@ export class Window extends PsychObject
|
|||||||
fullscr = false,
|
fullscr = false,
|
||||||
color = new Color("black"),
|
color = new Color("black"),
|
||||||
gamma = 1,
|
gamma = 1,
|
||||||
|
contrast = 1,
|
||||||
units = "pix",
|
units = "pix",
|
||||||
waitBlanking = false,
|
waitBlanking = false,
|
||||||
autoLog = true,
|
autoLog = true,
|
||||||
@ -64,7 +65,8 @@ export class Window extends PsychObject
|
|||||||
|
|
||||||
// storing AdjustmentFilter instance to access later;
|
// storing AdjustmentFilter instance to access later;
|
||||||
this._adjustmentFilter = new AdjustmentFilter({
|
this._adjustmentFilter = new AdjustmentFilter({
|
||||||
gamma
|
gamma,
|
||||||
|
contrast
|
||||||
});
|
});
|
||||||
|
|
||||||
// list of all elements, in the order they are currently drawn:
|
// list of all elements, in the order they are currently drawn:
|
||||||
@ -75,6 +77,9 @@ export class Window extends PsychObject
|
|||||||
this._addAttribute("gamma", gamma, 1, () => {
|
this._addAttribute("gamma", gamma, 1, () => {
|
||||||
this._adjustmentFilter.gamma = this._gamma;
|
this._adjustmentFilter.gamma = this._gamma;
|
||||||
});
|
});
|
||||||
|
this._addAttribute("contrast", contrast, 1, () => {
|
||||||
|
this._adjustmentFilter.contrast = this._contrast;
|
||||||
|
});
|
||||||
this._addAttribute("units", units);
|
this._addAttribute("units", units);
|
||||||
this._addAttribute("waitBlanking", waitBlanking);
|
this._addAttribute("waitBlanking", waitBlanking);
|
||||||
this._addAttribute("autoLog", autoLog);
|
this._addAttribute("autoLog", autoLog);
|
||||||
|
Loading…
Reference in New Issue
Block a user