//------------------------------------------------------------------------------------------------------- void ISoundComponent::_DoOnAttachNode() { //Á¬½Ó±ä¸ü¼àÌý _HostNode()->RegisterMessageListener( NodeProperty::SA_POSITION, MEMBER_FUNC_PTR( &ISoundComponent::MessageRotation ) ); _HostNode()->RegisterMessageListener( NodeProperty::SA_ROTATION, MEMBER_FUNC_PTR( &ISoundComponent::MessagePosition ) ); _HostNode()->RegisterMessageListener( NodeProperty::SA_VELOCITY, MEMBER_FUNC_PTR( &ISoundComponent::MessageVelocity ) ); }
//--------------------------------------------------------------------------------------------------------- void VertexBufferResource::_PushReflushStream( const VertexStream& stream, const vector2d& interval ) { ReflushStream* reflush = NEW ReflushStream; reflush->FlushStream( interval, stream.GetVertexSize(), stream.GetBufferData( interval.m_x ) ); m_ReflushList[m_ChangeIndex].push_back( reflush ); IGraphicSystem::Instance()->HostedGraphicUpdata( MEMBER_FUNC_PTR(&VertexBufferResource::DoChangeVertexBuffer) ); }
//------------------------------------------------------------------------------------------------------ void RenderTargetResource::ListenResizeview() { if ( NULL == m_ResizeFunction ) { m_ResizeFunction = Framework::Instance()->RegistResizeviewListener( MEMBER_FUNC_PTR( &RenderTargetResource::OnResizeview ) ); } }
//-------------------------------------------------------------------------------------------------------------------------------------- bool StateLogo::OnEngineInDone(UIGroup& sender) { UIAnimation anim(1000); anim.ColorAnimation( Color(1,1,1,1), Color(1,1,1,0) ); anim.SetDelay( 3000 ); m_pEngineLogo->SetUIAnimation(anim, MEMBER_FUNC_PTR( &StateLogo::OnEnginOutDone ) ); return true; }
//------------------------------------------------------------------------------ void PostHandle::_OnStart() { SmartPtr<PostJob> pPostJob( NEW PostJob ); pPostJob->SetUrl(GetUrl()); pPostJob->SetPostContent(_GetPostContent().c_str()); pPostJob->SetUsername(GetUsername()); pPostJob->SetPassword(GetPassword()); pPostJob->Connect(); pPostJob->SetCallback( MEMBER_FUNC_PTR( &PostHandle::JobDoneCallBack )); _PushJob( pPostJob ); }
//------------------------------------------------------------------------------------------------------- void StateLogo::LoadResource(Engine& engine) { STRING.LoadPackage( ); engine.GetDevice()->SetClearScreenColor(1.0, 1.0, 1.0, 1.0); engine.GetCamera()->CreatePerspectiveProjection(10.0f , 450.0f ); engine.GetCamera()->LookAt( vector3f(0,0,0),vector3f(0,0,1),vector3f(0,1,0) ); //UIAnimation anim1(1000); //anim1.ColorAnimation( Color(1,1,1,1), Color(1,1,1,0) ); //anim1.SetDelay( 4000 ); //m_pStudioLogo = engine.GetUIManager()->CreateUIGroup(UIFileName[ui_StudioLogo]); //m_pStudioLogo->SetUIAnimation(anim1, MEMBER_FUNC_PTR( &StateLogo::OnLogoOutDone ) ); UIAnimation anim2(1000); anim2.ColorAnimation( Color(1,1,1,0), Color(1,1,1,1) ); m_pEngineLogo = engine.GetUIManager()->CreateUIGroup(UIFileName[ui_EngineLogo]); m_pEngineLogo->SetUIAnimation(anim2, MEMBER_FUNC_PTR( &StateLogo::OnEngineInDone ) ); //m_pEngineLogo->SetShow(false); //ReleaseResource::Instance().CreateReleaseTread();//开启一个释放线程 AdHelper::Instance().Where() = AdHelper::OS_TOPCENTER; AdHelper::Instance().setShowAd(true); }
//--------------------------------------------------------------------------------------------------------- void ThreadSystem::RegistEvent( BohgeEngine::Framework& framework ) { framework.RegisterEventListener( FrameworkEvent::ET_RENDER_ON_ENTRY, MEMBER_FUNC_PTR( &ThreadSystem::OnFrameworkEntry ) ); framework.RegisterEventListener( FrameworkEvent::ET_RENDER_ON_EXIT, MEMBER_FUNC_PTR( &ThreadSystem::OnFrameworkExit ) ); }
//------------------------------------------------------------------------------------------------------- void MaterialSystem::RegistEvent( Framework& framework ) { IMaterialSystem::RegistEvent( framework ); framework.RegisterEventListener( FrameworkEvent::ET_RENDER_ON_ENTRY, MEMBER_FUNC_PTR( &MaterialSystem::OnFrameworkEntry ) ); framework.RegisterEventListener( FrameworkEvent::ET_RENDER_ON_EXIT, MEMBER_FUNC_PTR( &MaterialSystem::OnFrameworkExit ) ); }
//------------------------------------------------------------------------------------------------------- void SoundSystemSLES::RegistEvent( BohgeEngine::Framework& framework ) { framework.RegisterEventListener( FrameworkEvent::ET_LOGIC_ON_ENTRY, MEMBER_FUNC_PTR( &SoundSystemSLES::OnFrameworkEntry ) ); framework.RegisterEventListener( FrameworkEvent::ET_LOGIC_ON_EXIT, MEMBER_FUNC_PTR( &SoundSystemSLES::OnFrameworkExit ) ); framework.RegisterEventListener( FrameworkEvent::ET_LOGIC_DO_UPDATE, MEMBER_FUNC_PTR( &SoundSystemSLES::OnUpdate ) ); }
//------------------------------------------------------------------------------------------------------- void OpenGLGraphicSystem::RegistEvent( BohgeEngine::Framework& framework ) { IGraphicSystem::RegistEvent( framework ); framework.RegisterEventListener( FrameworkEvent::ET_RENDER_ON_ENTRY, MEMBER_FUNC_PTR( &OpenGLGraphicSystem::OnFrameworkEntry ) ); framework.RegisterEventListener( FrameworkEvent::ET_RENDER_ON_EXIT, MEMBER_FUNC_PTR( &OpenGLGraphicSystem::OnFrameworkExit ) ); }
//--------------------------------------------------------------------------------------------------------- void SkeletonComponent::_DoOnAttachNode() { //连接数据源提供者 _HostNode()->RegisterAttributeProvider( NodeProperty::GA_ANIMATION_REAL, MEMBER_FUNC_PTR( &SkeletonComponent::AttributeAnimationReal ) ); _HostNode()->RegisterAttributeProvider( NodeProperty::GA_ANIMATION_DUAL, MEMBER_FUNC_PTR( &SkeletonComponent::AttributeAnimationDual ) ); }