mirror of
https://github.com/libretro/RetroArch.git
synced 2025-02-21 10:11:18 +00:00
(Emscripten) Integrate header files into actual drivers
This commit is contained in:
parent
c0198ac391
commit
1f7482d833
@ -13,11 +13,23 @@
|
||||
* If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
#include <boolean.h>
|
||||
|
||||
#include "../../driver.h"
|
||||
#include "../../general.h"
|
||||
|
||||
#include "../../emscripten/RWebAudio.h"
|
||||
|
||||
/* forward declarations */
|
||||
unsigned RWebAudioSampleRate(void);
|
||||
void *RWebAudioInit(unsigned latency);
|
||||
ssize_t RWebAudioWrite(const void *buf, size_t size);
|
||||
bool RWebAudioStop(void);
|
||||
bool RWebAudioStart(void);
|
||||
void RWebAudioSetNonblockState(bool state);
|
||||
void RWebAudioFree(void);
|
||||
size_t RWebAudioWriteAvail(void);
|
||||
size_t RWebAudioBufferSize(void);
|
||||
static bool rwebaudio_is_paused;
|
||||
|
||||
static void rwebaudio_free(void *data)
|
||||
|
@ -13,8 +13,17 @@
|
||||
* If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <stdint.h>
|
||||
#include <boolean.h>
|
||||
#include "../../driver.h"
|
||||
#include "../../emscripten/RWebCam.h"
|
||||
|
||||
/* forward declarations */
|
||||
void *RWebCamInit(uint64_t caps, unsigned width, unsigned height);
|
||||
void RWebCamFree(void *data);
|
||||
bool RWebCamStart(void *data);
|
||||
void RWebCamStop(void *data);
|
||||
bool RWebCamPoll(void *data, retro_camera_frame_raw_framebuffer_t frame_raw_cb,
|
||||
retro_camera_frame_opengl_texture_t frame_gl_cb);
|
||||
|
||||
static void *rwebcam_init(const char *device, uint64_t caps,
|
||||
unsigned width, unsigned height)
|
||||
|
@ -1,28 +0,0 @@
|
||||
/* RetroArch - A frontend for libretro.
|
||||
* Copyright (C) 2012-2015 - Michael Lelli
|
||||
*
|
||||
* RetroArch is free software: you can redistribute it and/or modify it under the terms
|
||||
* of the GNU General Public License as published by the Free Software Found-
|
||||
* ation, either version 3 of the License, or (at your option) any later version.
|
||||
*
|
||||
* RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License along with RetroArch.
|
||||
* If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
#include <boolean.h>
|
||||
|
||||
unsigned RWebAudioSampleRate(void);
|
||||
void *RWebAudioInit(unsigned latency);
|
||||
ssize_t RWebAudioWrite(const void *buf, size_t size);
|
||||
bool RWebAudioStop(void);
|
||||
bool RWebAudioStart(void);
|
||||
void RWebAudioSetNonblockState(bool state);
|
||||
void RWebAudioFree(void);
|
||||
size_t RWebAudioWriteAvail(void);
|
||||
size_t RWebAudioBufferSize(void);
|
@ -1,24 +0,0 @@
|
||||
/* RetroArch - A frontend for libretro.
|
||||
* Copyright (C) 2012-2015 - Michael Lelli
|
||||
*
|
||||
* RetroArch is free software: you can redistribute it and/or modify it under the terms
|
||||
* of the GNU General Public License as published by the Free Software Found-
|
||||
* ation, either version 3 of the License, or (at your option) any later version.
|
||||
*
|
||||
* RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License along with RetroArch.
|
||||
* If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <stdint.h>
|
||||
#include <boolean.h>
|
||||
#include "../driver.h"
|
||||
|
||||
void *RWebCamInit(uint64_t caps, unsigned width, unsigned height);
|
||||
void RWebCamFree(void *data);
|
||||
bool RWebCamStart(void *data);
|
||||
void RWebCamStop(void *data);
|
||||
bool RWebCamPoll(void *data, retro_camera_frame_raw_framebuffer_t frame_raw_cb, retro_camera_frame_opengl_texture_t frame_gl_cb);
|
@ -1,29 +0,0 @@
|
||||
/* RetroArch - A frontend for libretro.
|
||||
* Copyright (C) 2012-2015 - Michael Lelli
|
||||
*
|
||||
* RetroArch is free software: you can redistribute it and/or modify it under the terms
|
||||
* of the GNU General Public License as published by the Free Software Found-
|
||||
* ation, either version 3 of the License, or (at your option) any later version.
|
||||
*
|
||||
* RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License along with RetroArch.
|
||||
* If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
typedef struct rwebinput_state
|
||||
{
|
||||
uint8_t keys[32];
|
||||
int mouse_x;
|
||||
int mouse_y;
|
||||
char mouse_l;
|
||||
char mouse_r;
|
||||
} rwebinput_state_t;
|
||||
|
||||
int RWebInputInit(void);
|
||||
rwebinput_state_t *RWebInputPoll(int context);
|
||||
void RWebInputDestroy(int context);
|
@ -19,13 +19,25 @@
|
||||
|
||||
#include "../../driver.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <boolean.h>
|
||||
#include "../../general.h"
|
||||
#include "../keyboard_line.h"
|
||||
|
||||
#include "../../emscripten/RWebInput.h"
|
||||
#include "../input_joypad.h"
|
||||
|
||||
typedef struct rwebinput_state
|
||||
{
|
||||
uint8_t keys[32];
|
||||
int mouse_x;
|
||||
int mouse_y;
|
||||
char mouse_l;
|
||||
char mouse_r;
|
||||
} rwebinput_state_t;
|
||||
|
||||
int RWebInputInit(void);
|
||||
rwebinput_state_t *RWebInputPoll(int context);
|
||||
void RWebInputDestroy(int context);
|
||||
|
||||
static bool uninited = false;
|
||||
|
||||
typedef struct rwebinput_input
|
||||
|
Loading…
x
Reference in New Issue
Block a user