Skip to content
This repository

GLSL emacs mode

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 README
Octocat-spinner-32 glsl-mode.el
README
glsl-mode.el --- major mode for Open GLSL shader files

Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc.
Copyright (C) 2011 Jim Hourihan

Authors: Xavier.Decoret@imag.fr, 
         Jim Hourihan <jimhourihan ~at~ gmail.com> (updated for 4.3, etc)
Keywords: languages
Version: 2.0
X-URL: http://artis.inrialpes.fr/~Xavier.Decoret/resources/glsl-mode/

This software is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
General Public License for more details.

You should have received a copy of the GNU General Public License
along with GNU Emacs; see the file COPYING.  If not, write to
the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.

 Commentary:

Major mode for editing OpenGLSL grammar files, usually files ending with
`.vert', `.frag', `.glsl', `.geom'.  Is is based on c-mode plus some
features and pre-specified fontifications.

Modifications from the 1.0 version of glsl-mode (jimhourihan):
 * Removed original optimized regexps for font-lock-keywords and
   replaced with keyword lists for easier maintenance
 * Added customization group and faces
 * Preprocessor faces
 * Updated to GLSL 4.3
 * Separate deprecated symbols
 * Made _ part of a word
 * man page lookup at opengl.org

This package provides the following features:
 * Syntax coloring (via font-lock) for grammar symbols and
   builtin functions and variables for up to GLSL version 4.2
 * Indentation for the current line (TAB) and selected region (C-M-\).
 * Switching between file.vert and file.frag
   with S-lefttab (via ff-find-other-file)
 * interactive function glsl-find-man-page prompts for glsl built
   in function, formats opengl.org url and passes to w3m

 Installation:

This file requires Emacs-20.3 or higher and package cc-mode.

If glsl-mode is not part of your distribution, put this file into your
load-path and the following into your ~/.emacs:
  (autoload 'glsl-mode "glsl-mode" nil t)
  (add-to-list 'auto-mode-alist '("\\.glsl\\'" . glsl-mode))
  (add-to-list 'auto-mode-alist '("\\.vert\\'" . glsl-mode))
  (add-to-list 'auto-mode-alist '("\\.frag\\'" . glsl-mode))
  (add-to-list 'auto-mode-alist '("\\.geom\\'" . glsl-mode))
Something went wrong with that request. Please try again.