pymovements.Screen.to_dict#
- Screen.to_dict(*, exclude_none: bool = True, prefer_resolution: bool = False, prefer_size: bool = False) dict[str, Any][source]#
Convert the Screen instance into a dictionary.
- Parameters:
exclude_none (bool) – Exclude attributes that are either
Noneor that are objects that evaluate toFalse(e.g.,[],{},EyeTracker()). Attributes of typebool,int, andfloatare not excluded. (default: True)prefer_resolution (bool) – If
Trueincluderesolutioninstead ofwidth_pxandheight_pxin output dictionary. (default: False)prefer_size (bool) – If
Trueincludesizeinstead ofwidth_cmandheight_cmin output dictionary. (default: False)
- Returns:
Screen as dictionary.
- Return type: