pygame documentation | || Pygame Home || Help Contents || Reference Index || Camera || Cdrom || Color || Cursors || Display || Draw || Event || Examples || Font || Freetype || Gfxdraw || Image || Joystick || Key || Locals || Mask || Math || Midi || Mixer || Mouse || Movie || Music || Overlay || Pixelarray || Pixelcopy || Pygame || Rect || Scrap || Sndarray || Sprite || Surface || Surfarray || Tests || Time || Transform

- pygame — the top level pygame package

- pygame.Color — pygame object for color representations

- Color.a — Gets or sets the alpha value of the Color.
- Color.b — Gets or sets the blue value of the Color.
- Color.cmy — Gets or sets the CMY representation of the Color.
- Color.correct_gamma — Applies a certain gamma value to the Color.
- Color.g — Gets or sets the green value of the Color.
- Color.hsla — Gets or sets the HSLA representation of the Color.
- Color.hsva — Gets or sets the HSVA representation of the Color.
- Color.i1i2i3 — Gets or sets the I1I2I3 representation of the Color.
- Color.normalize — Returns the normalized RGBA values of the Color.
- Color.r — Gets or sets the red value of the Color.
- Color.set_length — Set the number of elements in the Color to 1,2,3, or 4.

- pygame.Overlay — pygame object for video overlay graphics

- Overlay.display — set the overlay pixel data
- Overlay.get_hardware — test if the Overlay is hardware accelerated
- Overlay.set_location — control where the overlay is displayed

- pygame.PixelArray — pygame object for direct pixel access of surfaces

- PixelArray.compare — Compares the PixelArray with another one.
- PixelArray.extract — Extracts the passed color from the PixelArray.
- PixelArray.make_surface — Creates a new Surface from the current PixelArray.
- PixelArray.replace — Replaces the passed color in the PixelArray with another one.
- PixelArray.surface — Gets the Surface the PixelArray uses.

- pygame.Rect — pygame object for storing rectangular coordinates

- Rect.clamp — moves the rectangle inside another
- Rect.clamp_ip — moves the rectangle inside another, in place
- Rect.clip — crops a rectangle inside another
- Rect.collidedict — test if one rectangle in a dictionary intersects
- Rect.collidedictall — test if all rectangles in a dictionary intersect
- Rect.collidelist — test if one rectangle in a list intersects
- Rect.collidelistall — test if all rectangles in a list intersect
- Rect.collidepoint — test if a point is inside a rectangle
- Rect.colliderect — test if two rectangles overlap
- Rect.contains — test if one rectangle is inside another
- Rect.copy — copy the rectangle
- Rect.fit — resize and move a rectangle with aspect ratio
- Rect.inflate — grow or shrink the rectangle size
- Rect.inflate_ip — grow or shrink the rectangle size, in place
- Rect.move — moves the rectangle
- Rect.move_ip — moves the rectangle, in place
- Rect.normalize — correct negative sizes
- Rect.union — joins two rectangles into one
- Rect.union_ip — joins two rectangles into one, in place
- Rect.unionall — the union of many rectangles
- Rect.unionall_ip — the union of many rectangles, in place

- pygame.Surface — pygame object for representing images

- Surface.blit — draw one image onto another
- Surface.convert — change the pixel format of an image
- Surface.convert_alpha — change the pixel format of an image including per pixel alphas
- Surface.copy — create a new copy of a Surface
- Surface.fill — fill Surface with a solid color
- Surface.get_abs_offset — find the absolute position of a child subsurface inside its top level parent
- Surface.get_abs_parent — find the top level parent of a subsurface
- Surface.get_alpha — get the current Surface transparency value
- Surface.get_at — get the color value at a single pixel
- Surface.get_at_mapped — get the mapped color value at a single pixel
- Surface.get_bitsize — get the bit depth of the Surface pixel format
- Surface.get_bounding_rect — find the smallest rect containing data
- Surface.get_buffer — acquires a buffer object for the pixels of the Surface.
- Surface.get_bytesize — get the bytes used per Surface pixel
- Surface.get_clip — get the current clipping area of the Surface
- Surface.get_colorkey — Get the current transparent colorkey
- Surface.get_flags — get the additional flags used for the Surface
- Surface.get_height — get the height of the Surface
- Surface.get_locked — test if the Surface is current locked
- Surface.get_locks — Gets the locks for the Surface
- Surface.get_losses — the significant bits used to convert between a color and a mapped integer
- Surface.get_masks — the bitmasks needed to convert between a color and a mapped integer
- Surface.get_offset — find the position of a child subsurface inside a parent
- Surface.get_palette — get the color index palette for an 8bit Surface
- Surface.get_palette_at — get the color for a single entry in a palette
- Surface.get_parent — find the parent of a subsurface
- Surface.get_pitch — get the number of bytes used per Surface row
- Surface.get_rect — get the rectangular area of the Surface
- Surface.get_shifts — the bit shifts needed to convert between a color and a mapped integer
- Surface.get_size — get the dimensions of the Surface
- Surface.get_view — return a view of a surface's pixel data.
- Surface.get_width — get the width of the Surface
- Surface.lock — lock the Surface memory for pixel access
- Surface.map_rgb — convert a color into a mapped color value
- Surface.mustlock — test if the Surface requires locking
- Surface.scroll — Shift the surface image in place
- Surface.set_alpha — set the alpha value for the full Surface image
- Surface.set_at — set the color value for a single pixel
- Surface.set_clip — set the current clipping area of the Surface
- Surface.set_colorkey — Set the transparent colorkey
- Surface.set_masks — set the bitmasks needed to convert between a color and a mapped integer
- Surface.set_palette — set the color palette for an 8bit Surface
- Surface.set_palette_at — set the color for a single index in an 8bit Surface palette
- Surface.set_shifts — sets the bit shifts needed to convert between a color and a mapped integer
- Surface.subsurface — create a new surface that references its parent
- Surface.unlock — unlock the Surface memory from pixel access
- Surface.unmap_rgb — convert a mapped integer color value into a Color

- pygame.camera — pygame module for camera use

- pygame.camera.Camera — load a camera

- Camera.get_controls — gets current values of user controls
- Camera.get_image — captures an image as a Surface
- Camera.get_raw — returns an unmodified image as a string
- Camera.get_size — returns the dimensions of the images being recorded
- Camera.query_image — checks if a frame is ready
- Camera.set_controls — changes camera settings if supported by the camera
- Camera.start — opens, initializes, and starts capturing
- Camera.stop — stops, uninitializes, and closes the camera

- pygame.camera.colorspace — Surface colorspace conversion
- pygame.camera.list_cameras — returns a list of available cameras

- pygame.cdrom — pygame module for audio cdrom control

- pygame.cdrom.CD — class to manage a cdrom drive

- CD.eject — eject or open the cdrom drive
- CD.get_all — get all track information
- CD.get_busy — true if the drive is playing audio
- CD.get_current — the current audio playback position
- CD.get_empty — False if a cdrom is in the drive
- CD.get_id — the index of the cdrom drive
- CD.get_init — true if this cd device initialized
- CD.get_name — the system name of the cdrom drive
- CD.get_numtracks — the number of tracks on the cdrom
- CD.get_paused — true if the drive is paused
- CD.get_track_audio — true if the cdrom track has audio data
- CD.get_track_length — length of a cdrom track
- CD.get_track_start — start time of a cdrom track
- CD.init — initialize a cdrom drive for use
- CD.pause — temporarily stop audio playback
- CD.play — start playing audio
- CD.quit — uninitialize a cdrom drive for use
- CD.resume — unpause audio playback
- CD.stop — stop audio playback

- pygame.cdrom.get_count — number of cd drives on the system
- pygame.cdrom.get_init — true if the cdrom module is initialized
- pygame.cdrom.init — initialize the cdrom module
- pygame.cdrom.quit — uninitialize the cdrom module

- pygame.cursors — pygame module for cursor resources

- pygame.cursors.compile — create binary cursor data from simple strings
- pygame.cursors.load_xbm — load cursor data from an xbm file

- pygame.display — pygame module to control the display window and screen

- pygame.display.Info — Create a video display information object
- pygame.display.flip — update the full display Surface to the screen
- pygame.display.get_active — true when the display is active on the display
- pygame.display.get_caption — get the current window caption
- pygame.display.get_driver — get the name of the pygame display backend
- pygame.display.get_init — true if the display module is initialized
- pygame.display.get_surface — get a reference to the currently set display surface
- pygame.display.get_wm_info — Get information about the current windowing system
- pygame.display.gl_get_attribute — get the value for an opengl flag for the current display
- pygame.display.gl_set_attribute — request an opengl display attribute for the display mode
- pygame.display.iconify — iconify the display surface
- pygame.display.init — initialize the display module
- pygame.display.list_modes — get list of available fullscreen modes
- pygame.display.mode_ok — pick the best color depth for a display mode
- pygame.display.quit — uninitialize the display module
- pygame.display.set_caption — set the current window caption
- pygame.display.set_gamma — change the hardware gamma ramps
- pygame.display.set_gamma_ramp — change the hardware gamma ramps with a custom lookup
- pygame.display.set_icon — change the system image for the display window
- pygame.display.set_mode — initialize a window or screen for display
- pygame.display.set_palette — set the display color palette for indexed displays
- pygame.display.toggle_fullscreen — switch between fullscreen and windowed displays
- pygame.display.update — update portions of the screen for software displays

- pygame.draw — pygame module for drawing shapes

- pygame.draw.aaline — draw fine antialiased lines
- pygame.draw.aalines — draw a connected sequence of antialiased lines
- pygame.draw.arc — draw a partial section of an ellipse
- pygame.draw.circle — draw a circle around a point
- pygame.draw.ellipse — draw a round shape inside a rectangle
- pygame.draw.line — draw a straight line segment
- pygame.draw.lines — draw multiple contiguous line segments
- pygame.draw.polygon — draw a shape with any number of sides
- pygame.draw.rect — draw a rectangle shape

- pygame.encode_file_path — Encode a unicode or bytes object as a file system path
- pygame.encode_string — Encode a unicode or bytes object
- pygame.error — standard pygame exception
- pygame.event — pygame module for interacting with events and queues

- pygame.event.Event — create a new event object
- pygame.event.clear — remove all events from the queue
- pygame.event.event_name — get the string name from and event id
- pygame.event.get — get events from the queue
- pygame.event.get_blocked — test if a type of event is blocked from the queue
- pygame.event.get_grab — test if the program is sharing input devices
- pygame.event.peek — test if event types are waiting on the queue
- pygame.event.poll — get a single event from the queue
- pygame.event.post — place a new event on the queue
- pygame.event.pump — internally process pygame event handlers
- pygame.event.set_allowed — control which events are allowed on the queue
- pygame.event.set_blocked — control which events are allowed on the queue
- pygame.event.set_grab — control the sharing of input devices with other applications
- pygame.event.wait — wait for a single event from the queue

- pygame.examples — module of example programs

- pygame.examples.aliens.main — play the full aliens example
- pygame.examples.arraydemo.main — show various surfarray effects
- pygame.examples.blend_fill.main — demonstrate the various surface.fill method blend options
- pygame.examples.blit_blends.main — uses alternative additive fill to that of surface.fill
- pygame.examples.camera.main — display video captured live from an attached camera
- pygame.examples.chimp.main — hit the moving chimp
- pygame.examples.cursors.main — display two different custom cursors
- pygame.examples.eventlist.main — display pygame events
- pygame.examples.fastevents.main — stress test the fastevents module
- pygame.examples.fonty.main — run a font rendering example
- pygame.examples.glcube.main — display an animated 3D cube using OpenGL
- pygame.examples.headless_no_windows_needed.main — write an image file that is smoothscaled copy of an input file
- pygame.examples.liquid.main — display an animated liquid effect
- pygame.examples.mask.main — display multiple images bounce off each other using collision detection
- pygame.examples.midi.main — run a midi example
- pygame.examples.moveit.main — display animated objects on the screen
- pygame.examples.movieplayer.main — play an MPEG movie
- pygame.examples.oldalien.main — play the original aliens example
- pygame.examples.overlay.main — play a .pgm video using overlays
- pygame.examples.pixelarray.main — display various pixelarray generated effects
- pygame.examples.scaletest.main — interactively scale an image using smoothscale
- pygame.examples.scrap_clipboard.main — access the clipboard
- pygame.examples.scroll.main — run a Surface.scroll example that shows a magnified image
- pygame.examples.sound.main — load and play a sound
- pygame.examples.sound_array_demos.main — play various sndarray effects
- pygame.examples.stars.main — run a simple starfield example
- pygame.examples.testsprite.main — show lots of sprites moving around
- pygame.examples.vgrade.main — display a vertical gradient

- pygame.font — pygame module for loading and rendering fonts

- pygame.font.Font — create a new Font object from a file

- Font.get_ascent — get the ascent of the font
- Font.get_bold — check if text will be rendered bold
- Font.get_descent — get the descent of the font
- Font.get_height — get the height of the font
- Font.get_italic — check if the text will be rendered italic
- Font.get_linesize — get the line space of the font text
- Font.get_underline — check if text will be rendered with an underline
- Font.metrics — Gets the metrics for each character in the pased string.
- Font.render — Renders text on a surface
- Font.set_bold — enable fake rendering of bold text
- Font.set_italic — enable fake rendering of italic text
- Font.set_underline — control if text is rendered with an underline
- Font.size — determine the amount of space needed to render text

- pygame.font.SysFont — create a Font object from the system fonts
- pygame.font.get_default_font — get the filename of the default font
- pygame.font.get_fonts — get all available fonts
- pygame.font.get_init — true if the font module is initialized
- pygame.font.init — initialize the font module
- pygame.font.match_font — find a specific font on the system
- pygame.font.quit — uninitialize the font module

- pygame.freetype — Enhanced Pygame module for loading and rendering fonts

- pygame.freetype.Font — Creates a new Font from a supported font file.

- Font.antialiased — Font antialiasing mode
- Font.bold — Gets or sets the font's bold style
- Font.fixed_width — Gets whether the font is fixed-width
- Font.get_metrics — Gets glyph metrics for the font's characters
- Font.get_size — Gets the size of rendered text
- Font.height — Gets the height of the Font
- Font.italic — Gets or sets the font's italic style
- Font.name — Gets the name of the font face.
- Font.render — Renders text on a surface
- Font.render_raw — Renders text as a string of bytes
- Font.style — Gets or sets the font's style
- Font.underline — Gets or sets the font's underline style
- Font.vertical — Font vertical mode

- pygame.freetype.get_error — Get the latest error
- pygame.freetype.get_version — Get the FreeType version
- pygame.freetype.init — Initialize the underlying FreeType 2 library.
- pygame.freetype.quit — Shuts down the underlying FreeType 2 library.
- pygame.freetype.was_init — Returns whether the the FreeType 2 library is initialized.

- pygame.get_error — get the current error message
- pygame.get_sdl_byteorder — get the byte order of SDL
- pygame.get_sdl_version — get the version number of SDL
- pygame.gfxdraw — pygame module for drawing shapes

- pygame.gfxdraw.aacircle — draw an anti-aliased circle
- pygame.gfxdraw.aaellipse — draw an anti-aliased ellipse
- pygame.gfxdraw.aapolygon — draw an anti-aliased polygon
- pygame.gfxdraw.aatrigon — draw an anti-aliased triangle
- pygame.gfxdraw.arc — draw an arc
- pygame.gfxdraw.bezier — draw a bezier curve
- pygame.gfxdraw.box — draw a box
- pygame.gfxdraw.circle — draw a circle
- pygame.gfxdraw.ellipse — draw an ellipse
- pygame.gfxdraw.filled_circle — draw a filled circle
- pygame.gfxdraw.filled_ellipse — draw a filled ellipse
- pygame.gfxdraw.filled_polygon — draw a filled polygon
- pygame.gfxdraw.filled_trigon — draw a filled trigon
- pygame.gfxdraw.hline — draw a horizontal line
- pygame.gfxdraw.line — draw a line
- pygame.gfxdraw.pie — draw a pie
- pygame.gfxdraw.pixel — place a pixel
- pygame.gfxdraw.polygon — draw a polygon
- pygame.gfxdraw.rectangle — draw a rectangle
- pygame.gfxdraw.textured_polygon — draw a textured polygon
- pygame.gfxdraw.trigon — draw a triangle
- pygame.gfxdraw.vline — draw a vertical line

- pygame.image — pygame module for image transfer

- pygame.image.frombuffer — create a new Surface that shares data inside a string buffer
- pygame.image.fromstring — create new Surface from a string buffer
- pygame.image.get_extended — test if extended image formats can be loaded
- pygame.image.load — load new image from a file
- pygame.image.save — save an image to disk
- pygame.image.tostring — transfer image to string buffer

- pygame.init — initialize all imported pygame modules
- pygame.joystick — pygame module for interacting with joystick devices

- pygame.joystick.Joystick — create a new Joystick object

- Joystick.get_axis — get the current position of an axis
- Joystick.get_ball — get the relative position of a trackball
- Joystick.get_button — get the current button state
- Joystick.get_hat — get the position of a joystick hat
- Joystick.get_id — get the Joystick ID
- Joystick.get_init — check if the Joystick is initialized
- Joystick.get_name — get the Joystick system name
- Joystick.get_numaxes — get the number of axes on a Joystick
- Joystick.get_numballs — get the number of trackballs on a Joystick
- Joystick.get_numbuttons — get the number of buttons on a Joystick
- Joystick.get_numhats — get the number of hat controls on a Joystick
- Joystick.init — initialize the Joystick
- Joystick.quit — uninitialize the Joystick

- pygame.joystick.get_count — number of joysticks on the system
- pygame.joystick.get_init — true if the joystick module is initialized
- pygame.joystick.init — initialize the joystick module
- pygame.joystick.quit — uninitialize the joystick module

- pygame.key — pygame module to work with the keyboard

- pygame.key.get_focused — true if the display is receiving keyboard input from the system
- pygame.key.get_mods — determine which modifier keys are being held
- pygame.key.get_pressed — get the state of all keyboard buttons
- pygame.key.get_repeat — see how held keys are repeated
- pygame.key.name — get the name of a key identifier
- pygame.key.set_mods — temporarily set which modifier keys are pressed
- pygame.key.set_repeat — control how held keys are repeated

- pygame.locals — pygame constants
- pygame.mask — pygame module for image masks.

- pygame.mask.Mask — pygame object for representing 2d bitmasks

- Mask.angle — Returns the orientation of the pixels
- Mask.centroid — Returns the centroid of the pixels in a Mask
- Mask.clear — Sets all bits to 0
- Mask.connected_component — Returns a mask of a connected region of pixels.
- Mask.connected_components — Returns a list of masks of connected regions of pixels.
- Mask.convolve — Return the convolution of self with another mask.
- Mask.count — Returns the number of set pixels
- Mask.draw — Draws a mask onto another
- Mask.erase — Erases a mask from another
- Mask.fill — Sets all bits to 1
- Mask.get_at — Returns nonzero if the bit at (x,y) is set.
- Mask.get_bounding_rects — Returns a list of bounding rects of regions of set pixels.
- Mask.get_size — Returns the size of the mask.
- Mask.invert — Flips the bits in a Mask
- Mask.outline — list of points outlining an object
- Mask.overlap — Returns the point of intersection if the masks overlap with the given offset - or None if it does not overlap.
- Mask.overlap_area — Returns the number of overlapping 'pixels'.
- Mask.overlap_mask — Returns a mask of the overlapping pixels
- Mask.scale — Resizes a mask
- Mask.set_at — Sets the position in the mask given by x and y.

- pygame.mask.from_surface — Returns a Mask from the given surface.
- pygame.mask.from_threshold — Creates a mask by thresholding Surfaces

- pygame.math — pygame module for vector classes

- pygame.math.Vector2 — a 2-Dimensional Vector

- Vector2.angle_to — calculates the angle to a given vector in degrees.
- Vector2.as_polar — returns a tuple with radial distance and azimuthal angle.
- Vector2.cross — calculates the cross- or vector-product
- Vector2.distance_squared_to — calculates the squared euclidic distance to a given vector.
- Vector2.distance_to — calculates the euclidic distance to a given vector.
- Vector2.dot — calculates the dot- or scalar-product with the other vector
- Vector2.elementwise — The next operation will be performed elementwize.
- Vector2.from_polar — Sets x and y from a polar coordinates tuple.
- Vector2.is_normalized — tests if the vector is normalized i.e. has length == 1.
- Vector2.length — returns the euclidic length of the vector.
- Vector2.length_squared — returns the squared euclidic length of the vector.
- Vector2.lerp — returns a linear interpolation to the given vector.
- Vector2.normalize — returns a vector with the same direction but length 1.
- Vector2.normalize_ip — normalizes the vector in place so that its length is 1.
- Vector2.reflect — returns a vector reflected of a given normal.
- Vector2.reflect_ip — reflect the vector of a given normal in place.
- Vector2.rotate — rotates a vector by a given angle in degrees.
- Vector2.rotate_ip — rotates the vector by a given angle in degrees in place.
- Vector2.scale_to_length — scales the vector to a given length.
- Vector2.slerp — returns a spherical interpolation to the given vector.

- pygame.math.Vector3 — a 3-Dimensional Vector

- Vector3.angle_to — calculates the angle to a given vector in degrees.
- Vector3.as_spherical — returns a tuple with radial distance, inclination and azimuthal angle.
- Vector3.cross — calculates the cross- or vector-product
- Vector3.distance_squared_to — calculates the squared euclidic distance to a given vector.
- Vector3.distance_to — calculates the euclidic distance to a given vector.
- Vector3.dot — calculates the dot- or scalar-product with the other vector
- Vector3.elementwise — The next operation will be performed elementwize.
- Vector3.from_spherical — Sets x, y and z from a spherical coordinates 3-tuple.
- Vector3.is_normalized — tests if the vector is normalized i.e. has length == 1.
- Vector3.length — returns the euclidic length of the vector.
- Vector3.length_squared — returns the squared euclidic length of the vector.
- Vector3.lerp — returns a linear interpolation to the given vector.
- Vector3.normalize — returns a vector with the same direction but length 1.
- Vector3.normalize_ip — normalizes the vector in place so that its length is 1.
- Vector3.reflect — returns a vector reflected of a given normal.
- Vector3.reflect_ip — reflect the vector of a given normal in place.
- Vector3.rotate — rotates a vector by a given angle in degrees.
- Vector3.rotate_ip — rotates the vector by a given angle in degrees in place.
- Vector3.rotate_x — rotates a vector around the x-axis by the angle in degrees.
- Vector3.rotate_x_ip — rotates the vector around the x-axis by the angle in degrees in place.
- Vector3.rotate_y — rotates a vector around the y-axis by the angle in degrees.
- Vector3.rotate_y_ip — rotates the vector around the y-axis by the angle in degrees in place.
- Vector3.rotate_z — rotates a vector around the z-axis by the angle in degrees.
- Vector3.rotate_z_ip — rotates the vector around the z-axis by the angle in degrees in place.
- Vector3.scale_to_length — scales the vector to a given length.
- Vector3.slerp — returns a spherical interpolation to the given vector.

- pygame.math.disable_swizzling — globally disables swizzling for vectors.
- pygame.math.enable_swizzling — globally enables swizzling for vectors.

- pygame.midi — pygame module for interacting with midi input and output.

- pygame.midi.Input — Input is used to get midi input from midi devices.

- Input.close — closes a midi stream, flushing any pending buffers.
- Input.poll — returns true if there's data, or false if not.
- Input.read — reads num_events midi events from the buffer.

- pygame.midi.MidiException — exception that pygame.midi functions and classes can raise
- pygame.midi.Output — Output is used to send midi to an output device

- Output.abort — terminates outgoing messages immediately
- Output.close — closes a midi stream, flushing any pending buffers.
- Output.note_off — turns a midi note off. Note must be on.
- Output.note_on — turns a midi note on. Note must be off.
- Output.set_instrument — select an instrument, with a value between 0 and 127
- Output.write — writes a list of midi data to the Output
- Output.write_short — write_short(status <, data1><, data2>)
- Output.write_sys_ex — writes a timestamped system-exclusive midi message.

- pygame.midi.get_count — gets the number of devices.
- pygame.midi.get_default_input_id — gets default input device number
- pygame.midi.get_default_output_id — gets default output device number
- pygame.midi.get_device_info — returns information about a midi device
- pygame.midi.init — initialize the midi module
- pygame.midi.midis2events — converts midi events to pygame events
- pygame.midi.quit — uninitialize the midi module
- pygame.midi.time — returns the current time in ms of the PortMidi timer

- pygame.mixer — pygame module for loading and playing sounds

- pygame.mixer.Channel — Create a Channel object for controlling playback

- Channel.fadeout — stop playback after fading channel out
- Channel.get_busy — check if the channel is active
- Channel.get_endevent — get the event a channel sends when playback stops
- Channel.get_queue — return any Sound that is queued
- Channel.get_sound — get the currently playing Sound
- Channel.get_volume — get the volume of the playing channel
- Channel.pause — temporarily stop playback of a channel
- Channel.play — play a Sound on a specific Channel
- Channel.queue — queue a Sound object to follow the current
- Channel.set_endevent — have the channel send an event when playback stops
- Channel.set_volume — set the volume of a playing channel
- Channel.stop — stop playback on a Channel
- Channel.unpause — resume pause playback of a channel

- pygame.mixer.Sound — Create a new Sound object from a file or buffer object

- Sound.fadeout — stop sound playback after fading out
- Sound.get_buffer — acquires a buffer object for the samples of the Sound.
- Sound.get_length — get the length of the Sound
- Sound.get_num_channels — count how many times this Sound is playing
- Sound.get_volume — get the playback volume
- Sound.play — begin sound playback
- Sound.set_volume — set the playback volume for this Sound
- Sound.stop — stop sound playback

- pygame.mixer.fadeout — fade out the volume on all sounds before stopping
- pygame.mixer.find_channel — find an unused channel
- pygame.mixer.get_busy — test if any sound is being mixed
- pygame.mixer.get_init — test if the mixer is initialized
- pygame.mixer.get_num_channels — get the total number of playback channels
- pygame.mixer.init — initialize the mixer module
- pygame.mixer.music — pygame module for controlling streamed audio

- pygame.mixer.music.fadeout — stop music playback after fading out
- pygame.mixer.music.get_busy — check if the music stream is playing
- pygame.mixer.music.get_endevent — get the event a channel sends when playback stops
- pygame.mixer.music.get_pos — get the music play time
- pygame.mixer.music.get_volume — get the music volume
- pygame.mixer.music.load — Load a music file for playback
- pygame.mixer.music.pause — temporarily stop music playback
- pygame.mixer.music.play — Start the playback of the music stream
- pygame.mixer.music.queue — queue a music file to follow the current
- pygame.mixer.music.rewind — restart music
- pygame.mixer.music.set_endevent — have the music send an event when playback stops
- pygame.mixer.music.set_pos — set position to play from
- pygame.mixer.music.set_volume — set the music volume
- pygame.mixer.music.stop — stop the music playback
- pygame.mixer.music.unpause — resume paused music

- pygame.mixer.pause — temporarily stop playback of all sound channels
- pygame.mixer.pre_init — preset the mixer init arguments
- pygame.mixer.quit — uninitialize the mixer
- pygame.mixer.set_num_channels — set the total number of playback channels
- pygame.mixer.set_reserved — reserve channels from being automatically used
- pygame.mixer.stop — stop playback of all sound channels
- pygame.mixer.unpause — resume paused playback of sound channels

- pygame.mouse — pygame module to work with the mouse

- pygame.mouse.get_cursor — get the image for the system mouse cursor
- pygame.mouse.get_focused — check if the display is receiving mouse input
- pygame.mouse.get_pos — get the mouse cursor position
- pygame.mouse.get_pressed — get the state of the mouse buttons
- pygame.mouse.get_rel — get the amount of mouse movement
- pygame.mouse.set_cursor — set the image for the system mouse cursor
- pygame.mouse.set_pos — set the mouse cursor position
- pygame.mouse.set_visible — hide or show the mouse cursor

- pygame.movie — pygame module for playback of mpeg video

- pygame.movie.Movie — load an mpeg movie file

- Movie.get_busy — check if the movie is currently playing
- Movie.get_frame — get the current video frame
- Movie.get_length — the total length of the movie in seconds
- Movie.get_size — get the resolution of the video
- Movie.get_time — get the current vide playback time
- Movie.has_audio — check if the movie file contains audio
- Movie.has_video — check if the movie file contains video
- Movie.pause — temporarily stop and resume playback
- Movie.play — start playback of a movie
- Movie.render_frame — set the current video frame
- Movie.rewind — restart the movie playback
- Movie.set_display — set the video target Surface
- Movie.set_volume — set the audio playback volume
- Movie.skip — advance the movie playback position
- Movie.stop — stop movie playback

- pygame.pixelcopy — pygame module for general pixel array copying

- pygame.pixelcopy.array_to_surface — copy an array object to a surface
- pygame.pixelcopy.map_array — copy an array to another array, using surface format
- pygame.pixelcopy.surface_to_array — copy surface pixels to an array object

- pygame.quit — uninitialize all pygame modules
- pygame.register_quit — register a function to be called when pygame quits
- pygame.scrap — pygame module for clipboard support.

- pygame.scrap.contains — Checks, whether a certain type is available in the clipboard.
- pygame.scrap.get — Gets the data for the specified type from the clipboard.
- pygame.scrap.get_types — Gets a list of the available clipboard types.
- pygame.scrap.init — Initializes the scrap module.
- pygame.scrap.lost — Checks whether the clipboard is currently owned by the application.
- pygame.scrap.put — Places data into the clipboard.
- pygame.scrap.set_mode — Sets the clipboard access mode.

- pygame.set_error — set the current error message
- pygame.sndarray — pygame module for accessing sound sample data

- pygame.sndarray.array — copy Sound samples into an array
- pygame.sndarray.get_arraytype — Gets the currently active array type.
- pygame.sndarray.get_arraytypes — Gets the array system types currently supported.
- pygame.sndarray.make_sound — convert an array into a Sound object
- pygame.sndarray.samples — reference Sound samples into an array
- pygame.sndarray.use_arraytype — Sets the array system to be used for sound arrays

- pygame.sprite — pygame module with basic game object classes

- pygame.sprite.DirtySprite — a more featureful subclass of Sprite with more attributes

- pygame.sprite.Group — container class for many Sprites

- Group.add — add Sprites to this Group
- Group.clear — draw a background over the Sprites
- Group.copy — duplicate the Group
- Group.draw — blit the Sprite images
- Group.empty — remove all Sprites
- Group.has — test if a Group contains Sprites
- Group.remove — remove Sprites from the Group
- Group.sprites — list of the Sprites this Group contains
- Group.update — call the update method on contained Sprites

- pygame.sprite.GroupSingle — Group container that holds a single Sprite
- pygame.sprite.LayeredDirty — LayeredDirty Group is for DirtySprites. Subclasses LayeredUpdates.

- LayeredDirty.change_layer — changes the layer of the sprite
- LayeredDirty.clear — used to set background
- LayeredDirty.draw — draw all sprites in the right order onto the passed surface.
- LayeredDirty.get_clip — clip the area where to draw. Just pass None (default) to reset the clip
- LayeredDirty.repaint_rect — repaints the given area
- LayeredDirty.set_clip — clip the area where to draw. Just pass None (default) to reset the clip
- LayeredDirty.set_timing_treshold — sets the treshold in milliseconds

- pygame.sprite.LayeredUpdates — LayeredUpdates Group handles layers, that draws like OrderedUpdates.

- LayeredUpdates.add — add a sprite or sequence of sprites to a group
- LayeredUpdates.change_layer — changes the layer of the sprite
- LayeredUpdates.draw — draw all sprites in the right order onto the passed surface.
- LayeredUpdates.get_bottom_layer — returns the bottom layer
- LayeredUpdates.get_layer_of_sprite — returns the layer that sprite is currently in.
- LayeredUpdates.get_sprite — returns the sprite at the index idx from the groups sprites
- LayeredUpdates.get_sprites_at — returns a list with all sprites at that position.
- LayeredUpdates.get_sprites_from_layer — returns all sprites from a layer, ordered by how they where added
- LayeredUpdates.get_top_layer — returns the top layer
- LayeredUpdates.get_top_sprite — returns the topmost sprite
- LayeredUpdates.layers — returns a list of layers defined (unique), sorted from botton up.
- LayeredUpdates.move_to_back — moves the sprite to the bottom layer
- LayeredUpdates.move_to_front — brings the sprite to front layer
- LayeredUpdates.remove_sprites_of_layer — removes all sprites from a layer and returns them as a list.
- LayeredUpdates.sprites — returns a ordered list of sprites (first back, last top).
- LayeredUpdates.switch_layer — switches the sprites from layer1 to layer2

- pygame.sprite.OrderedUpdates — RenderUpdates class that draws Sprites in order of addition
- pygame.sprite.RenderUpdates — Group class that tracks dirty updates

- RenderUpdates.draw — blit the Sprite images and track changed areas

- pygame.sprite.Sprite — simple base class for visible game objects

- Sprite.add — add the sprite to groups
- Sprite.alive — does the sprite belong to any groups
- Sprite.groups — list of Groups that contain this Sprite
- Sprite.kill — remove the Sprite from all Groups
- Sprite.remove — remove the sprite from groups
- Sprite.update — method to control sprite behavior

- pygame.sprite.collide_circle — collision detection between two sprites, using circles.
- pygame.sprite.collide_circle_ratio — collision detection between two sprites, using circles scaled to a ratio.
- pygame.sprite.collide_mask — collision detection between two sprites, using masks.
- pygame.sprite.collide_rect — collision detection between two sprites, using rects.
- pygame.sprite.collide_rect_ratio — collision detection between two sprites, using rects scaled to a ratio.
- pygame.sprite.groupcollide — find all Sprites that collide between two Groups
- pygame.sprite.spritecollide — find Sprites in a Group that intersect another Sprite
- pygame.sprite.spritecollideany — simple test if a Sprite intersects anything in a Group

- pygame.surfarray — pygame module for accessing surface pixel data using array interfaces

- pygame.surfarray.array2d — Copy pixels into a 2d array
- pygame.surfarray.array3d — Copy pixels into a 3d array
- pygame.surfarray.array_alpha — Copy pixel alphas into a 2d array
- pygame.surfarray.array_colorkey — Copy the colorkey values into a 2d array
- pygame.surfarray.blit_array — Blit directly from a array values
- pygame.surfarray.get_arraytype — Gets the currently active array type.
- pygame.surfarray.get_arraytypes — Gets the array system types currently supported.
- pygame.surfarray.make_surface — Copy an array to a new surface
- pygame.surfarray.map_array — Map a 3d array into a 2d array
- pygame.surfarray.pixels2d — Reference pixels into a 2d array
- pygame.surfarray.pixels3d — Reference pixels into a 3d array
- pygame.surfarray.pixels_alpha — Reference pixel alphas into a 2d array
- pygame.surfarray.pixels_blue — Reference pixel blue into a 2d array.
- pygame.surfarray.pixels_green — Reference pixel green into a 2d array.
- pygame.surfarray.pixels_red — Reference pixel red into a 2d array.
- pygame.surfarray.use_arraytype — Sets the array system to be used for surface arrays

- pygame.tests — Pygame unit test suite package

- pygame.tests.run — Run the Pygame unit test suite

- pygame.time — pygame module for monitoring time

- pygame.time.Clock — create an object to help track time

- Clock.get_fps — compute the clock framerate
- Clock.get_rawtime — actual time used in the previous tick
- Clock.get_time — time used in the previous tick
- Clock.tick — update the clock
- Clock.tick_busy_loop — update the clock

- pygame.time.delay — pause the program for an amount of time
- pygame.time.get_ticks — get the time in milliseconds
- pygame.time.set_timer — repeatedly create an event on the event queue
- pygame.time.wait — pause the program for an amount of time

- pygame.transform — pygame module to transform surfaces

- pygame.transform.average_color — finds the average color of a surface
- pygame.transform.average_surfaces — find the average surface from many surfaces.
- pygame.transform.chop — gets a copy of an image with an interior area removed
- pygame.transform.flip — flip vertically and horizontally
- pygame.transform.get_smoothscale_backend — return smoothscale filter version in use: 'GENERIC', 'MMX', or 'SSE'
- pygame.transform.laplacian — find edges in a surface
- pygame.transform.rotate — rotate an image
- pygame.transform.rotozoom — filtered scale and rotation
- pygame.transform.scale — resize to new resolution
- pygame.transform.scale2x — specialized image doubler
- pygame.transform.set_smoothscale_backend — set smoothscale filter version to one of: 'GENERIC', 'MMX', or 'SSE'
- pygame.transform.smoothscale — scale a surface to an arbitrary size smoothly
- pygame.transform.threshold — finds which, and how many pixels in a surface are within a threshold of a color.

- pygame.version — small module containing version information

- pygame.version.ver — version number as a string
- pygame.version.vernum — tupled integers of the version