zevlg at yandex.ru
Fri Dec 5 05:55:15 EST 2008
Hey! I just discovered interesting opportunity in (S)XEmacs. That is
video glyphs, i.e. glyphs running video inside. Just try out this
(defun lg-video-glyph (file &optional w h)
"Create video glyph to play FILE.
Optionally you can specify width and height by passing W and H args."
(let* ((gg (make-glyph [subwindow]))
(prc (start-process "mplayer" nil "mplayer"
(glyph-image-instance gg) (or w 200) (or h 140))
(put gg 'mplayer-proc prc)
(setq gg (lg-video-glyph "~/crypt/video/kunfu-panda.mp4"))
(make-extent (point) (point))
than you are able to resize video glyph with sexp like this:
(resize-subwindow (glyph-image-instance gg) WIDTH HEIGHT)
Most interesting is that if you point the cursor inside that glyph you
can control mplayer as normal, i mean you can rewind, pause, change
volume, etc, and OSD works as well
More information about the XEmacs-Beta