mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-20 22:05:12 +00:00
commit
d18d19870f
159 changed files with 5702 additions and 5951 deletions
|
|
@ -284,16 +284,18 @@ void dmuxQueryAttr(u32 info_addr /* may be 0 */, vm::ptr<CellDmuxAttr> attr)
|
|||
attr->memSize = 0x10000; // 0x3e8e6 from ps3
|
||||
}
|
||||
|
||||
void dmuxQueryEsAttr(u32 info_addr /* may be 0 */, vm::ptr<const CellCodecEsFilterId> esFilterId,
|
||||
const u32 esSpecificInfo_addr, vm::ptr<CellDmuxEsAttr> attr)
|
||||
void dmuxQueryEsAttr(u32 info /* may be 0 */, vm::ptr<const CellCodecEsFilterId> esFilterId, u32 esSpecificInfo, vm::ptr<CellDmuxEsAttr> attr)
|
||||
{
|
||||
if (esFilterId->filterIdMajor >= 0xe0)
|
||||
{
|
||||
attr->memSize = 0x500000; // 0x45fa49 from ps3
|
||||
}
|
||||
else
|
||||
{
|
||||
attr->memSize = 0x7000; // 0x73d9 from ps3
|
||||
}
|
||||
|
||||
cellDmux.Warning("*** filter(0x%x, 0x%x, 0x%x, 0x%x)", (u32)esFilterId->filterIdMajor, (u32)esFilterId->filterIdMinor,
|
||||
(u32)esFilterId->supplementalInfo1, (u32)esFilterId->supplementalInfo2);
|
||||
cellDmux.Warning("*** filter(0x%x, 0x%x, 0x%x, 0x%x)", esFilterId->filterIdMajor, esFilterId->filterIdMinor, esFilterId->supplementalInfo1, esFilterId->supplementalInfo2);
|
||||
}
|
||||
|
||||
u32 dmuxOpen(Demuxer* dmux_ptr)
|
||||
|
|
@ -306,7 +308,7 @@ u32 dmuxOpen(Demuxer* dmux_ptr)
|
|||
dmux.id = dmux_id;
|
||||
|
||||
dmux.dmuxCb = static_cast<PPUThread*>(Emu.GetCPU().AddThread(CPU_THREAD_PPU).get());
|
||||
dmux.dmuxCb->SetName(fmt::format("Demuxer[%d] Callback", dmux_id));
|
||||
dmux.dmuxCb->SetName(fmt::format("Demuxer[0x%x] Callback", dmux_id));
|
||||
dmux.dmuxCb->SetEntry(0);
|
||||
dmux.dmuxCb->SetPrio(1001);
|
||||
dmux.dmuxCb->SetStackSize(0x10000);
|
||||
|
|
@ -314,7 +316,7 @@ u32 dmuxOpen(Demuxer* dmux_ptr)
|
|||
dmux.dmuxCb->InitRegs();
|
||||
dmux.dmuxCb->DoRun();
|
||||
|
||||
thread_t t(fmt::format("Demuxer[%d] Thread", dmux_id), [dmux_ptr, sptr]()
|
||||
thread_t t(fmt::format("Demuxer[0x%x] Thread", dmux_id), [dmux_ptr, sptr]()
|
||||
{
|
||||
Demuxer& dmux = *dmux_ptr;
|
||||
|
||||
|
|
@ -774,92 +776,92 @@ u32 dmuxOpen(Demuxer* dmux_ptr)
|
|||
return dmux_id;
|
||||
}
|
||||
|
||||
int cellDmuxQueryAttr(vm::ptr<const CellDmuxType> demuxerType, vm::ptr<CellDmuxAttr> demuxerAttr)
|
||||
s32 cellDmuxQueryAttr(vm::ptr<const CellDmuxType> type, vm::ptr<CellDmuxAttr> attr)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxQueryAttr(demuxerType_addr=0x%x, demuxerAttr_addr=0x%x)", demuxerType.addr(), demuxerAttr.addr());
|
||||
cellDmux.Warning("cellDmuxQueryAttr(type=*0x%x, attr=*0x%x)", type, attr);
|
||||
|
||||
if (demuxerType->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
if (type->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
||||
dmuxQueryAttr(0, demuxerAttr);
|
||||
dmuxQueryAttr(0, attr);
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxQueryAttr2(vm::ptr<const CellDmuxType2> demuxerType2, vm::ptr<CellDmuxAttr> demuxerAttr)
|
||||
s32 cellDmuxQueryAttr2(vm::ptr<const CellDmuxType2> type2, vm::ptr<CellDmuxAttr> attr)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxQueryAttr2(demuxerType2_addr=0x%x, demuxerAttr_addr=0x%x)", demuxerType2.addr(), demuxerAttr.addr());
|
||||
cellDmux.Warning("cellDmuxQueryAttr2(demuxerType2=*0x%x, demuxerAttr=*0x%x)", type2, attr);
|
||||
|
||||
if (demuxerType2->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
if (type2->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
||||
dmuxQueryAttr(demuxerType2->streamSpecificInfo_addr, demuxerAttr);
|
||||
dmuxQueryAttr(type2->streamSpecificInfo, attr);
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxOpen(vm::ptr<const CellDmuxType> demuxerType, vm::ptr<const CellDmuxResource> demuxerResource,
|
||||
vm::ptr<const CellDmuxCb> demuxerCb, vm::ptr<u32> demuxerHandle)
|
||||
s32 cellDmuxOpen(vm::ptr<const CellDmuxType> type, vm::ptr<const CellDmuxResource> res, vm::ptr<const CellDmuxCb> cb, vm::ptr<u32> handle)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxOpen(demuxerType_addr=0x%x, demuxerResource_addr=0x%x, demuxerCb_addr=0x%x, demuxerHandle_addr=0x%x)",
|
||||
demuxerType.addr(), demuxerResource.addr(), demuxerCb.addr(), demuxerHandle.addr());
|
||||
cellDmux.Warning("cellDmuxOpen(type=*0x%x, res=*0x%x, cb=*0x%x, handle=*0x%x)", type, res, cb, handle);
|
||||
|
||||
if (demuxerType->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
if (type->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
||||
// TODO: check demuxerResource and demuxerCb arguments
|
||||
|
||||
*demuxerHandle = dmuxOpen(new Demuxer(demuxerResource->memAddr, demuxerResource->memSize, demuxerCb->cbMsgFunc, demuxerCb->cbArg));
|
||||
*handle = dmuxOpen(new Demuxer(res->memAddr, res->memSize, cb->cbMsgFunc, cb->cbArg));
|
||||
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxOpenEx(vm::ptr<const CellDmuxType> demuxerType, vm::ptr<const CellDmuxResourceEx> demuxerResourceEx,
|
||||
vm::ptr<const CellDmuxCb> demuxerCb, vm::ptr<u32> demuxerHandle)
|
||||
s32 cellDmuxOpenEx(vm::ptr<const CellDmuxType> type, vm::ptr<const CellDmuxResourceEx> resEx, vm::ptr<const CellDmuxCb> cb, vm::ptr<u32> handle)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxOpenEx(demuxerType_addr=0x%x, demuxerResourceEx_addr=0x%x, demuxerCb_addr=0x%x, demuxerHandle_addr=0x%x)",
|
||||
demuxerType.addr(), demuxerResourceEx.addr(), demuxerCb.addr(), demuxerHandle.addr());
|
||||
cellDmux.Warning("cellDmuxOpenEx(type=*0x%x, resEx=*0x%x, cb=*0x%x, handle=*0x%x)", type, resEx, cb, handle);
|
||||
|
||||
if (demuxerType->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
if (type->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
||||
// TODO: check demuxerResourceEx and demuxerCb arguments
|
||||
|
||||
*demuxerHandle = dmuxOpen(new Demuxer(demuxerResourceEx->memAddr, demuxerResourceEx->memSize, demuxerCb->cbMsgFunc, demuxerCb->cbArg));
|
||||
*handle = dmuxOpen(new Demuxer(resEx->memAddr, resEx->memSize, cb->cbMsgFunc, cb->cbArg));
|
||||
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxOpen2(vm::ptr<const CellDmuxType2> demuxerType2, vm::ptr<const CellDmuxResource2> demuxerResource2,
|
||||
vm::ptr<const CellDmuxCb> demuxerCb, vm::ptr<u32> demuxerHandle)
|
||||
s32 _nid_e075fabc(vm::ptr<const CellDmuxType> type, vm::ptr<const CellDmuxResourceEx> resEx, vm::ptr<const CellDmuxCb> cb, vm::ptr<u32> handle)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxOpen2(demuxerType2_addr=0x%x, demuxerResource2_addr=0x%x, demuxerCb_addr=0x%x, demuxerHandle_addr=0x%x)",
|
||||
demuxerType2.addr(), demuxerResource2.addr(), demuxerCb.addr(), demuxerHandle.addr());
|
||||
return cellDmuxOpenEx(type, resEx, cb, handle);
|
||||
}
|
||||
|
||||
if (demuxerType2->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
s32 cellDmuxOpen2(vm::ptr<const CellDmuxType2> type2, vm::ptr<const CellDmuxResource2> res2, vm::ptr<const CellDmuxCb> cb, vm::ptr<u32> handle)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxOpen2(type2=*0x%x, res2=*0x%x, cb=*0x%x, handle=*0x%x)", type2, res2, cb, handle);
|
||||
|
||||
if (type2->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
||||
// TODO: check demuxerType2, demuxerResource2 and demuxerCb arguments
|
||||
|
||||
*demuxerHandle = dmuxOpen(new Demuxer(demuxerResource2->memAddr, demuxerResource2->memSize, demuxerCb->cbMsgFunc, demuxerCb->cbArg));
|
||||
*handle = dmuxOpen(new Demuxer(res2->memAddr, res2->memSize, cb->cbMsgFunc, cb->cbArg));
|
||||
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxClose(u32 demuxerHandle)
|
||||
s32 cellDmuxClose(u32 handle)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxClose(demuxerHandle=%d)", demuxerHandle);
|
||||
cellDmux.Warning("cellDmuxClose(handle=0x%x)", handle);
|
||||
|
||||
std::shared_ptr<Demuxer> dmux;
|
||||
if (!Emu.GetIdManager().GetIDData(demuxerHandle, dmux))
|
||||
const auto dmux = Emu.GetIdManager().GetIDData<Demuxer>(handle);
|
||||
|
||||
if (!dmux)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -871,7 +873,7 @@ int cellDmuxClose(u32 demuxerHandle)
|
|||
{
|
||||
if (Emu.IsStopped())
|
||||
{
|
||||
cellDmux.Warning("cellDmuxClose(%d) aborted", demuxerHandle);
|
||||
cellDmux.Warning("cellDmuxClose(%d) aborted", handle);
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
|
|
@ -879,17 +881,17 @@ int cellDmuxClose(u32 demuxerHandle)
|
|||
}
|
||||
|
||||
if (dmux->dmuxCb) Emu.GetCPU().RemoveThread(dmux->dmuxCb->GetId());
|
||||
Emu.GetIdManager().RemoveID<Demuxer>(demuxerHandle);
|
||||
Emu.GetIdManager().RemoveID<Demuxer>(handle);
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxSetStream(u32 demuxerHandle, const u32 streamAddress, u32 streamSize, bool discontinuity, u64 userData)
|
||||
s32 cellDmuxSetStream(u32 handle, u32 streamAddress, u32 streamSize, bool discontinuity, u64 userData)
|
||||
{
|
||||
cellDmux.Log("cellDmuxSetStream(demuxerHandle=%d, streamAddress=0x%x, streamSize=%d, discontinuity=%d, userData=0x%llx",
|
||||
demuxerHandle, streamAddress, streamSize, discontinuity, userData);
|
||||
cellDmux.Log("cellDmuxSetStream(handle=0x%x, streamAddress=0x%x, streamSize=%d, discontinuity=%d, userData=0x%llx)", handle, streamAddress, streamSize, discontinuity, userData);
|
||||
|
||||
std::shared_ptr<Demuxer> dmux;
|
||||
if (!Emu.GetIdManager().GetIDData(demuxerHandle, dmux))
|
||||
const auto dmux = Emu.GetIdManager().GetIDData<Demuxer>(handle);
|
||||
|
||||
if (!dmux)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -911,12 +913,13 @@ int cellDmuxSetStream(u32 demuxerHandle, const u32 streamAddress, u32 streamSize
|
|||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxResetStream(u32 demuxerHandle)
|
||||
s32 cellDmuxResetStream(u32 handle)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxResetStream(demuxerHandle=%d)", demuxerHandle);
|
||||
cellDmux.Warning("cellDmuxResetStream(handle=0x%x)", handle);
|
||||
|
||||
std::shared_ptr<Demuxer> dmux;
|
||||
if (!Emu.GetIdManager().GetIDData(demuxerHandle, dmux))
|
||||
const auto dmux = Emu.GetIdManager().GetIDData<Demuxer>(handle);
|
||||
|
||||
if (!dmux)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -925,12 +928,13 @@ int cellDmuxResetStream(u32 demuxerHandle)
|
|||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxResetStreamAndWaitDone(u32 demuxerHandle)
|
||||
s32 cellDmuxResetStreamAndWaitDone(u32 handle)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxResetStreamAndWaitDone(demuxerHandle=%d)", demuxerHandle);
|
||||
cellDmux.Warning("cellDmuxResetStreamAndWaitDone(handle=0x%x)", handle);
|
||||
|
||||
std::shared_ptr<Demuxer> dmux;
|
||||
if (!Emu.GetIdManager().GetIDData(demuxerHandle, dmux))
|
||||
const auto dmux = Emu.GetIdManager().GetIDData<Demuxer>(handle);
|
||||
|
||||
if (!dmux)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -948,7 +952,7 @@ int cellDmuxResetStreamAndWaitDone(u32 demuxerHandle)
|
|||
{
|
||||
if (Emu.IsStopped())
|
||||
{
|
||||
cellDmux.Warning("cellDmuxResetStreamAndWaitDone(%d) aborted", demuxerHandle);
|
||||
cellDmux.Warning("cellDmuxResetStreamAndWaitDone(%d) aborted", handle);
|
||||
return CELL_OK;
|
||||
}
|
||||
std::this_thread::sleep_for(std::chrono::milliseconds(1)); // hack
|
||||
|
|
@ -957,48 +961,41 @@ int cellDmuxResetStreamAndWaitDone(u32 demuxerHandle)
|
|||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxQueryEsAttr(vm::ptr<const CellDmuxType> demuxerType, vm::ptr<const CellCodecEsFilterId> esFilterId,
|
||||
const u32 esSpecificInfo_addr, vm::ptr<CellDmuxEsAttr> esAttr)
|
||||
s32 cellDmuxQueryEsAttr(vm::ptr<const CellDmuxType> type, vm::ptr<const CellCodecEsFilterId> esFilterId, u32 esSpecificInfo, vm::ptr<CellDmuxEsAttr> esAttr)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxQueryEsAttr(demuxerType_addr=0x%x, esFilterId_addr=0x%x, esSpecificInfo_addr=0x%x, esAttr_addr=0x%x)",
|
||||
demuxerType.addr(), esFilterId.addr(), esSpecificInfo_addr, esAttr.addr());
|
||||
cellDmux.Warning("cellDmuxQueryEsAttr(demuxerType=*0x%x, esFilterId=*0x%x, esSpecificInfo=*0x%x, esAttr=*0x%x)", type, esFilterId, esSpecificInfo, esAttr);
|
||||
|
||||
if (demuxerType->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
if (type->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
||||
// TODO: check esFilterId and esSpecificInfo correctly
|
||||
dmuxQueryEsAttr(0, esFilterId, esSpecificInfo_addr, esAttr);
|
||||
dmuxQueryEsAttr(0, esFilterId, esSpecificInfo, esAttr);
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxQueryEsAttr2(vm::ptr<const CellDmuxType2> demuxerType2, vm::ptr<const CellCodecEsFilterId> esFilterId,
|
||||
const u32 esSpecificInfo_addr, vm::ptr<CellDmuxEsAttr> esAttr)
|
||||
s32 cellDmuxQueryEsAttr2(vm::ptr<const CellDmuxType2> type2, vm::ptr<const CellCodecEsFilterId> esFilterId, u32 esSpecificInfo, vm::ptr<CellDmuxEsAttr> esAttr)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxQueryEsAttr2(demuxerType2_addr=0x%x, esFilterId_addr=0x%x, esSpecificInfo_addr=0x%x, esAttr_addr=0x%x)",
|
||||
demuxerType2.addr(), esFilterId.addr(), esSpecificInfo_addr, esAttr.addr());
|
||||
cellDmux.Warning("cellDmuxQueryEsAttr2(type2=*0x%x, esFilterId=*0x%x, esSpecificInfo=*0x%x, esAttr=*0x%x)", type2, esFilterId, esSpecificInfo, esAttr);
|
||||
|
||||
if (demuxerType2->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
if (type2->streamType != CELL_DMUX_STREAM_TYPE_PAMF)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
||||
// TODO: check demuxerType2, esFilterId and esSpecificInfo correctly
|
||||
dmuxQueryEsAttr(demuxerType2->streamSpecificInfo_addr, esFilterId, esSpecificInfo_addr, esAttr);
|
||||
dmuxQueryEsAttr(type2->streamSpecificInfo, esFilterId, esSpecificInfo, esAttr);
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxEnableEs(u32 demuxerHandle, vm::ptr<const CellCodecEsFilterId> esFilterId,
|
||||
vm::ptr<const CellDmuxEsResource> esResourceInfo, vm::ptr<const CellDmuxEsCb> esCb,
|
||||
const u32 esSpecificInfo_addr, vm::ptr<u32> esHandle)
|
||||
s32 cellDmuxEnableEs(u32 handle, vm::ptr<const CellCodecEsFilterId> esFilterId, vm::ptr<const CellDmuxEsResource> esResourceInfo, vm::ptr<const CellDmuxEsCb> esCb, u32 esSpecificInfo, vm::ptr<u32> esHandle)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxEnableEs(demuxerHandle=%d, esFilterId_addr=0x%x, esResourceInfo_addr=0x%x, esCb_addr=0x%x, "
|
||||
"esSpecificInfo_addr=0x%x, esHandle_addr=0x%x)", demuxerHandle, esFilterId.addr(), esResourceInfo.addr(),
|
||||
esCb.addr(), esSpecificInfo_addr, esHandle.addr());
|
||||
cellDmux.Warning("cellDmuxEnableEs(handle=0x%x, esFilterId=*0x%x, esResourceInfo=*0x%x, esCb=*0x%x, esSpecificInfo=*0x%x, esHandle=*0x%x)", handle, esFilterId, esResourceInfo, esCb, esSpecificInfo, esHandle);
|
||||
|
||||
std::shared_ptr<Demuxer> dmux;
|
||||
if (!Emu.GetIdManager().GetIDData(demuxerHandle, dmux))
|
||||
const auto dmux = Emu.GetIdManager().GetIDData<Demuxer>(handle);
|
||||
|
||||
if (!dmux)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -1007,14 +1004,14 @@ int cellDmuxEnableEs(u32 demuxerHandle, vm::ptr<const CellCodecEsFilterId> esFil
|
|||
|
||||
std::shared_ptr<ElementaryStream> es(new ElementaryStream(dmux.get(), esResourceInfo->memAddr, esResourceInfo->memSize,
|
||||
esFilterId->filterIdMajor, esFilterId->filterIdMinor, esFilterId->supplementalInfo1, esFilterId->supplementalInfo2,
|
||||
esCb->cbEsMsgFunc, esCb->cbArg, esSpecificInfo_addr));
|
||||
esCb->cbEsMsgFunc, esCb->cbArg, esSpecificInfo));
|
||||
|
||||
u32 id = Emu.GetIdManager().GetNewID(es);
|
||||
es->id = id;
|
||||
*esHandle = id;
|
||||
|
||||
cellDmux.Warning("*** New ES(dmux=%d, addr=0x%x, size=0x%x, filter(0x%x, 0x%x, 0x%x, 0x%x), cb=0x%x(arg=0x%x), spec=0x%x): id = %d",
|
||||
demuxerHandle, es->memAddr, es->memSize, es->fidMajor, es->fidMinor, es->sup1, es->sup2, es->cbFunc, es->cbArg, es->spec, id);
|
||||
cellDmux.Warning("*** New ES(dmux=0x%x, addr=0x%x, size=0x%x, filter={0x%x, 0x%x, 0x%x, 0x%x}, cb=0x%x, arg=0x%x, spec=0x%x): id = %d",
|
||||
handle, es->memAddr, es->memSize, es->fidMajor, es->fidMinor, es->sup1, es->sup2, es->cbFunc, es->cbArg, es->spec, id);
|
||||
|
||||
DemuxerTask task(dmuxEnableEs);
|
||||
task.es.es = id;
|
||||
|
|
@ -1024,12 +1021,13 @@ int cellDmuxEnableEs(u32 demuxerHandle, vm::ptr<const CellCodecEsFilterId> esFil
|
|||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxDisableEs(u32 esHandle)
|
||||
s32 cellDmuxDisableEs(u32 esHandle)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxDisableEs(esHandle=0x%x)", esHandle);
|
||||
|
||||
std::shared_ptr<ElementaryStream> es;
|
||||
if (!Emu.GetIdManager().GetIDData(esHandle, es))
|
||||
const auto es = Emu.GetIdManager().GetIDData<ElementaryStream>(esHandle);
|
||||
|
||||
if (!es)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -1042,12 +1040,13 @@ int cellDmuxDisableEs(u32 esHandle)
|
|||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxResetEs(u32 esHandle)
|
||||
s32 cellDmuxResetEs(u32 esHandle)
|
||||
{
|
||||
cellDmux.Log("cellDmuxResetEs(esHandle=0x%x)", esHandle);
|
||||
|
||||
std::shared_ptr<ElementaryStream> es;
|
||||
if (!Emu.GetIdManager().GetIDData(esHandle, es))
|
||||
const auto es = Emu.GetIdManager().GetIDData<ElementaryStream>(esHandle);
|
||||
|
||||
if (!es)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -1060,13 +1059,13 @@ int cellDmuxResetEs(u32 esHandle)
|
|||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxGetAu(u32 esHandle, vm::ptr<u32> auInfo_ptr, vm::ptr<u32> auSpecificInfo_ptr)
|
||||
s32 cellDmuxGetAu(u32 esHandle, vm::ptr<u32> auInfo, vm::ptr<u32> auSpecificInfo)
|
||||
{
|
||||
cellDmux.Log("cellDmuxGetAu(esHandle=0x%x, auInfo_ptr_addr=0x%x, auSpecificInfo_ptr_addr=0x%x)",
|
||||
esHandle, auInfo_ptr.addr(), auSpecificInfo_ptr.addr());
|
||||
cellDmux.Log("cellDmuxGetAu(esHandle=0x%x, auInfo=**0x%x, auSpecificInfo=**0x%x)", esHandle, auInfo, auSpecificInfo);
|
||||
|
||||
std::shared_ptr<ElementaryStream> es;
|
||||
if (!Emu.GetIdManager().GetIDData(esHandle, es))
|
||||
const auto es = Emu.GetIdManager().GetIDData<ElementaryStream>(esHandle);
|
||||
|
||||
if (!es)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -1078,18 +1077,18 @@ int cellDmuxGetAu(u32 esHandle, vm::ptr<u32> auInfo_ptr, vm::ptr<u32> auSpecific
|
|||
return CELL_DMUX_ERROR_EMPTY;
|
||||
}
|
||||
|
||||
*auInfo_ptr = info;
|
||||
*auSpecificInfo_ptr = spec;
|
||||
*auInfo = info;
|
||||
*auSpecificInfo = spec;
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxPeekAu(u32 esHandle, vm::ptr<u32> auInfo_ptr, vm::ptr<u32> auSpecificInfo_ptr)
|
||||
s32 cellDmuxPeekAu(u32 esHandle, vm::ptr<u32> auInfo, vm::ptr<u32> auSpecificInfo)
|
||||
{
|
||||
cellDmux.Log("cellDmuxPeekAu(esHandle=0x%x, auInfo_ptr_addr=0x%x, auSpecificInfo_ptr_addr=0x%x)",
|
||||
esHandle, auInfo_ptr.addr(), auSpecificInfo_ptr.addr());
|
||||
cellDmux.Log("cellDmuxPeekAu(esHandle=0x%x, auInfo=**0x%x, auSpecificInfo=**0x%x)", esHandle, auInfo, auSpecificInfo);
|
||||
|
||||
std::shared_ptr<ElementaryStream> es;
|
||||
if (!Emu.GetIdManager().GetIDData(esHandle, es))
|
||||
const auto es = Emu.GetIdManager().GetIDData<ElementaryStream>(esHandle);
|
||||
|
||||
if (!es)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -1101,18 +1100,18 @@ int cellDmuxPeekAu(u32 esHandle, vm::ptr<u32> auInfo_ptr, vm::ptr<u32> auSpecifi
|
|||
return CELL_DMUX_ERROR_EMPTY;
|
||||
}
|
||||
|
||||
*auInfo_ptr = info;
|
||||
*auSpecificInfo_ptr = spec;
|
||||
*auInfo = info;
|
||||
*auSpecificInfo = spec;
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxGetAuEx(u32 esHandle, vm::ptr<u32> auInfoEx_ptr, vm::ptr<u32> auSpecificInfo_ptr)
|
||||
s32 cellDmuxGetAuEx(u32 esHandle, vm::ptr<u32> auInfoEx, vm::ptr<u32> auSpecificInfo)
|
||||
{
|
||||
cellDmux.Log("cellDmuxGetAuEx(esHandle=0x%x, auInfoEx_ptr_addr=0x%x, auSpecificInfo_ptr_addr=0x%x)",
|
||||
esHandle, auInfoEx_ptr.addr(), auSpecificInfo_ptr.addr());
|
||||
cellDmux.Log("cellDmuxGetAuEx(esHandle=0x%x, auInfoEx=**0x%x, auSpecificInfo=**0x%x)", esHandle, auInfoEx, auSpecificInfo);
|
||||
|
||||
std::shared_ptr<ElementaryStream> es;
|
||||
if (!Emu.GetIdManager().GetIDData(esHandle, es))
|
||||
const auto es = Emu.GetIdManager().GetIDData<ElementaryStream>(esHandle);
|
||||
|
||||
if (!es)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -1124,18 +1123,18 @@ int cellDmuxGetAuEx(u32 esHandle, vm::ptr<u32> auInfoEx_ptr, vm::ptr<u32> auSpec
|
|||
return CELL_DMUX_ERROR_EMPTY;
|
||||
}
|
||||
|
||||
*auInfoEx_ptr = info;
|
||||
*auSpecificInfo_ptr = spec;
|
||||
*auInfoEx = info;
|
||||
*auSpecificInfo = spec;
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxPeekAuEx(u32 esHandle, vm::ptr<u32> auInfoEx_ptr, vm::ptr<u32> auSpecificInfo_ptr)
|
||||
s32 cellDmuxPeekAuEx(u32 esHandle, vm::ptr<u32> auInfoEx, vm::ptr<u32> auSpecificInfo)
|
||||
{
|
||||
cellDmux.Log("cellDmuxPeekAuEx(esHandle=0x%x, auInfoEx_ptr_addr=0x%x, auSpecificInfo_ptr_addr=0x%x)",
|
||||
esHandle, auInfoEx_ptr.addr(), auSpecificInfo_ptr.addr());
|
||||
cellDmux.Log("cellDmuxPeekAuEx(esHandle=0x%x, auInfoEx=**0x%x, auSpecificInfo=**0x%x)", esHandle, auInfoEx, auSpecificInfo);
|
||||
|
||||
std::shared_ptr<ElementaryStream> es;
|
||||
if (!Emu.GetIdManager().GetIDData(esHandle, es))
|
||||
const auto es = Emu.GetIdManager().GetIDData<ElementaryStream>(esHandle);
|
||||
|
||||
if (!es)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -1147,17 +1146,18 @@ int cellDmuxPeekAuEx(u32 esHandle, vm::ptr<u32> auInfoEx_ptr, vm::ptr<u32> auSpe
|
|||
return CELL_DMUX_ERROR_EMPTY;
|
||||
}
|
||||
|
||||
*auInfoEx_ptr = info;
|
||||
*auSpecificInfo_ptr = spec;
|
||||
*auInfoEx = info;
|
||||
*auSpecificInfo = spec;
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxReleaseAu(u32 esHandle)
|
||||
s32 cellDmuxReleaseAu(u32 esHandle)
|
||||
{
|
||||
cellDmux.Log("cellDmuxReleaseAu(esHandle=0x%x)", esHandle);
|
||||
|
||||
std::shared_ptr<ElementaryStream> es;
|
||||
if (!Emu.GetIdManager().GetIDData(esHandle, es))
|
||||
const auto es = Emu.GetIdManager().GetIDData<ElementaryStream>(esHandle);
|
||||
|
||||
if (!es)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -1169,12 +1169,13 @@ int cellDmuxReleaseAu(u32 esHandle)
|
|||
return CELL_OK;
|
||||
}
|
||||
|
||||
int cellDmuxFlushEs(u32 esHandle)
|
||||
s32 cellDmuxFlushEs(u32 esHandle)
|
||||
{
|
||||
cellDmux.Warning("cellDmuxFlushEs(esHandle=0x%x)", esHandle);
|
||||
|
||||
std::shared_ptr<ElementaryStream> es;
|
||||
if (!Emu.GetIdManager().GetIDData(esHandle, es))
|
||||
const auto es = Emu.GetIdManager().GetIDData<ElementaryStream>(esHandle);
|
||||
|
||||
if (!es)
|
||||
{
|
||||
return CELL_DMUX_ERROR_ARG;
|
||||
}
|
||||
|
|
@ -1193,6 +1194,7 @@ Module cellDmux("cellDmux", []()
|
|||
REG_FUNC(cellDmux, cellDmuxQueryAttr2);
|
||||
REG_FUNC(cellDmux, cellDmuxOpen);
|
||||
REG_FUNC(cellDmux, cellDmuxOpenEx);
|
||||
REG_UNNAMED(cellDmux, e075fabc);
|
||||
REG_FUNC(cellDmux, cellDmuxOpen2);
|
||||
REG_FUNC(cellDmux, cellDmuxClose);
|
||||
REG_FUNC(cellDmux, cellDmuxSetStream);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue