summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--TODO5
-rw-r--r--info/blueshift.texinfo91
-rw-r--r--src/blueshift_quartz.pyx4
-rw-r--r--src/blueshift_randr.pyx2
-rw-r--r--src/blueshift_vidmode.pyx2
-rw-r--r--src/blueshift_w32gdi.pyx4
6 files changed, 91 insertions, 17 deletions
diff --git a/TODO b/TODO
index 2f3f52e..e493820 100644
--- a/TODO
+++ b/TODO
@@ -20,11 +20,6 @@ Low priority:
(Not too important, it is hardcoded in X to only allow 256)
Use Robertson's method
Screen count function for VidMode should be added
- CRTC count function for W32 GDI should be documented
- W32 GDI support should be documented
- Quartz support should be documented
- CRTC count function for Quartz should be documented
- Gamma restore function for Quartz should be documented
Future stuff:
How is it looking on the DirectFB front?
diff --git a/info/blueshift.texinfo b/info/blueshift.texinfo
index fe1595b..6c3160a 100644
--- a/info/blueshift.texinfo
+++ b/info/blueshift.texinfo
@@ -248,12 +248,14 @@ comma separated list, and multiple options
may be used. It is best to start one
instance per monitor with colour calibration.
-Be aware than under X — using RandR — the
-primary monitor is reported to have the
-zeroth CRTC. But under TTY — using DRM —
-this is no concept of primary monitors,
-and thus the CRTC indices can slightly
-different.
+Be aware than under X — using the Resize and
+Rotate (RandR) extension@footnote{Don't be
+fooled by the name, it can actually do anything
+that has to do with monitor control.} — the
+primary monitor is reported to have the zeroth
+CRTC. But under TTY — using DRM — this is no
+concept of primary monitors, and thus the CRTC
+indices can slightly different.
@end table
@option{-g}, @option{-b}, @option{+b}, and
@@ -1554,6 +1556,83 @@ function it will still be called outputs
for API compatibility with the RandR
version) by be different.
+Blueshift also have support for running
+under Windows, using Windows Graphics
+Device Interface (Windows GDI) and Mac
+OS X, using Quartz via Core Graphics.
+However, this has only been tested on
+GNU/Linux under X with compatibility
+layers written, for Blueshift and
+Redshift, from documentation; and are
+not support beyond this documentation.
+@footnote{The reason for this is simple:
+the are proprietary operating systems
+that would never touch because of the
+fact that they are proprietary and that
+they are GUI orientated, as well as
+I would not like to pay for those
+shortcomings.}
+
+Windows GDI is used similarly to RandR.
+To apply the adjustments invoke the
+function @code{w32gdi}, optionally with
+the indices of the CRTC:s to perform the
+adjustment on. If no CRTC is selected,
+the adjustment will be applied on all
+CRTC:s. To create a function that applies
+the adjustments that are applied currently
+[when the function is created] on top of
+the current adjustments [when the create
+function is invoked] use the function
+@code{w32gdi_get}, optionally with the
+index of the CRTC to read from. If not
+CRTC is selected CRTC 0 will be used.
+For compatibility with the other methods,
+@code{w32gdi} and @code{w32gdi_get} have
+two dummy parameters: @code{screen} and
+@code{display}.
+
+Quartz is used in the same way as Windows
+GDI, except the functions are named
+@code{quartz} and @code{quartz_get},
+respectively.
+
+@c TODO resolve this (Windows and Mac OS X)
+Be aware than the following may change
+in a future version of Blueshift as support
+for Windows and Mac OS X increases.
+
+Both Windows GDI and Quartz have support
+for getting the number of available CRTC:s.
+It is however not as full featured as for
+RandR and DRM so @code{list_screens} cannot
+be used. Instead, use the functions
+@code{w32gdi_crtc_count} and
+@code{quartz_crtc_count}, respectively.
+They take no arguments and return an integer
+with the number of available CRTC:s.
+
+Quartz also have support for resetting the
+adjustment on each and every monitor on the
+system to this on ColorSync. To perform
+this action run the function
+@code{quartz_restore}. It takes no arguments
+and does not return any value.
+
+Again, the support for Windows and Mac OS X, is
+minimal. For now, if you want to use either of
+@code{w32gdi_crtc_count}, @code{quartz_crtc_count}
+and @code{quartz_restore} before Windows GDI
+or Quartz have been used via @code{w32gdi},
+@code{w32gdi_get}, @code{quartz} or @code{quartz_get},
+you will have to initialise them. The easiest
+way to do this is to just run @code{w32gdi_get}
+or @code{quartz_get}. Another way to do this
+is to run @code{w32gdi_open} or @code{quartz_open}
+and when done run @code{w32gdi_close} or
+@code{quartz_close}. Neither of these functions
+take any arguments nor returns any value.
+
@node Optimising
@section Optimising
diff --git a/src/blueshift_quartz.pyx b/src/blueshift_quartz.pyx
index 528c08f..8b8da88 100644
--- a/src/blueshift_quartz.pyx
+++ b/src/blueshift_quartz.pyx
@@ -107,7 +107,7 @@ def quartz_crtc_count():
'''
Get the number of CRTC:s on the system
- @return The number of CRTC:s on the system
+ @return :int The number of CRTC:s on the system
'''
return blueshift_quartz_crtc_count()
@@ -145,7 +145,7 @@ def quartz_apply(crtc_indices, r_curve, g_curve, b_curve):
@param r_curve:list<float> The red colour curve
@param g_curve:list<float> The green colour curve
@param b_curve:list<float> The blue colour curve
- @return Zero on success
+ @return :int Zero on success
'''
# Convert curves to C floats
for i in range(256):
diff --git a/src/blueshift_randr.pyx b/src/blueshift_randr.pyx
index 7de1d13..842a026 100644
--- a/src/blueshift_randr.pyx
+++ b/src/blueshift_randr.pyx
@@ -133,7 +133,7 @@ def randr_apply(crtc_indices, r_curve, g_curve, b_curve):
@param r_curve:list<int> The red colour curve
@param g_curve:list<int> The green colour curve
@param b_curve:list<int> The blue colour curve
- @return Zero on success
+ @return :int Zero on success
'''
# Convert curves to 16-bit C integers
for i in range(256):
diff --git a/src/blueshift_vidmode.pyx b/src/blueshift_vidmode.pyx
index 772befd..f5d3760 100644
--- a/src/blueshift_vidmode.pyx
+++ b/src/blueshift_vidmode.pyx
@@ -131,7 +131,7 @@ def vidmode_apply(r_curve, g_curve, b_curve):
@param r_curve:list<int> The red colour curve
@param g_curve:list<int> The green colour curve
@param b_curve:list<int> The blue colour curve
- @return Zero on success
+ @return :int Zero on success
'''
# Convert curves to 16-bit C integers
for i in range(256):
diff --git a/src/blueshift_w32gdi.pyx b/src/blueshift_w32gdi.pyx
index 0886a7e..2a9750b 100644
--- a/src/blueshift_w32gdi.pyx
+++ b/src/blueshift_w32gdi.pyx
@@ -87,7 +87,7 @@ def w32gdi_crtc_count():
'''
Get the number of CRTC:s on the system
- @return The number of CRTC:s on the system
+ @return :int The number of CRTC:s on the system
'''
return blueshift_w32gdi_crtc_count()
@@ -125,7 +125,7 @@ def w32gdi_apply(crtc_indices, r_curve, g_curve, b_curve):
@param r_curve:list<int> The red colour curve
@param g_curve:list<int> The green colour curve
@param b_curve:list<int> The blue colour curve
- @return Zero on success
+ @return :int Zero on success
'''
# Convert curves to 16-bit C integers
for i in range(256):