include/SDL_gamecontroller.h
changeset 8042 7863121cb7d5
parent 7341 675c85d46f30
child 8046 e7c89b29932a
equal deleted inserted replaced
8041:afd62b3fda31 8042:7863121cb7d5
   105  *
   105  *
   106  *  This string shows an example of a valid mapping for a controller
   106  *  This string shows an example of a valid mapping for a controller
   107  *  "341a3608000000000000504944564944,Afterglow PS3 Controller,a:b1,b:b2,y:b3,x:b0,start:b9,guide:b12,back:b8,dpup:h0.1,dpleft:h0.8,dpdown:h0.4,dpright:h0.2,leftshoulder:b4,rightshoulder:b5,leftstick:b10,rightstick:b11,leftx:a0,lefty:a1,rightx:a2,righty:a3,lefttrigger:b6,righttrigger:b7",
   107  *  "341a3608000000000000504944564944,Afterglow PS3 Controller,a:b1,b:b2,y:b3,x:b0,start:b9,guide:b12,back:b8,dpup:h0.1,dpleft:h0.8,dpdown:h0.4,dpright:h0.2,leftshoulder:b4,rightshoulder:b5,leftstick:b10,rightstick:b11,leftx:a0,lefty:a1,rightx:a2,righty:a3,lefttrigger:b6,righttrigger:b7",
   108  *
   108  *
   109  */
   109  */
       
   110 
       
   111 /**
       
   112  *  Load a set of mappings from a file, filtered by the current SDL_GetPlatform()
       
   113  *  A community sourced database of controllers is available at https://raw.github.com/gabomdq/SDL_GameControllerDB/master/gamecontrollerdb.txt
       
   114  *
       
   115  * \return number of mappings added, -1 on error
       
   116  */
       
   117 extern DECLSPEC int SDLCALL SDL_GameControllerAddMappingsFromFile( const char* mapDB );
   110 
   118 
   111 /**
   119 /**
   112  *  Add or update an existing mapping configuration
   120  *  Add or update an existing mapping configuration
   113  *
   121  *
   114  * \return 1 if mapping is added, 0 if updated, -1 on error
   122  * \return 1 if mapping is added, 0 if updated, -1 on error