2020-02-15 23:36:20 +01:00
# include " stdafx.h "
# include "Emu/VFS.h"
2016-03-21 20:43:03 +01:00
# include "Emu/Cell/PPUModule.h"
2014-08-24 00:34:04 +02:00
2014-08-02 10:20:48 +02:00
# include "cellSail.h"
2014-12-24 19:47:56 +01:00
# include "cellPamf.h"
2014-08-02 10:20:48 +02:00
2018-08-25 14:39:00 +02:00
LOG_CHANNEL ( cellSail ) ;
2013-09-28 04:36:57 +02:00
2015-07-09 17:30:37 +02:00
s32 cellSailMemAllocatorInitialize ( vm : : ptr < CellSailMemAllocator > pSelf , vm : : ptr < CellSailMemAllocatorFuncs > pCallbacks )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailMemAllocatorInitialize(pSelf=*0x%x, pCallbacks=*0x%x) " , pSelf , pCallbacks ) ;
2014-10-17 15:20:40 +02:00
pSelf - > callbacks = pCallbacks ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-11 18:48:02 +02:00
s32 cellSailFutureInitialize ( vm : : ptr < CellSailFuture > pSelf )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailFutureInitialize(pSelf=*0x%x) " , pSelf ) ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-11 18:48:02 +02:00
s32 cellSailFutureFinalize ( vm : : ptr < CellSailFuture > pSelf )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailFutureFinalize(pSelf=*0x%x) " , pSelf ) ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-11 18:48:02 +02:00
s32 cellSailFutureReset ( vm : : ptr < CellSailFuture > pSelf , b8 wait )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailFutureReset(pSelf=*0x%x, wait=%d) " , pSelf , wait ) ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-11 18:48:02 +02:00
s32 cellSailFutureSet ( vm : : ptr < CellSailFuture > pSelf , s32 result )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailFutureSet(pSelf=*0x%x, result=%d) " , pSelf , result ) ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-11 18:48:02 +02:00
s32 cellSailFutureGet ( vm : : ptr < CellSailFuture > pSelf , u64 timeout , vm : : ptr < s32 > pResult )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailFutureGet(pSelf=*0x%x, timeout=%lld, result=*0x%x) " , pSelf , timeout , pResult ) ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-11 18:48:02 +02:00
s32 cellSailFutureIsDone ( vm : : ptr < CellSailFuture > pSelf , vm : : ptr < s32 > pResult )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailFutureIsDone(pSelf=*0x%x, result=*0x%x) " , pSelf , pResult ) ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorGetStreamType ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorGetUri ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorGetMediaInfo ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-26 02:53:26 +02:00
s32 cellSailDescriptorSetAutoSelection ( vm : : ptr < CellSailDescriptor > pSelf , b8 autoSelection )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailDescriptorSetAutoSelection(pSelf=*0x%x, autoSelection=%d) " , pSelf , autoSelection ) ;
2014-10-17 15:20:40 +02:00
2015-08-10 14:10:16 +02:00
if ( pSelf )
{
2014-11-15 15:45:02 +01:00
pSelf - > autoSelection = autoSelection ;
return autoSelection ;
}
2014-10-17 15:20:40 +02:00
2014-11-15 15:45:02 +01:00
return CELL_OK ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorIsAutoSelection ( vm : : ptr < CellSailDescriptor > pSelf )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailDescriptorIsAutoSelection(pSelf=*0x%x) " , pSelf ) ;
2018-08-25 14:39:00 +02:00
2014-11-15 15:45:02 +01:00
if ( pSelf )
2015-08-10 14:10:16 +02:00
{
2014-11-15 15:45:02 +01:00
return pSelf - > autoSelection ;
2015-08-10 14:10:16 +02:00
}
2014-11-15 15:45:02 +01:00
return CELL_OK ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorCreateDatabase ( vm : : ptr < CellSailDescriptor > pSelf , vm : : ptr < void > pDatabase , u32 size , u64 arg )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailDescriptorCreateDatabase(pSelf=*0x%x, pDatabase=*0x%x, size=0x%x, arg=0x%llx) " , pSelf , pDatabase , size , arg ) ;
2014-12-24 19:47:56 +01:00
2019-12-02 22:31:34 +01:00
switch ( pSelf - > streamType )
2015-08-10 14:10:16 +02:00
{
2014-12-24 19:47:56 +01:00
case CELL_SAIL_STREAM_PAMF :
{
2015-08-10 14:10:16 +02:00
u32 addr = pSelf - > sp_ ;
2014-12-24 19:47:56 +01:00
auto ptr = vm : : ptr < CellPamfReader > : : make ( addr ) ;
memcpy ( pDatabase . get_ptr ( ) , ptr . get_ptr ( ) , sizeof ( CellPamfReader ) ) ;
break ;
}
default :
2016-01-12 22:57:16 +01:00
cellSail . error ( " Unhandled stream type: %d " , pSelf - > streamType ) ;
2014-12-24 19:47:56 +01:00
}
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorDestroyDatabase ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorOpen ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorClose ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorSetEs ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorClearEs ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorGetCapabilities ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorInquireCapability ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailDescriptorSetParameter ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailSoundAdapterInitialize ( vm : : ptr < CellSailSoundAdapter > pSelf , vm : : cptr < CellSailSoundAdapterFuncs > pCallbacks , vm : : ptr < void > pArg )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailSoundAdapterInitialize(pSelf=*0x%x, pCallbacks=*0x%x, pArg=*0x%x) " , pSelf , pCallbacks , pArg ) ;
2015-08-10 14:10:16 +02:00
if ( pSelf - > initialized )
{
return CELL_SAIL_ERROR_INVALID_STATE ;
}
if ( pSelf - > registered )
{
return CELL_SAIL_ERROR_INVALID_STATE ;
}
pSelf - > pMakeup = pCallbacks - > pMakeup ;
pSelf - > pCleanup = pCallbacks - > pCleanup ;
pSelf - > pFormatChanged = pCallbacks - > pFormatChanged ;
pSelf - > arg = pArg ;
pSelf - > initialized = true ;
pSelf - > registered = false ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailSoundAdapterFinalize ( vm : : ptr < CellSailSoundAdapter > pSelf )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailSoundAdapterFinalize(pSelf=*0x%x) " , pSelf ) ;
2015-08-10 14:10:16 +02:00
if ( ! pSelf - > initialized )
{
return CELL_SAIL_ERROR_INVALID_STATE ;
}
if ( pSelf - > registered )
{
return CELL_SAIL_ERROR_INVALID_STATE ;
}
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailSoundAdapterSetPreferredFormat ( vm : : ptr < CellSailSoundAdapter > pSelf , vm : : cptr < CellSailAudioFormat > pFormat )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailSoundAdapterSetPreferredFormat(pSelf=*0x%x, pFormat=*0x%x) " , pSelf , pFormat ) ;
2015-08-10 14:10:16 +02:00
pSelf - > format = * pFormat ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailSoundAdapterGetFrame ( vm : : ptr < CellSailSoundAdapter > pSelf , u32 samples , vm : : ptr < CellSailSoundFrameInfo > pInfo )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailSoundAdapterGetFrame(pSelf=*0x%x, samples=%d, pInfo=*0x%x) " , pSelf , samples , pInfo ) ;
2015-08-10 14:10:16 +02:00
if ( ! pSelf - > initialized )
{
return CELL_SAIL_ERROR_INVALID_STATE ;
}
if ( pSelf - > registered )
{
return CELL_SAIL_ERROR_INVALID_STATE ;
}
if ( samples > 2048 )
{
return CELL_SAIL_ERROR_INVALID_ARG ;
}
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailSoundAdapterGetFormat ( vm : : ptr < CellSailSoundAdapter > pSelf , vm : : ptr < CellSailAudioFormat > pFormat )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailSoundAdapterGetFormat(pSelf=*0x%x, pFormat=*0x%x) " , pSelf , pFormat ) ;
2015-08-10 14:10:16 +02:00
* pFormat = pSelf - > format ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailSoundAdapterUpdateAvSync ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailSoundAdapterPtsToTimePosition ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailGraphicsAdapterInitialize ( vm : : ptr < CellSailGraphicsAdapter > pSelf , vm : : cptr < CellSailGraphicsAdapterFuncs > pCallbacks , vm : : ptr < void > pArg )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailGraphicsAdapterInitialize(pSelf=*0x%x, pCallbacks=*0x%x, pArg=*0x%x) " , pSelf , pCallbacks , pArg ) ;
2015-08-10 14:10:16 +02:00
if ( pSelf - > initialized )
{
return CELL_SAIL_ERROR_INVALID_STATE ;
}
if ( pSelf - > registered )
{
return CELL_SAIL_ERROR_INVALID_STATE ;
}
pSelf - > pMakeup = pCallbacks - > pMakeup ;
pSelf - > pCleanup = pCallbacks - > pCleanup ;
pSelf - > pFormatChanged = pCallbacks - > pFormatChanged ;
pSelf - > pAlloc = pCallbacks - > pAlloc ;
pSelf - > pFree = pCallbacks - > pFree ;
pSelf - > arg = pArg ;
pSelf - > initialized = true ;
pSelf - > registered = true ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailGraphicsAdapterFinalize ( vm : : ptr < CellSailGraphicsAdapter > pSelf )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailGraphicsAdapterFinalize(pSelf=*0x%x) " , pSelf ) ;
2015-08-10 14:10:16 +02:00
if ( ! pSelf - > initialized )
{
return CELL_SAIL_ERROR_INVALID_STATE ;
}
if ( pSelf - > registered )
{
return CELL_SAIL_ERROR_INVALID_STATE ;
}
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailGraphicsAdapterSetPreferredFormat ( vm : : ptr < CellSailGraphicsAdapter > pSelf , vm : : cptr < CellSailVideoFormat > pFormat )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailGraphicsAdapterSetPreferredFormat(pSelf=*0x%x, pFormat=*0x%x) " , pSelf , pFormat ) ;
2015-08-10 14:10:16 +02:00
pSelf - > format = * pFormat ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailGraphicsAdapterGetFrame ( vm : : ptr < CellSailGraphicsAdapter > pSelf , vm : : ptr < CellSailGraphicsFrameInfo > pInfo )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailGraphicsAdapterGetFrame(pSelf=*0x%x, pInfo=*0x%x) " , pSelf , pInfo ) ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailGraphicsAdapterGetFrame2 ( vm : : ptr < CellSailGraphicsAdapter > pSelf , vm : : ptr < CellSailGraphicsFrameInfo > pInfo , vm : : ptr < CellSailGraphicsFrameInfo > pPrevInfo , vm : : ptr < u64 > pFlipTime , u64 flags )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailGraphicsAdapterGetFrame2(pSelf=*0x%x, pInfo=*0x%x, pPrevInfo=*0x%x, flipTime=*0x%x, flags=0x%llx) " , pSelf , pInfo , pPrevInfo , pFlipTime , flags ) ;
2015-08-11 18:48:02 +02:00
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailGraphicsAdapterGetFormat ( vm : : ptr < CellSailGraphicsAdapter > pSelf , vm : : ptr < CellSailVideoFormat > pFormat )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailGraphicsAdapterGetFormat(pSelf=*0x%x, pFormat=*0x%x) " , pSelf , pFormat ) ;
2015-08-10 14:10:16 +02:00
* pFormat = pSelf - > format ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailGraphicsAdapterUpdateAvSync ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailGraphicsAdapterPtsToTimePosition ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailAuReceiverInitialize ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailAuReceiverFinalize ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailAuReceiverGet ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailRendererAudioInitialize ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailRendererAudioFinalize ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailRendererAudioNotifyCallCompleted ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailRendererAudioNotifyFrameDone ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailRendererAudioNotifyOutputEos ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailRendererVideoInitialize ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailRendererVideoFinalize ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailRendererVideoNotifyCallCompleted ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailRendererVideoNotifyFrameDone ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailRendererVideoNotifyOutputEos ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceInitialize ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceFinalize ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceNotifyCallCompleted ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceNotifyInputEos ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceNotifyStreamOut ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceNotifySessionError ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceNotifyMediaStateChanged ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceNotifyOpenCompleted ( )
2013-09-28 04:36:57 +02:00
{
2016-08-08 18:01:06 +02:00
fmt : : throw_exception ( " Unexpected function " HERE ) ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceNotifyStartCompleted ( )
2013-09-28 04:36:57 +02:00
{
2016-08-08 18:01:06 +02:00
fmt : : throw_exception ( " Unexpected function " HERE ) ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceNotifyStopCompleted ( )
2013-09-28 04:36:57 +02:00
{
2016-08-08 18:01:06 +02:00
fmt : : throw_exception ( " Unexpected function " HERE ) ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceNotifyReadCompleted ( )
2013-09-28 04:36:57 +02:00
{
2016-08-08 18:01:06 +02:00
fmt : : throw_exception ( " Unexpected function " HERE ) ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceSetDiagHandler ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailSourceNotifyCloseCompleted ( )
2013-09-28 04:36:57 +02:00
{
2016-08-08 18:01:06 +02:00
fmt : : throw_exception ( " Unexpected function " HERE ) ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailMp4MovieGetBrand ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailMp4MovieIsCompatibleBrand ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailMp4MovieGetMovieInfo ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailMp4MovieGetTrackByIndex ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailMp4MovieGetTrackById ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailMp4MovieGetTrackByTypeAndIndex ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailMp4TrackGetTrackInfo ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailMp4TrackGetTrackReferenceCount ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailMp4TrackGetTrackReference ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailAviMovieGetMovieInfo ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailAviMovieGetStreamByIndex ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailAviMovieGetStreamByTypeAndIndex ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailAviMovieGetHeader ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailAviStreamGetMediaType ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailAviStreamGetHeader ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerInitialize ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2016-07-27 23:43:22 +02:00
s32 cellSailPlayerInitialize2 ( ppu_thread & ppu ,
2015-07-27 16:59:21 +02:00
vm : : ptr < CellSailPlayer > pSelf ,
vm : : ptr < CellSailMemAllocator > pAllocator ,
vm : : ptr < CellSailPlayerFuncNotified > pCallback ,
vm : : ptr < void > callbackArg ,
vm : : ptr < CellSailPlayerAttribute > pAttribute ,
vm : : ptr < CellSailPlayerResource > pResource )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailPlayerInitialize2(pSelf=*0x%x, pAllocator=*0x%x, pCallback=*0x%x, callbackArg=*0x%x, pAttribute=*0x%x, pResource=*0x%x) " ,
2015-07-27 16:59:21 +02:00
pSelf , pAllocator , pCallback , callbackArg , pAttribute , pResource ) ;
2014-10-17 15:20:40 +02:00
2015-07-27 16:59:21 +02:00
pSelf - > allocator = * pAllocator ;
2014-10-17 15:20:40 +02:00
pSelf - > callback = pCallback ;
2015-07-27 16:59:21 +02:00
pSelf - > callbackArg = callbackArg ;
pSelf - > attribute = * pAttribute ;
pSelf - > resource = * pResource ;
2015-08-10 17:58:10 +02:00
pSelf - > booted = false ;
2015-07-27 16:59:21 +02:00
pSelf - > paused = true ;
2014-10-17 15:20:40 +02:00
2015-08-11 18:48:02 +02:00
{
CellSailEvent event ;
2015-09-13 09:26:01 +02:00
event . u32x2 . major = CELL_SAIL_EVENT_PLAYER_STATE_CHANGED ;
event . u32x2 . minor = 0 ;
2015-09-26 22:46:04 +02:00
pSelf - > callback ( ppu , pSelf - > callbackArg , event , CELL_SAIL_PLAYER_STATE_INITIALIZED , 0 ) ;
2016-07-27 23:43:22 +02:00
} ;
2015-08-11 18:48:02 +02:00
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailPlayerFinalize ( vm : : ptr < CellSailPlayer > pSelf )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailPlayerFinalize(pSelf=*0x%x) " , pSelf ) ;
2015-08-10 14:10:16 +02:00
if ( pSelf - > sAdapter )
{
pSelf - > sAdapter - > registered = false ;
}
if ( pSelf - > gAdapter )
{
pSelf - > gAdapter - > registered = false ;
}
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerRegisterSource ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerGetRegisteredProtocols ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailPlayerSetSoundAdapter ( vm : : ptr < CellSailPlayer > pSelf , u32 index , vm : : ptr < CellSailSoundAdapter > pAdapter )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailPlayerSetSoundAdapter(pSelf=*0x%x, index=%d, pAdapter=*0x%x) " , pSelf , index , pAdapter ) ;
2015-08-10 14:10:16 +02:00
if ( index > pSelf - > attribute . maxAudioStreamNum )
{
return CELL_SAIL_ERROR_INVALID_ARG ;
}
pSelf - > sAdapter = pAdapter ;
pAdapter - > index = index ;
pAdapter - > registered = true ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailPlayerSetGraphicsAdapter ( vm : : ptr < CellSailPlayer > pSelf , u32 index , vm : : ptr < CellSailGraphicsAdapter > pAdapter )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailPlayerSetGraphicsAdapter(pSelf=*0x%x, index=%d, pAdapter=*0x%x) " , pSelf , index , pAdapter ) ;
2015-08-10 14:10:16 +02:00
if ( index > pSelf - > attribute . maxVideoStreamNum )
{
return CELL_SAIL_ERROR_INVALID_ARG ;
}
pSelf - > gAdapter = pAdapter ;
pAdapter - > index = index ;
pAdapter - > registered = true ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerSetAuReceiver ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerSetRendererAudio ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerSetRendererVideo ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailPlayerSetParameter ( vm : : ptr < CellSailPlayer > pSelf , s32 parameterType , u64 param0 , u64 param1 )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailPlayerSetParameter(pSelf=*0x%x, parameterType=0x%x, param0=0x%llx, param1=0x%llx) " , pSelf , parameterType , param0 , param1 ) ;
2015-08-10 17:58:10 +02:00
switch ( parameterType )
{
2020-03-04 15:08:40 +01:00
case CELL_SAIL_PARAMETER_GRAPHICS_ADAPTER_BUFFER_RELEASE_DELAY : pSelf - > graphics_adapter_buffer_release_delay = static_cast < u32 > ( param1 ) ; break ; // TODO: Stream index
case CELL_SAIL_PARAMETER_CONTROL_PPU_THREAD_STACK_SIZE : pSelf - > control_ppu_thread_stack_size = static_cast < u32 > ( param0 ) ; break ;
case CELL_SAIL_PARAMETER_ENABLE_APOST_SRC : pSelf - > enable_apost_src = static_cast < u32 > ( param1 ) ; break ; // TODO: Stream index
2016-01-12 22:57:16 +01:00
default : cellSail . todo ( " cellSailPlayerSetParameter(): unimplemented parameter %s " , ParameterCodeToName ( parameterType ) ) ;
2015-08-10 17:58:10 +02:00
}
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 17:58:10 +02:00
s32 cellSailPlayerGetParameter ( vm : : ptr < CellSailPlayer > pSelf , s32 parameterType , vm : : ptr < u64 > pParam0 , vm : : ptr < u64 > pParam1 )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailPlayerGetParameter(pSelf=*0x%x, parameterType=0x%x, param0=*0x%x, param1=*0x%x) " , pSelf , parameterType , pParam0 , pParam1 ) ;
2015-08-10 17:58:10 +02:00
switch ( parameterType )
{
2020-03-04 15:08:40 +01:00
case 0 :
2016-01-12 22:57:16 +01:00
default : cellSail . error ( " cellSailPlayerGetParameter(): unimplemented parameter %s " , ParameterCodeToName ( parameterType ) ) ;
2015-08-10 17:58:10 +02:00
}
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerSubscribeEvent ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerUnsubscribeEvent ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerReplaceEventHandler ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2016-07-27 23:43:22 +02:00
s32 cellSailPlayerBoot ( ppu_thread & ppu , vm : : ptr < CellSailPlayer > pSelf , u64 userParam )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailPlayerBoot(pSelf=*0x%x, userParam=%d) " , pSelf , userParam ) ;
2015-08-10 17:58:10 +02:00
2016-07-27 23:43:22 +02:00
{
CellSailEvent event ;
event . u32x2 . major = CELL_SAIL_EVENT_PLAYER_STATE_CHANGED ;
event . u32x2 . minor = 0 ;
pSelf - > callback ( ppu , pSelf - > callbackArg , event , CELL_SAIL_PLAYER_STATE_BOOT_TRANSITION , 0 ) ;
} ;
// TODO: Do stuff here
pSelf - > booted = true ;
{
CellSailEvent event ;
event . u32x2 . major = CELL_SAIL_EVENT_PLAYER_CALL_COMPLETED ;
event . u32x2 . minor = CELL_SAIL_PLAYER_CALL_BOOT ;
pSelf - > callback ( ppu , pSelf - > callbackArg , event , 0 , 0 ) ;
} ;
2015-08-10 17:58:10 +02:00
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerAddDescriptor ( vm : : ptr < CellSailPlayer > pSelf , vm : : ptr < CellSailDescriptor > pDesc )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailPlayerAddDescriptor(pSelf=*0x%x, pDesc=*0x%x) " , pSelf , pDesc ) ;
2014-10-17 15:20:40 +02:00
2014-11-15 15:45:02 +01:00
if ( pSelf & & pSelf - > descriptors < 3 & & pDesc )
2014-10-17 15:20:40 +02:00
{
pSelf - > descriptors + + ;
pSelf - > registeredDescriptors [ pSelf - > descriptors ] = pDesc ;
pDesc - > registered = true ;
}
else
{
2016-01-12 22:57:16 +01:00
cellSail . error ( " Descriptor limit reached or the descriptor is unspecified! This should never happen, report this to a developer. " ) ;
2014-10-17 15:20:40 +02:00
}
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-08-10 14:10:16 +02:00
s32 cellSailPlayerCreateDescriptor ( vm : : ptr < CellSailPlayer > pSelf , s32 streamType , vm : : ptr < void > pMediaInfo , vm : : cptr < char > pUri , vm : : pptr < CellSailDescriptor > ppDesc )
2013-09-28 04:36:57 +02:00
{
2016-08-11 01:29:59 +02:00
cellSail . todo ( " cellSailPlayerCreateDescriptor(pSelf=*0x%x, streamType=%d, pMediaInfo=*0x%x, pUri=%s, ppDesc=**0x%x) " , pSelf , streamType , pMediaInfo , pUri , ppDesc ) ;
2018-08-25 14:39:00 +02:00
2015-07-11 22:44:53 +02:00
u32 descriptorAddress = vm : : alloc ( sizeof ( CellSailDescriptor ) , vm : : main ) ;
2014-12-20 08:05:42 +01:00
auto descriptor = vm : : ptr < CellSailDescriptor > : : make ( descriptorAddress ) ;
2015-07-27 16:59:21 +02:00
* ppDesc = descriptor ;
2014-12-20 08:05:42 +01:00
descriptor - > streamType = streamType ;
descriptor - > registered = false ;
2014-10-17 15:20:40 +02:00
2014-12-19 12:31:52 +01:00
//pSelf->descriptors = 0;
2014-10-17 15:20:40 +02:00
pSelf - > repeatMode = 0 ;
2014-12-24 19:47:56 +01:00
switch ( streamType )
{
case CELL_SAIL_STREAM_PAMF :
{
std : : string uri = pUri . get_ptr ( ) ;
2020-02-29 06:29:28 +01:00
if ( uri . starts_with ( " x-cell-fs:// " ) )
2015-08-10 14:10:16 +02:00
{
2016-03-21 20:43:03 +01:00
if ( fs : : file f { vfs : : get ( uri . substr ( 12 ) ) } )
2015-08-10 14:10:16 +02:00
{
2020-03-04 15:08:40 +01:00
u32 size = : : size32 ( f ) ;
2015-08-10 14:10:16 +02:00
u32 buffer = vm : : alloc ( size , vm : : main ) ;
auto bufPtr = vm : : cptr < PamfHeader > : : make ( buffer ) ;
2014-12-24 19:47:56 +01:00
PamfHeader * buf = const_cast < PamfHeader * > ( bufPtr . get_ptr ( ) ) ;
2016-08-15 02:11:49 +02:00
verify ( HERE ) , f . read ( buf , size ) = = size ;
2015-07-11 22:44:53 +02:00
u32 sp_ = vm : : alloc ( sizeof ( CellPamfReader ) , vm : : main ) ;
2014-12-24 19:47:56 +01:00
auto sp = vm : : ptr < CellPamfReader > : : make ( sp_ ) ;
2015-08-10 14:10:16 +02:00
u32 reader = cellPamfReaderInitialize ( sp , bufPtr , size , 0 ) ;
2014-12-24 19:47:56 +01:00
2015-08-10 14:10:16 +02:00
descriptor - > buffer = buffer ;
descriptor - > sp_ = sp_ ;
2014-12-24 19:47:56 +01:00
}
else
2015-08-10 14:10:16 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " Couldn't open PAMF: %s " , uri . c_str ( ) ) ;
2015-08-10 14:10:16 +02:00
}
2014-12-24 19:47:56 +01:00
}
else
2015-08-10 14:10:16 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " Unhandled uri: %s " , uri . c_str ( ) ) ;
2015-08-10 14:10:16 +02:00
}
2014-12-24 19:47:56 +01:00
break ;
}
default :
2016-01-12 22:57:16 +01:00
cellSail . error ( " Unhandled stream type: %d " , streamType ) ;
2014-12-24 19:47:56 +01:00
}
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerDestroyDescriptor ( vm : : ptr < CellSailPlayer > pSelf , vm : : ptr < CellSailDescriptor > pDesc )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailPlayerAddDescriptor(pSelf=*0x%x, pDesc=*0x%x) " , pSelf , pDesc ) ;
2014-10-17 15:20:40 +02:00
if ( pDesc - > registered )
return CELL_SAIL_ERROR_INVALID_STATE ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerRemoveDescriptor ( vm : : ptr < CellSailPlayer > pSelf , vm : : ptr < CellSailDescriptor > ppDesc )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailPlayerAddDescriptor(pSelf=*0x%x, pDesc=*0x%x) " , pSelf , ppDesc ) ;
2014-10-17 15:20:40 +02:00
if ( pSelf - > descriptors > 0 )
{
ppDesc = pSelf - > registeredDescriptors [ pSelf - > descriptors ] ;
2015-10-17 19:47:18 +02:00
// TODO: Figure out how properly free a descriptor. Use game specified memory dealloc function?
//delete &pSelf->registeredDescriptors[pSelf->descriptors];
2014-10-17 15:20:40 +02:00
pSelf - > descriptors - - ;
}
return pSelf - > descriptors ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerGetDescriptorCount ( vm : : ptr < CellSailPlayer > pSelf )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailPlayerGetDescriptorCount(pSelf=*0x%x) " , pSelf ) ;
2014-10-17 15:20:40 +02:00
return pSelf - > descriptors ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerGetCurrentDescriptor ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerOpenStream ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerCloseStream ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerOpenEsAudio ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerOpenEsVideo ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerOpenEsUser ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerReopenEsAudio ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerReopenEsVideo ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerReopenEsUser ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerCloseEsAudio ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerCloseEsVideo ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerCloseEsUser ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerStart ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerStop ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerNext ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerCancel ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-26 02:53:26 +02:00
s32 cellSailPlayerSetPaused ( vm : : ptr < CellSailPlayer > pSelf , b8 paused )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . todo ( " cellSailPlayerSetPaused(pSelf=*0x%x, paused=%d) " , pSelf , paused ) ;
2013-09-28 04:36:57 +02:00
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerIsPaused ( vm : : ptr < CellSailPlayer > pSelf )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailPlayerIsPaused(pSelf=*0x%x) " , pSelf ) ;
2014-12-14 08:59:04 +01:00
return pSelf - > paused ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerSetRepeatMode ( vm : : ptr < CellSailPlayer > pSelf , s32 repeatMode , vm : : ptr < CellSailStartCommand > pCommand )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailPlayerSetRepeatMode(pSelf=*0x%x, repeatMode=%d, pCommand=*0x%x) " , pSelf , repeatMode , pCommand ) ;
2014-10-17 15:20:40 +02:00
pSelf - > repeatMode = repeatMode ;
pSelf - > playbackCommand = pCommand ;
return pSelf - > repeatMode ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerGetRepeatMode ( vm : : ptr < CellSailPlayer > pSelf , vm : : ptr < CellSailStartCommand > pCommand )
2013-09-28 04:36:57 +02:00
{
2016-01-12 22:57:16 +01:00
cellSail . warning ( " cellSailPlayerGetRepeatMode(pSelf=*0x%x, pCommand=*0x%x) " , pSelf , pCommand ) ;
2014-10-17 15:20:40 +02:00
pCommand = pSelf - > playbackCommand ;
return pSelf - > repeatMode ;
2013-09-28 04:36:57 +02:00
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerSetEsAudioMuted ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerSetEsVideoMuted ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerIsEsAudioMuted ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerIsEsVideoMuted ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerDumpImage ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2015-07-09 17:30:37 +02:00
s32 cellSailPlayerUnregisterSource ( )
2013-09-28 04:36:57 +02:00
{
UNIMPLEMENTED_FUNC ( cellSail ) ;
return CELL_OK ;
}
2016-03-21 20:43:03 +01:00
DECLARE ( ppu_module_manager : : cellSail ) ( " cellSail " , [ ] ( )
2015-02-18 17:22:06 +01:00
{
2017-02-12 19:35:55 +01:00
static ppu_static_module cellSailAvi ( " cellSailAvi " ) ;
2015-02-20 14:58:40 +01:00
REG_FUNC ( cellSail , cellSailMemAllocatorInitialize ) ;
REG_FUNC ( cellSail , cellSailFutureInitialize ) ;
REG_FUNC ( cellSail , cellSailFutureFinalize ) ;
REG_FUNC ( cellSail , cellSailFutureReset ) ;
REG_FUNC ( cellSail , cellSailFutureSet ) ;
REG_FUNC ( cellSail , cellSailFutureGet ) ;
REG_FUNC ( cellSail , cellSailFutureIsDone ) ;
REG_FUNC ( cellSail , cellSailDescriptorGetStreamType ) ;
REG_FUNC ( cellSail , cellSailDescriptorGetUri ) ;
REG_FUNC ( cellSail , cellSailDescriptorGetMediaInfo ) ;
REG_FUNC ( cellSail , cellSailDescriptorSetAutoSelection ) ;
REG_FUNC ( cellSail , cellSailDescriptorIsAutoSelection ) ;
REG_FUNC ( cellSail , cellSailDescriptorCreateDatabase ) ;
REG_FUNC ( cellSail , cellSailDescriptorDestroyDatabase ) ;
REG_FUNC ( cellSail , cellSailDescriptorOpen ) ;
REG_FUNC ( cellSail , cellSailDescriptorClose ) ;
REG_FUNC ( cellSail , cellSailDescriptorSetEs ) ;
REG_FUNC ( cellSail , cellSailDescriptorClearEs ) ;
REG_FUNC ( cellSail , cellSailDescriptorGetCapabilities ) ;
REG_FUNC ( cellSail , cellSailDescriptorInquireCapability ) ;
REG_FUNC ( cellSail , cellSailDescriptorSetParameter ) ;
REG_FUNC ( cellSail , cellSailSoundAdapterInitialize ) ;
REG_FUNC ( cellSail , cellSailSoundAdapterFinalize ) ;
REG_FUNC ( cellSail , cellSailSoundAdapterSetPreferredFormat ) ;
REG_FUNC ( cellSail , cellSailSoundAdapterGetFrame ) ;
REG_FUNC ( cellSail , cellSailSoundAdapterGetFormat ) ;
REG_FUNC ( cellSail , cellSailSoundAdapterUpdateAvSync ) ;
REG_FUNC ( cellSail , cellSailSoundAdapterPtsToTimePosition ) ;
REG_FUNC ( cellSail , cellSailGraphicsAdapterInitialize ) ;
REG_FUNC ( cellSail , cellSailGraphicsAdapterFinalize ) ;
REG_FUNC ( cellSail , cellSailGraphicsAdapterSetPreferredFormat ) ;
REG_FUNC ( cellSail , cellSailGraphicsAdapterGetFrame ) ;
REG_FUNC ( cellSail , cellSailGraphicsAdapterGetFrame2 ) ;
REG_FUNC ( cellSail , cellSailGraphicsAdapterGetFormat ) ;
REG_FUNC ( cellSail , cellSailGraphicsAdapterUpdateAvSync ) ;
REG_FUNC ( cellSail , cellSailGraphicsAdapterPtsToTimePosition ) ;
REG_FUNC ( cellSail , cellSailAuReceiverInitialize ) ;
REG_FUNC ( cellSail , cellSailAuReceiverFinalize ) ;
REG_FUNC ( cellSail , cellSailAuReceiverGet ) ;
REG_FUNC ( cellSail , cellSailRendererAudioInitialize ) ;
REG_FUNC ( cellSail , cellSailRendererAudioFinalize ) ;
REG_FUNC ( cellSail , cellSailRendererAudioNotifyCallCompleted ) ;
REG_FUNC ( cellSail , cellSailRendererAudioNotifyFrameDone ) ;
REG_FUNC ( cellSail , cellSailRendererAudioNotifyOutputEos ) ;
REG_FUNC ( cellSail , cellSailRendererVideoInitialize ) ;
REG_FUNC ( cellSail , cellSailRendererVideoFinalize ) ;
REG_FUNC ( cellSail , cellSailRendererVideoNotifyCallCompleted ) ;
REG_FUNC ( cellSail , cellSailRendererVideoNotifyFrameDone ) ;
REG_FUNC ( cellSail , cellSailRendererVideoNotifyOutputEos ) ;
REG_FUNC ( cellSail , cellSailSourceInitialize ) ;
REG_FUNC ( cellSail , cellSailSourceFinalize ) ;
REG_FUNC ( cellSail , cellSailSourceNotifyCallCompleted ) ;
REG_FUNC ( cellSail , cellSailSourceNotifyInputEos ) ;
REG_FUNC ( cellSail , cellSailSourceNotifyStreamOut ) ;
REG_FUNC ( cellSail , cellSailSourceNotifySessionError ) ;
REG_FUNC ( cellSail , cellSailSourceNotifyMediaStateChanged ) ;
REG_FUNC ( cellSail , cellSailSourceSetDiagHandler ) ;
2015-08-01 00:48:38 +02:00
{
// these functions shouldn't exist
REG_FUNC ( cellSail , cellSailSourceNotifyOpenCompleted ) ;
REG_FUNC ( cellSail , cellSailSourceNotifyStartCompleted ) ;
REG_FUNC ( cellSail , cellSailSourceNotifyStopCompleted ) ;
REG_FUNC ( cellSail , cellSailSourceNotifyReadCompleted ) ;
REG_FUNC ( cellSail , cellSailSourceNotifyCloseCompleted ) ;
}
2015-02-20 14:58:40 +01:00
REG_FUNC ( cellSail , cellSailMp4MovieGetBrand ) ;
REG_FUNC ( cellSail , cellSailMp4MovieIsCompatibleBrand ) ;
REG_FUNC ( cellSail , cellSailMp4MovieGetMovieInfo ) ;
REG_FUNC ( cellSail , cellSailMp4MovieGetTrackByIndex ) ;
REG_FUNC ( cellSail , cellSailMp4MovieGetTrackById ) ;
REG_FUNC ( cellSail , cellSailMp4MovieGetTrackByTypeAndIndex ) ;
REG_FUNC ( cellSail , cellSailMp4TrackGetTrackInfo ) ;
REG_FUNC ( cellSail , cellSailMp4TrackGetTrackReferenceCount ) ;
REG_FUNC ( cellSail , cellSailMp4TrackGetTrackReference ) ;
2015-02-18 17:22:06 +01:00
2015-02-20 14:58:40 +01:00
REG_FUNC ( cellSail , cellSailAviMovieGetMovieInfo ) ;
REG_FUNC ( cellSail , cellSailAviMovieGetStreamByIndex ) ;
REG_FUNC ( cellSail , cellSailAviMovieGetStreamByTypeAndIndex ) ;
REG_FUNC ( cellSail , cellSailAviMovieGetHeader ) ;
REG_FUNC ( cellSail , cellSailAviStreamGetMediaType ) ;
REG_FUNC ( cellSail , cellSailAviStreamGetHeader ) ;
REG_FUNC ( cellSail , cellSailPlayerInitialize ) ;
REG_FUNC ( cellSail , cellSailPlayerInitialize2 ) ;
REG_FUNC ( cellSail , cellSailPlayerFinalize ) ;
REG_FUNC ( cellSail , cellSailPlayerRegisterSource ) ;
REG_FUNC ( cellSail , cellSailPlayerGetRegisteredProtocols ) ;
REG_FUNC ( cellSail , cellSailPlayerSetSoundAdapter ) ;
REG_FUNC ( cellSail , cellSailPlayerSetGraphicsAdapter ) ;
REG_FUNC ( cellSail , cellSailPlayerSetAuReceiver ) ;
REG_FUNC ( cellSail , cellSailPlayerSetRendererAudio ) ;
REG_FUNC ( cellSail , cellSailPlayerSetRendererVideo ) ;
REG_FUNC ( cellSail , cellSailPlayerSetParameter ) ;
REG_FUNC ( cellSail , cellSailPlayerGetParameter ) ;
REG_FUNC ( cellSail , cellSailPlayerSubscribeEvent ) ;
REG_FUNC ( cellSail , cellSailPlayerUnsubscribeEvent ) ;
REG_FUNC ( cellSail , cellSailPlayerReplaceEventHandler ) ;
REG_FUNC ( cellSail , cellSailPlayerBoot ) ;
REG_FUNC ( cellSail , cellSailPlayerCreateDescriptor ) ;
REG_FUNC ( cellSail , cellSailPlayerDestroyDescriptor ) ;
REG_FUNC ( cellSail , cellSailPlayerAddDescriptor ) ;
REG_FUNC ( cellSail , cellSailPlayerRemoveDescriptor ) ;
REG_FUNC ( cellSail , cellSailPlayerGetDescriptorCount ) ;
REG_FUNC ( cellSail , cellSailPlayerGetCurrentDescriptor ) ;
REG_FUNC ( cellSail , cellSailPlayerOpenStream ) ;
REG_FUNC ( cellSail , cellSailPlayerCloseStream ) ;
REG_FUNC ( cellSail , cellSailPlayerOpenEsAudio ) ;
REG_FUNC ( cellSail , cellSailPlayerOpenEsVideo ) ;
REG_FUNC ( cellSail , cellSailPlayerOpenEsUser ) ;
REG_FUNC ( cellSail , cellSailPlayerReopenEsAudio ) ;
REG_FUNC ( cellSail , cellSailPlayerReopenEsVideo ) ;
REG_FUNC ( cellSail , cellSailPlayerReopenEsUser ) ;
REG_FUNC ( cellSail , cellSailPlayerCloseEsAudio ) ;
REG_FUNC ( cellSail , cellSailPlayerCloseEsVideo ) ;
REG_FUNC ( cellSail , cellSailPlayerCloseEsUser ) ;
REG_FUNC ( cellSail , cellSailPlayerStart ) ;
REG_FUNC ( cellSail , cellSailPlayerStop ) ;
REG_FUNC ( cellSail , cellSailPlayerNext ) ;
REG_FUNC ( cellSail , cellSailPlayerCancel ) ;
REG_FUNC ( cellSail , cellSailPlayerSetPaused ) ;
REG_FUNC ( cellSail , cellSailPlayerIsPaused ) ;
REG_FUNC ( cellSail , cellSailPlayerSetRepeatMode ) ;
REG_FUNC ( cellSail , cellSailPlayerGetRepeatMode ) ;
REG_FUNC ( cellSail , cellSailPlayerSetEsAudioMuted ) ;
REG_FUNC ( cellSail , cellSailPlayerSetEsVideoMuted ) ;
REG_FUNC ( cellSail , cellSailPlayerIsEsAudioMuted ) ;
REG_FUNC ( cellSail , cellSailPlayerIsEsVideoMuted ) ;
REG_FUNC ( cellSail , cellSailPlayerDumpImage ) ;
REG_FUNC ( cellSail , cellSailPlayerUnregisterSource ) ;
2015-02-18 17:22:06 +01:00
} ) ;