⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 asfdemux_common.h

📁 1. 8623L平台
💻 H
📖 第 1 页 / 共 2 页
字号:
#ifdef DISPLAY_VIDEO_BITRATE	RMuint32 prev_timeV;	RMuint32 prev_MON_V;	RMuint32 nb_bytes_since_prev_timeV;	RMuint32 byteRateV;	RMuint32 maxByteRateV;#endif	/* #### Begin CARDEA code #### */	void * cardea_context;	RMuint8 sample_id[8];	/* #### End CARDEA code #### */	RMbool fDecodingWMAPROPacket;	struct RMfifo *wmapro_fifo;	struct asf_wmapro_buffer_info *pread_wmapro_info;	RMbool bcc_enabled;	struct bcc *pbcc;	RMuint32 prebufferedBytes;	// for VC1	RMuint8 *seqHeader;	RMuint32 seqHeaderSize;	RMbool addSeqHeader;	RMbool addEntryHeader;	RMbool addFrameHeader;	RMuint8 *entryHeader;	RMuint32 entryHeaderSize;	RMbool isVC1;	RMbool getStartCodeBuffer;	RMuint8 *startCodeBuffer;	RMuint32 startCodeBufferSize;	RMuint32 startCodeBufferLeft;	// to allow sending audio when in trickmodes	RMbool sendAudioTrickmode;	RMbool monitorFIFOs;	struct timeval last;	RMbool bypass_drm;	RMbool linear_playback;	RMuint32 audioStreams;	RMuint32 audioStreamTable[10];	RMuint32 audioInstances;	struct video_cmdline *video_opt;	struct display_cmdline *disp_opt;	struct audio_cmdline *audio_opt;	struct playback_cmdline *play_opt;#ifndef WITH_MONO	struct display_context disp_info;#endif	struct asf_priv_cmdline priv_opt;	struct RM_PSM_Actions actions; 	struct asf_stream_info stream_table[4];	RMuint64 lastVideoPTS;	void **dmabuffer_array;	RMuint32 dmabuffer_index;		RMbool audioSamplesDropped;	RMstatus audioSetupStatus;	RMstatus videoSetupStatus;    	enum RMasfProcess_key_goto gotoRequest; 	void *StreamingContext;	RMuint64 stc_offset_ms;};#define GET_DATA_FIFO_INFO(pRUA, ModuleId)				\	{								\		struct DataFIFOInfo DataFIFOInfo;			\		RMuint32 fullness;					\		RUAGetProperty(pRUA, ModuleId, RMGenericPropertyID_DataFIFOInfo, &DataFIFOInfo, sizeof(DataFIFOInfo)); \		fullness = (100*DataFIFOInfo.Readable)/DataFIFOInfo.Size; \		fprintf(stderr, "Data %lx: st=%08lx sz=%ld wr=%ld rd=%ld --> f : %lu/100\n", ModuleId, DataFIFOInfo.StartAddress,	\			DataFIFOInfo.Size, DataFIFOInfo.Writable,  DataFIFOInfo.Readable, fullness); \	}								\#define GET_XFER_FIFO_INFO(pRUA, ModuleId)				\	{								\		struct XferFIFOInfo_type XferFIFOInfo;			\		RMuint32 fullness;					\		RUAGetProperty(pRUA, ModuleId, RMGenericPropertyID_XferFIFOInfo, &XferFIFOInfo, sizeof(XferFIFOInfo)); \		fullness = (100*XferFIFOInfo.Readable)/XferFIFOInfo.Size; \		fprintf(stderr, "XFER %lx: st=%08lx sz=%ld wr=%ld rd=%ld er=%lx --> f : %lu/100\n", ModuleId, XferFIFOInfo.StartAddress, \			XferFIFOInfo.Size, XferFIFOInfo.Writable,  XferFIFOInfo.Readable, XferFIFOInfo.Erasable, fullness); \	}#define GET_XFER_FIFO_BYTES_QUEUED(pRUA, ModuleId)			\	{								\		RMuint32 bytes_queued;					\		RUAGetProperty(pRUA, ModuleId, RMGenericPropertyID_XferFIFOBytesQueued, &bytes_queued, sizeof(bytes_queued)); \		fprintf(stderr, "XFER %lx: %lu\n", ModuleId, bytes_queued); \	}#define PROCESS_KEY_INCALLBACK(getkey,return_if_any_key)		\	do {								\		RMDBGLOG((DISABLE, "process_key_incallback\n"));		\		if (pSendContext->gotoRequest <= RMProcess_key_goto_got_key_but_noaction) \			pSendContext->gotoRequest = pSendContext->process_key_sub(pSendContext,FALSE, getkey,TRUE,dataType); \		else							\			RMDBGLOG((ENABLE, "GotoRequest already on the way (%d)\n",pSendContext->gotoRequest)); \		if ( ((return_if_any_key)&&(pSendContext->gotoRequest > RMProcess_key_goto_none)) \		     ||((!return_if_any_key)&&(pSendContext->gotoRequest > RMProcess_key_goto_got_key_but_noaction)) ) { \			RMDBGLOG((ENABLE, "GotoRequest %d from callback process\n",pSendContext->gotoRequest)); \			goto return_from_callback;			\		}							\	} while (0)#define PROCESS_KEY(release, getkey)					\	do {								\		enum RMasfProcess_key_goto exit_goto;			\		RMuint8 from_callback;					\		RMDBGLOG((DISABLE, "process_key\n"));			\		if (SendContext.gotoRequest > RMProcess_key_goto_nojump_but_exit) { \			RMDBGLOG((ENABLE, "pProcessContext->gotoRequest not null, asking for jump\n"));	\			from_callback=TRUE;				\			exit_goto = SendContext.gotoRequest;		\		}							\		else {							\			from_callback=FALSE;				\			if (!SendContext.process_key_sub)		\				RMDBGLOG((ENABLE, "laksdjflskdjfsldkf\n")); \									\			exit_goto = SendContext.process_key_sub(&SendContext,release, getkey,FALSE,0); \		}							\		SendContext.gotoRequest = RMProcess_key_goto_none;	\		switch (exit_goto) {					\		case RMProcess_key_goto_none:				\		case RMProcess_key_goto_got_key_but_noaction:		\		case RMProcess_key_goto_nojump_but_exit:		\				break;					\		case RMProcess_key_goto_cleanup:			\			RMDBGLOG((ENABLE, "Executing goto cleanup requested from %s process\n",from_callback?"callback":"main")); \			goto cleanup;					\		case RMProcess_key_goto_mainloop_seek:			\			RMDBGLOG((ENABLE, "Executing goto mainloop_seek requested from %s process\n",from_callback?"callback":"main")); \			goto mainloop_seek;				\		case RMProcess_key_goto_wmapro_decoder_delete:		\			RMDBGLOG((ENABLE, "Executing goto wmapro_decoder_delete requested from %s process\n",from_callback?"callback":"main")); \			goto wmapro_decoder_delete;			\		}							\	} while (0)#define MONITOR_FIFO_INTERVAL_US 250000/* Prototypes */void asf_monitorFIFO(struct asf_context *context, RMbool alwaysShow);RMstatus asf_Play(struct asf_context * pSendContext, RMuint32 devices, enum DCCVideoPlayCommand mode);RMstatus asf_Stop(struct asf_context *pSendContext, RMuint32 devices);RMstatus asf_Pause(struct asf_context * pSendContext, RMuint32 devices);RMstatus asf_init_private_options(struct asf_priv_cmdline *options);void print_GUID(void *context,		unsigned char GUID[16], 		unsigned char *Name, 		unsigned char *Data, 		unsigned long long Partial_Size, 		unsigned long long Size);void print_File_Properties(void *context,			   unsigned long long File_Size,			   unsigned long long Creation_Date,			   unsigned long long Data_Packets_Count,			   unsigned long long Play_Duration,			   unsigned long long Send_Duration,			   unsigned long long Preroll,			   unsigned long Minimum_Data_Packet_Size,			   unsigned long Maximum_Data_Packet_Size,			   unsigned long Maximum_Bitrate,			   unsigned char Broadcast,			   unsigned char Seekable);void print_Stream_Bitrate_Properties(void *context,				     unsigned char Stream_Number, 				     unsigned long Average_Bitrate);void print_Audio_Stream_Properties(void *context,				   unsigned char Stream_Number, 				   unsigned short Codec_ID,				   unsigned short Number_of_Channels, 				   unsigned long Samples_Per_Second,				   unsigned long Average_Number_of_Bytes_Per_Second,				   unsigned short Block_Alignment, 				   unsigned short Bits_Per_Sample,				   unsigned char *Codec_Specific_Data, 				   unsigned long Partial_Codec_Specific_Data_Size, 				   unsigned long Codec_Specific_Data_Size);void print_Video_Stream_Properties(void *context,				   unsigned char Stream_Number, 				   unsigned long Compression_ID, 				   unsigned long Image_Width, 				   unsigned long Image_Height,				   unsigned char *Codec_Specific_Data, 				   unsigned long Partial_Codec_Specific_Data_Size, 				   unsigned long Codec_Specific_Data_Size);void print_Bitrate_Mutual_Exclusion(void *context,				    unsigned long mutex_index, 				    unsigned short Stream_Numbers_Count,				    unsigned char bitrate_exclusion,				    unsigned char Stream_Number);void dummy_content_encryption_callback(void *context,				       RMuint8 *Secret_Data,				       RMuint32 Partial_Secret_Data_Length,				       RMuint32  Secret_Data_Length,				       RMuint8 *Key_ID,                                // ASCII char				       RMuint32 Partial_Key_ID_Length,				       RMuint32 Key_ID_Length,				       RMuint8 *License_URL,                           // ASCII char				       RMuint32 Partial_License_URL_Length,				       RMuint32 License_URL_Length);void dummy_drm_init(void *context,		    RMuint8 *Data,		    RMuint32 Partial_Data_Size,		    RMuint32 Data_Size);void payload_extension (void *context,			unsigned short Stream_Number,			unsigned long Media_Object_Number,			unsigned char Media_Object_Number_valid,			unsigned short Payload_Extension_System_ID,			unsigned char *Payload_Extension_System_Data,			unsigned short Partial_Payload_Extension_System_Data_Size,			unsigned short Payload_Extension_System_Data_Size,			unsigned short bytes_left);void inband_AspectRatio(void *context,			RMuint16 Stream_Num,			RMuint32 aspectRatioX,			RMuint32 aspectRatioY);void languagelistcb(void *context,		    RMuint16 Language_ID_Records_Count,		    RMuint16 Language_ID_Records_Index,		    RMuint8 *Language_ID,		    RMuint8 Partial_Language_ID_Length,		    RMuint8 Language_ID_Length);void play_Payload(void *context,		  unsigned char Stream_Number,  		  unsigned char *buf, 		  unsigned long size,		  unsigned long bytes_left,		  unsigned char Is_Key_Frame,		  unsigned long Media_Object_Number, 		  unsigned char Media_Object_Number_valid,		  unsigned long Presentation_Time, 		  unsigned char Presentation_Time_valid,		  unsigned long Offset_Into_Media_Object);RMuint32 asf_ResyncAudio(struct asf_context *pSendContext, struct emhwlib_info *pInfo);void asf_flush_wmaproFIFO(struct asf_context *pSendContext);RMbool asf_try_decode_wmapro(struct asf_context *pSendContext, RMbool EOS);void asf_check_prebuf_state(struct asf_context *pSendContext, RMuint32 buffersize);RMstatus asf_WaitForEOS(struct asf_context *context, struct RM_PSM_Actions *pActions);RMstatus asf_init(struct asf_context *pSendContext,		  int argc, 		  char *argv[],		  struct playback_cmdline *pPlayback_options,		  struct display_cmdline  *pDisplay_options,		  struct video_cmdline *pVideo_options,		  struct audio_cmdline *pAudio_options,		  struct stream_options_s *pStream_options,		  struct dh_context *pDh_info,		  struct RM_PSM_Context *pPSMContext,		  struct dcc_context *pDcc_info,		  void *mono,		  process_key_sub_callback process_key,		  struct RMfifo *wmapro_fifo,		  RMuint8 **wmapro_fifo_buffer,		  RMuint8 **wmapro_fifo_buffer_original,		  struct dtcp_cookie *dtcpCookieHandle,		  RMuint32 keyflags,		  RMbool isStreaming);RMstatus asf_close(struct asf_context *pSendContext,		   RMuint8 *wmapro_fifo_buffer_original,		   struct dtcp_cookie *dtcpCookieHandle);RMstatus asf_SyncTimerWithDecoderPTS(struct asf_context *pSendContext);#endif // __ASFDEMUX_COMMON_H__

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -