mirror of
https://github.com/melonDS-emu/melonDS.git
synced 2025-07-24 14:49:53 -06:00
actual DSi camera support (#1520)
basically feeding something that isn't a fixed stripe pattern, and emulating enough of the camera hardware to make this work
This commit is contained in:
@ -33,6 +33,7 @@
|
||||
#include "Platform.h"
|
||||
#include "Config.h"
|
||||
#include "ROMManager.h"
|
||||
#include "CameraManager.h"
|
||||
#include "LAN_Socket.h"
|
||||
#include "LAN_PCap.h"
|
||||
#include "LocalMP.h"
|
||||
@ -40,8 +41,11 @@
|
||||
|
||||
std::string EmuDirectory;
|
||||
|
||||
extern CameraManager* camManager[2];
|
||||
|
||||
void emuStop();
|
||||
|
||||
|
||||
namespace Platform
|
||||
{
|
||||
|
||||
@ -99,7 +103,6 @@ void IPCDeInit()
|
||||
IPCBuffer->detach();
|
||||
delete IPCBuffer;
|
||||
}
|
||||
|
||||
IPCBuffer = nullptr;
|
||||
}
|
||||
|
||||
@ -492,8 +495,6 @@ u16 MP_RecvReplies(u8* data, u64 timestamp, u16 aidmask)
|
||||
return LocalMP::RecvReplies(data, timestamp, aidmask);
|
||||
}
|
||||
|
||||
|
||||
|
||||
bool LAN_Init()
|
||||
{
|
||||
if (Config::DirectLAN)
|
||||
@ -537,4 +538,20 @@ int LAN_RecvPacket(u8* data)
|
||||
return LAN_Socket::RecvPacket(data);
|
||||
}
|
||||
|
||||
|
||||
void Camera_Start(int num)
|
||||
{
|
||||
return camManager[num]->start();
|
||||
}
|
||||
|
||||
void Camera_Stop(int num)
|
||||
{
|
||||
return camManager[num]->stop();
|
||||
}
|
||||
|
||||
void Camera_CaptureFrame(int num, u32* frame, int width, int height, bool yuv)
|
||||
{
|
||||
return camManager[num]->captureFrame(frame, width, height, yuv);
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user