Unix and Linux Discussions Tagged with printf |
|
Thread / Thread Starter |
Last Post |
Replies |
Views |
Forum |
|
|
|
4 |
3,651 |
Shell Programming and Scripting |
|
|
|
2 |
16,193 |
Shell Programming and Scripting |
|
|
|
2 |
3,649 |
Programming |
|
|
|
13 |
10,508 |
Shell Programming and Scripting |
|
|
|
3 |
12,052 |
Programming |
|
|
|
2 |
3,334 |
Shell Programming and Scripting |
|
|
|
3 |
3,948 |
UNIX for Advanced & Expert Users |
|
|
|
1 |
6,459 |
Programming |
|
|
|
4 |
6,947 |
Shell Programming and Scripting |
|
|
|
4 |
39,744 |
Programming |
|
|
|
2 |
3,059 |
Shell Programming and Scripting |
|
|
|
5 |
8,416 |
Shell Programming and Scripting |
|
|
|
1 |
1,794 |
Programming |
|
|
|
7 |
9,417 |
Shell Programming and Scripting |
|
|
|
7 |
3,679 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
2,680 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
11,380 |
Shell Programming and Scripting |
|
|
|
0 |
878 |
Software Releases - RSS News |
|
|
|
0 |
1,045 |
Software Releases - RSS News |
|
|
|
0 |
4,841 |
Programming |
|
|
|
6 |
3,162 |
Shell Programming and Scripting |
|
|
|
2 |
6,021 |
Shell Programming and Scripting |
|
|
|
1 |
4,014 |
Programming |
|
|
|
16 |
14,693 |
Programming |
|
|
|
2 |
5,928 |
Programming |
|
|
|
2 |
3,414 |
Programming |
|
|
|
2 |
12,777 |
Programming |
|
|
|
1 |
7,280 |
Programming |
|
|
|
2 |
2,895 |
UNIX for Advanced & Expert Users |
|
|
|
2 |
5,365 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
11,392 |
UNIX for Advanced & Expert Users |
|
|
|
4 |
30,372 |
UNIX for Advanced & Expert Users |
|
|
|
2 |
2,588 |
Programming |
|
|
|
1 |
3,295 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
10,784 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
10,389 |
UNIX for Dummies Questions & Answers |
|
|
|
3 |
3,504 |
UNIX for Dummies Questions & Answers |
|
|
|
3 |
3,549 |
UNIX for Dummies Questions & Answers |
|
|
|
0 |
19,750 |
UNIX for Dummies Questions & Answers |
SDL_JoystickOpen(3) SDL API Reference SDL_JoystickOpen(3)
NAME
SDL_JoystickOpen- Opens a joystick for use.
SYNOPSIS
#include "SDL.h"
SDL_Joystick *SDL_JoystickOpen(int index);
DESCRIPTION
Opens a joystick for use within SDL. The index refers to the N'th joystick in the system. A joystick must be opened before it game be used.
RETURN VALUE
Returns a SDL_Joystick structure on success. NULL on failure.
EXAMPLES
SDL_Joystick *joy;
// Check for joystick
if(SDL_NumJoysticks()>0){
// Open joystick
joy=SDL_JoystickOpen(0);
if(joy)
{
printf("Opened Joystick 0
");
printf("Name: %s
", SDL_JoystickName(0));
printf("Number of Axes: %d
", SDL_JoystickNumAxes(joy));
printf("Number of Buttons: %d
", SDL_JoystickNumButtons(joy));
printf("Number of Balls: %d
", SDL_JoystickNumBalls(joy));
}
else
printf("Couldn't open Joystick 0
");
// Close if opened
if(SDL_JoystickOpened(0))
SDL_JoystickClose(joy);
}
SEE ALSO
SDL_JoystickClose
SDL
Tue 11 Sep 2001, 23:00 SDL_JoystickOpen(3)