Home My Page Projects Code Snippets Project Openings 3D graphics for Standard ML
Summary Activity SCM

SCM Repository

[sml3d] View of /trunk/sml3d/src/openal/alc-sig.sml
ViewVC logotype

View of /trunk/sml3d/src/openal/alc-sig.sml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 292 - (download) (annotate)
Tue Sep 30 07:54:18 2008 UTC (11 years, 1 month ago) by jhr
File size: 2050 byte(s)
repository restructuring
(* alc-sig.sml
 *
 * COPYRIGHT (c) 2008 John Reppy (http://cs.uchicago.edu/~jhr)
 * All rights reserved.
 *)

signature ALC =
  sig

    type device
    type capture_device
    type context

  (** Context Management **)

    datatype context_attr
      = FREQUENCY of int		(* Frequency for mixing output buffer (Hz) *)
      | REFRESH of int			(* Refresh intervals (Hz) *)
      | SYNC of bool			(* Indicating a synchronous context *)
      | MONO_SOURCES of int		(* Number of requested mono sources *)
      | STEREO_SOURCES of int		(* Number of requested stereo sources *)

    val createContext : device * context_attr list -> context option
    val makeContextCurrent : context -> bool
    val processContext : context -> unit
    val suspendContext : context -> unit
    val destroyContext : context -> unit
    val getCurrentContext : unit -> context option
    val getContextsDevice : context -> device option


  (** Device Management **)

    val openDevice : string option -> device option
    val closeDevice : device -> bool


  (** Error Management **)

    eqtype error
    val INVALID_DEVICE : error
    val INVALID_CONTEXT : error
    val INVALID_ENUM : error
    val INVALID_VALUE : error
    val OUT_OF_MEMORY : error

    val getError : device -> error option


  (** Query functions **)
    val defaultDeviceSpecifier : unit -> string option		(* default device; NONE for no device *)
    val deviceSpecifier : device -> string			(* name of device *)
    val deviceSpecifiers : unit -> string list			(* names of all devices *)
    val deviceFrequency : device -> int				(* Frequency for mixing output buffer (Hz) *)
    val deviceRefresh : device -> int				(* Refresh intervals (Hz) *)
    val deviceSync : device -> bool				(* Indicating a synchronous context *)
    val deviceMonoSources : device -> int			(* Number of requested mono sources *)
    val deviceStereoSources : device -> int			(* Number of requested stereo sources *)
    val allAttributes : device -> context_attr list		(* context attributes for device *)

  end


root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0