Commit 85b779f6 authored by Alastair Bridgewater's avatar Alastair Bridgewater
Browse files

clx-interface: Excise all of the (disabled) GLX noise.

  * All of this GLX code is disabled, and dates back to when this
file was part of "game-stuff".  It is not presently required, and
only serves to obscure what's really going on.
parent 4c3ec61a
......@@ -40,17 +40,6 @@
(defparameter *default-window-title* "CLX Interface Window")
#+(or)
(defun handle-glx-init-kludges (display)
;; GLX doesn't (yet) tell the server what it needs to know
;; automatically, so we need to tell it to do so now.
(glx::client-info display)
;; If the GLX context isn't destroyed properly then the context
;; information hangs around in a special variable to confuse things
;; when next a GLX connection is made.
(setf glx::*current-context* nil))
(defun set-window-space-requirement (window space-requirement)
(multiple-value-bind
(width min-width max-width height max-height min-height)
......@@ -62,20 +51,8 @@
(defun init-display (&key display-name space-requirement window-title)
(setf *display* (xlib:open-default-display display-name))
#+(or)
(handle-glx-init-kludges *display*)
(let* ((screen (xlib:display-default-screen *display*))
(root (xlib:screen-root screen))
#+(or)
(visual (glx:choose-visual screen '(:glx-rgba
(:glx-red-size 1)
(:glx-green-size 1)
(:glx-blue-size 1)
:glx-double-buffer)))
#+(or)
(colormap (xlib:create-colormap (glx:visual-id visual) root))
#+(or)
(visual-depth (glx:visual-attribute visual :glx-depth-size))
(black-pixel (xlib:screen-black-pixel screen))
(white-pixel (xlib:screen-white-pixel screen))
(width (or (and space-requirement
......@@ -88,9 +65,6 @@
:x 0 :y 0 :width width :height height
:background white-pixel
:border black-pixel
;:visual (glx:visual-id visual)
;:depth visual-depth
;:colormap colormap
:event-mask '(:exposure))))
(setf *window* window)
......@@ -99,13 +73,7 @@
(when space-requirement
(set-window-space-requirement window space-requirement))
(xlib:map-window window)
;; Set up a GLX context for us to use.
#+(or)
(glx:make-current window
(glx:create-context screen
(glx:visual-id visual)))))
(xlib:map-window window)))
(defun close-display ()
;; It is sufficient to drop the reference to *window*, as closing
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment