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

📄 o_karaoke.c

📁 Zoran V966 DVD 解码 Soc芯片的源程序
💻 C
📖 第 1 页 / 共 3 页
字号:
*	Out		:
*
*	Desc 	:	The Karaoke On/Off choice operation function.
****************************************************************************************/
#pragma argsused
static MS_OP _KaraokeOnOffChoiceOperation(MSO_OBJECT __NEAR* pThis, MS_OP MsOp, UINT32 lParam)
{
	MS_OP MsOpInput=MsOp;
#ifdef D_CD_GRAPHIC_ENABLED
	BOOL bIsCdGraphic = CoreAPI_IsCDGDetected();
#endif// D_CD_GRAPHIC_ENABLED

	if(MS_OP_ENTER == MsOp)
	{
		if(!CoreAPI_WaitForUICoreActionDone())
			return MS_OP_NONE;
			
#ifdef D_CD_GRAPHIC_ENABLED
		if(bIsCdGraphic)
			MS_SEND_OP(MS_OP_MENU_CDG_PLAYBACK_STOP, 0);
#endif// D_CD_GRAPHIC_ENABLED		
	}
		
	MsOp=ChoiceNoExpandingOperation(pThis, MsOp, lParam);

	if(MS_OP_ENTER == MsOpInput)
		{
		if(MS_OP_NONE == MsOp) 
			MS_SendOperation((MSO_OBJECT __NEAR*)MS_GetParentPtr(pThis), MS_OP_REFRESH, 0);	

#ifdef D_CD_GRAPHIC_ENABLED		
		if(bIsCdGraphic)
			return MS_OP_MENU_CDG_PLAYBACK_RESTART;
#endif// D_CD_GRAPHIC_ENABLED		
	}
	return MsOp;
}

/***************************************************************************************
*	Function 	: 	_LRModeChoiceOperation
*
*	In		:
*
*	Out		:
*
*	Desc 	:	The choice operation of all the MSO_CHOICE objects in the Karaoke kit.
****************************************************************************************/
#ifdef D_KARAOKE_LRMODE
#pragma argsused
static MS_OP _LRModeChoiceOperation(MSO_OBJECT __NEAR* pThis, MS_OP MsOp, UINT32 lParam)
{	
	// Pre-processing
	switch(MsOp)
	{
		case MS_OP_ENTER:			
			 if(MS_IS_CHOICE_DISABLED(pThis))
			{
			 	PROHIBIT(MSG_PROHIBIT_NOT_ALLOWED_NOW);
				return MS_OP_NONE;	
			}			
			 
		default:
			break;
	}

	MsOp = ChoiceNoExpandingOperation(pThis, MsOp, lParam);


	// Post-processing
	switch(MsOp)
	{
	case MS_OP_INIT: // Fall Through !!!
		case MS_OP_REFRESH:
			{	
				if(FALSE == CoreAPI_IsKaraokeOn())
				{	
					MS_SET_CHOICE_DISABLE(pThis);	
					MS_DisplayAddObject(pThis);
				}
				else
				{
					MS_CLEAR_CHOICE_DISABLE(pThis);
					MS_DisplayAddObject(pThis);
				}
			}
			return MS_OP_NONE;
			
		default:
			break;
	}
	return MsOp;
}
#endif// D_KARAOKE_LRMODE
/***************************************************************************************
*	Function 	: 	_KeyShiftHSliderOperation
*
*	In		:
*
*	Out		:
*
*	Desc 	:	The choice operation of Key Shift slider object.
****************************************************************************************/
#pragma argsused
static MS_OP _KeyShiftHSliderOperation(MSO_OBJECT __NEAR* pThis, MS_OP MsOp, UINT32 lParam)
{
	// Pre-processing
	switch(MsOp)
	{
	case MS_OP_LEFT: // Fall Through !!!
	case MS_OP_RIGHT:
		{
			// Do nothing if disabled.
			if(MS_IS_HSLIDER_DISABLED(pThis))
			{
				PROHIBIT(MSG_PROHIBIT_NOT_ALLOWED_NOW);
				return MS_OP_NONE;
			}
		}
		break;

	default:
		break;
	}
	
	MsOp = HSliderOperationOnVList(pThis, MsOp, lParam);

	// Post-processing
	switch(MsOp)
	{
	case MS_OP_INIT: // Fall Through !!!
	case MS_OP_REFRESH:
		{
			// Disable the slider if Karaoke is off.
			if((FALSE ==CoreAPI_IsKaraokeOn()) 
#ifdef D_KARAOKE_MIC_EFFECT
				|| (KAR_MIC_EFFECT_HARMONY == CoreAPI_GetKarmiceEffect())
#endif
				)
			{
				MS_SET_HSLIDER_DISABLE(pThis);
				MS_DisplayAddObject(pThis);
			}
			else
			{
				MS_CLEAR_HSLIDER_DISABLE(pThis);
				MS_DisplayAddObject(pThis);
			}	
		}
		break;

	case MS_OP_ENTER:
		return MS_OP_NONE;

	default:
		break;
	}
	return MsOp;
}

/***************************************************************************************
*	Function 	: 	_EchoHSliderOperation
*
*	In		:
*
*	Out		:
*
*	Desc 	:	The choice operation of Echo slider object.
****************************************************************************************/
#pragma argsused
static MS_OP _EchoHSliderOperation(MSO_OBJECT __NEAR* pThis, MS_OP MsOp, UINT32 lParam)
{
	// Pre-processing
	switch(MsOp)
	{
	case MS_OP_LEFT: // Fall Through !!!
	case MS_OP_RIGHT:
		{
			// Do nothing if disabled.
			if(MS_IS_HSLIDER_DISABLED(pThis))
			{
				PROHIBIT(MSG_PROHIBIT_NOT_ALLOWED_NOW);
				return MS_OP_NONE;
			}
		}
		break;

	default:
		break;
	}
	
	MsOp = HSliderOperationOnVList(pThis, MsOp, lParam);

	// Post-processing
	switch(MsOp)
	{
	case MS_OP_INIT: // Fall Through !!!
	case MS_OP_REFRESH:
		{
			// Disable the slider if Karaoke is off.
			if(FALSE == CoreAPI_IsKaraokeOn())
			{
				MS_SET_HSLIDER_DISABLE(pThis);
				MS_DisplayAddObject(pThis);
			}
			else
			{
				MS_CLEAR_HSLIDER_DISABLE(pThis);
				MS_DisplayAddObject(pThis);
			}	
		}
		break;

	case MS_OP_ENTER:
		return MS_OP_NONE;

	default:
		break;
	}
	return MsOp;
}

/***************************************************************************************
*	Function 	: 	_VoiceCancelChoiceOperation
*
*	In		:
*
*	Out		:
*
*	Desc 	:	The Voice cancel choice operation function.
****************************************************************************************/
#pragma argsused
static MS_OP _VoiceCancelChoiceOperation(MSO_OBJECT __NEAR* pThis, MS_OP MsOp, UINT32 lParam)
{	

	// Pre-processing
	switch(MsOp)
	{
		case MS_OP_ENTER:
			{
				 if(MS_IS_CHOICE_DISABLED(pThis))
				{
				 	PROHIBIT(MSG_PROHIBIT_NOT_ALLOWED_NOW);
					return MS_OP_NONE;	
				}
			}
			 
		default:
			break;
	}

	MsOp = ChoiceNoExpandingOperation(pThis, MsOp, lParam);

	// Post-processing
	switch(MsOp)
	{
		case MS_OP_INIT:
		case MS_OP_REFRESH:
			{	
			if(FALSE == CoreAPI_IsKaraokeOn())
				{	
					MS_SET_CHOICE_DISABLE(pThis);	
					MS_DisplayAddObject(pThis);
				}
				else
				{
					MS_CLEAR_CHOICE_DISABLE(pThis);
					MS_DisplayAddObject(pThis);
				}
			}
			return MS_OP_NONE;
			
		default:
			break;
	}
	return MsOp;
}

/***************************************************************************************
*	Function 	: 	_MelodyChoiceOperation
*
*	In		:
*
*	Out		:
*
*	Desc 	:	The Melody On/Off choice operation function.
****************************************************************************************/
#ifdef D_KARAOKE_MELODY
#pragma argsused
static MS_OP _MelodyChoiceOperation(MSO_OBJECT __NEAR* pThis, MS_OP MsOp, UINT32 lParam)
{	
	// Pre-processing
	switch(MsOp)
	{
		case MS_OP_ENTER:			
			 if(MS_IS_CHOICE_DISABLED(pThis))
			{
			 	PROHIBIT(MSG_PROHIBIT_NOT_ALLOWED_NOW);
				return MS_OP_NONE;	
			}			
			 
		default:
			break;
	}

	MsOp = ChoiceNoExpandingOperation(pThis, MsOp, lParam);

	// Post-processing
	switch(MsOp)
	{
	case MS_OP_INIT: // Fall Through !!!
		case MS_OP_REFRESH:
			{	
			if((FALSE == CoreAPI_IsKaraokeOn()) || !CoreAPI_IsDVDVideoKaraokeDisc())
				{	
					MS_SET_CHOICE_DISABLE(pThis);	
					MS_DisplayAddObject(pThis);
				}
				else
				{
					MS_CLEAR_CHOICE_DISABLE(pThis);
					MS_DisplayAddObject(pThis);
				}
			}
		return MS_OP_NONE;
			
		default:
			break;
	}
	return MsOp;
}
#endif//D_KARAOKE_MELODY
/***************************************************************************************
*	Function 	: 	_MicEffectChoiceOperation
*
*	In		:
*
*	Out		:
*
*	Desc 	:	The Mic Effect choice operation function.
****************************************************************************************/
#ifdef D_KARAOKE_MIC_EFFECT
#pragma argsused
static MS_OP _MicEffectChoiceOperation(MSO_OBJECT __NEAR* pThis, MS_OP MsOp, UINT32 lParam)
{	
	// Pre-processing
	switch(MsOp)
	{
		case MS_OP_ENTER:			
			 if(MS_IS_CHOICE_DISABLED(pThis))
			{
			 	PROHIBIT(MSG_PROHIBIT_NOT_ALLOWED_NOW);
				return MS_OP_NONE;	
			}			
			 
		default:
			break;
	}

	MsOp = ChoiceNoExpandingOperation(pThis, MsOp, lParam);

	// Post-processing
	switch(MsOp)
	{
	case MS_OP_INIT: // Fall Through !!!
	case MS_OP_REFRESH:
			{
				if(FALSE == CoreAPI_IsKaraokeOn())
				{	
					MS_SET_CHOICE_DISABLE(pThis);	
					MS_DisplayAddObject(pThis);
				}
				else
				{
					MS_CLEAR_CHOICE_DISABLE(pThis);
					MS_DisplayAddObject(pThis);
				}
			}
			return MS_OP_NONE;
			
		default:
			break;
	}
	return MsOp;
}
#endif//D_KARAOKE_MIC_EFFECT
/***************************************************************************************
*	Function 	: 	_VocalEffectOnOffChoiceOperation
*
*	In		:
*
*	Out		:
*
*	Desc 	:	The Vocal choice operation function.
****************************************************************************************/
#ifdef D_VOCAL_SUPPORT_ENABLED
#pragma argsused
static MS_OP _VocalEffectChoiceOperation(MSO_OBJECT __NEAR* pThis, MS_OP MsOp, UINT32 lParam)
{	
	// Pre-processing
	switch(MsOp)
	{
		case MS_OP_ENTER:	
			{
				 if(MS_IS_CHOICE_DISABLED(pThis))
				{
				 	PROHIBIT(MSG_PROHIBIT_NOT_ALLOWED_NOW);
					return MS_OP_NONE;	
				}
			}
			 
		default:
			break;
	}

	MsOp = ChoiceNoExpandingOperation(pThis, MsOp, lParam);

⌨️ 快捷键说明

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