docs/man3/SDL_JoystickName.3
author Aaron Wishnick <schnarf@gmail.com>
Wed, 18 Jun 2008 04:51:10 +0000
branchgsoc2008_audio_resampling
changeset 2655 b8e736c8a5a8
parent 2283 546f7c1eb755
child 4311 1238da4a7112
permissions -rw-r--r--
Added beginnings of resampling code.
slouken@181
     1
.TH "SDL_JoystickName" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 
slouken@0
     2
.SH "NAME"
slouken@2283
     3
SDL_JoystickName \- Get joystick name\&.
slouken@0
     4
.SH "SYNOPSIS"
slouken@0
     5
.PP
slouken@0
     6
\fB#include "SDL\&.h"
slouken@0
     7
.sp
slouken@0
     8
\fBconst char *\fBSDL_JoystickName\fP\fR(\fBint index\fR);
slouken@0
     9
.SH "DESCRIPTION"
slouken@0
    10
.PP
slouken@0
    11
Get the implementation dependent name of joystick\&. The \fBindex\fR parameter refers to the N\&'th joystick on the system\&.
slouken@0
    12
.SH "RETURN VALUE"
slouken@0
    13
.PP
slouken@0
    14
Returns a char pointer to the joystick name\&.
slouken@0
    15
.SH "EXAMPLES"
slouken@0
    16
.PP
slouken@0
    17
.PP
slouken@0
    18
.nf
slouken@0
    19
\f(CW/* Print the names of all attached joysticks */
slouken@0
    20
int num_joy, i;
slouken@0
    21
num_joy=SDL_NumJoysticks();
slouken@0
    22
printf("%d joysticks found
slouken@0
    23
", num_joy);
slouken@0
    24
for(i=0;i<num_joy;i++)
slouken@0
    25
  printf("%s
slouken@181
    26
", SDL_JoystickName(i));\fR
slouken@0
    27
.fi
slouken@0
    28
.PP
slouken@0
    29
.SH "SEE ALSO"
slouken@0
    30
.PP
slouken@0
    31
\fI\fBSDL_JoystickOpen\fP\fR
slouken@181
    32
...\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00