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

📄 sm1doc.h

📁 linux下的一款播放器
💻 H
📖 第 1 页 / 共 2 页
字号:
/* ***** BEGIN LICENSE BLOCK ***** * Source last modified: $Id: sm1doc.h,v 1.2.12.1 2004/07/09 01:57:34 hubbe Exp $ *  * Portions Copyright (c) 1995-2004 RealNetworks, Inc. All Rights Reserved. *  * The contents of this file, and the files included with this file, * are subject to the current version of the RealNetworks Public * Source License (the "RPSL") available at * http://www.helixcommunity.org/content/rpsl unless you have licensed * the file under the current version of the RealNetworks Community * Source License (the "RCSL") available at * http://www.helixcommunity.org/content/rcsl, in which case the RCSL * will apply. You may also obtain the license terms directly from * RealNetworks.  You may not use this file except in compliance with * the RPSL or, if you have a valid RCSL with RealNetworks applicable * to this file, the RCSL.  Please see the applicable RPSL or RCSL for * the rights, obligations and limitations governing use of the * contents of the file. *  * Alternatively, the contents of this file may be used under the * terms of the GNU General Public License Version 2 or later (the * "GPL") in which case the provisions of the GPL are applicable * instead of those above. If you wish to allow use of your version of * this file only under the terms of the GPL, and not to allow others * to use your version of this file under the terms of either the RPSL * or RCSL, indicate your decision by deleting the provisions above * and replace them with the notice and other provisions required by * the GPL. If you do not delete the provisions above, a recipient may * use your version of this file under the terms of any one of the * RPSL, the RCSL or the GPL. *  * This file is part of the Helix DNA Technology. RealNetworks is the * developer of the Original Code and owns the copyrights in the * portions it created. *  * This file, and the files included with this file, is distributed * and made available on an 'AS IS' basis, WITHOUT WARRANTY OF ANY * KIND, EITHER EXPRESS OR IMPLIED, AND REALNETWORKS HEREBY DISCLAIMS * ALL SUCH WARRANTIES, INCLUDING WITHOUT LIMITATION, ANY WARRANTIES * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, QUIET * ENJOYMENT OR NON-INFRINGEMENT. *  * Technology Compatibility Kit Test Suite(s) Location: *    http://www.helixcommunity.org/content/tck *  * Contributor(s): *  * ***** END LICENSE BLOCK ***** */#ifndef _SM1DOC_H_#define _SM1DOC_H_#include "hxthread.h"#include "baseobj.h"class CSmil1Renderer;class CSmil1Parser;class CSmil1BasicRegion;class CSmil1RootLayout;class CHXHeader;struct SMIL1PlayToAssoc;struct SMIL1SourceInfo;class CSmil1LayoutEvent;class CSmil1ShowSiteEvent;class CSmil1EventHook;class CSmil1PassiveSiteWatcher;class CResourceLoader;class ProcessElementCallback;#ifdef _WINDOWSclass CHXDIBits;#endif#if defined(_UNIX) && (!(defined(_BEOS))) && (!(defined(_MAC_UNIX)))#include <X11/Xlib.h>#include <X11/Xutil.h>typedef ULONG32 COLORTYPE;class XData{  public:      XData()      {	  m_Pixmap = 0;	  m_Display = 0;      }      ~XData()      {	  if (m_Pixmap != 0)	  {              XFreePixmap(m_Display, m_Pixmap);	  }      }  public:      HXBitmapInfoHeader m_backgroundBitmapInfoHeader;      Pixmap m_Pixmap;      Display* m_Display;      Colormap m_colormap;};#endif    // _UNIXclass CSmil1DocumentRenderer:  public IHXSiteUser,			       public IHXRendererAdviseSink,			       public IHXGroupSink,			       public IHXValues,			       public CSmil1ElementHandler,			       public IHXPassiveSiteWatcher,                               public CHXBaseCountingObject{public:    CSmil1DocumentRenderer	    (CSmil1Renderer* pParent,				    IUnknown* pContext);    virtual ~CSmil1DocumentRenderer  ();    HX_RESULT close		    (CSmil1Renderer* pParent);    HX_RESULT setDocument	    (const char* pFragment);    HX_RESULT onPacket		    (IHXBuffer* pBuffer,				    BOOL bIsFinal);    HX_RESULT handleLButtonUp	    (const char* pID,				    UINT16 uXPos,				    UINT16 uYPos);    HX_RESULT handleMouseMove	    (void* pWindow,				    const char* pID,				    UINT16 uXPos,				    UINT16 uYPos);    BOOL handleSetCursor	    ();    HX_RESULT detachSite	    (IHXSite* pSite);    double			    getResizeXScale()				    {					return m_dResizeXScale;				    }    double			    getResizeYScale()				    {					return m_dResizeYScale;				    }    HX_RESULT addShowEvents	    (const char* pRegionName,				    IHXSite* pSite);    /*     * IUnknown methods     */    STDMETHOD(QueryInterface)	    (THIS_				    REFIID riid,				    void** ppvObj);    STDMETHOD_(ULONG32, AddRef)	    (THIS);    STDMETHOD_(ULONG32, Release)    (THIS);    /*     * IHXSiteUser methods     */    STDMETHOD(AttachSite)	    (THIS_				    IHXSite* pSite);    STDMETHOD(DetachSite)	    (THIS);    STDMETHOD(HandleEvent)	    (THIS_				    HXxEvent* pEvent);    STDMETHOD_(BOOL,NeedsWindowedSites)	(THIS);    /*     * IHXRendererAdviseSink methods     */    STDMETHOD(TrackDurationSet)		(THIS_					UINT32 ulGroupIndex,					UINT32 ulTrackIndex,					UINT32 ulDuration,					UINT32 ulDelay,					BOOL   bIsLive);    STDMETHOD(RepeatedTrackDurationSet)	(THIS_					const char*  pID,					UINT32 ulDuration,									        BOOL   bIsLive);    STDMETHOD(RendererInitialized)	(THIS_					IHXRenderer* pRend,					IUnknown* pStream,					IHXValues* pInfo);    STDMETHOD(RendererClosed)		(THIS_					IHXRenderer* pRend,					IHXValues* pInfo);    // /POST-RP8REV release IHXRendererAdviseSink method:    STDMETHOD(TrackUpdated)             (THIS_ UINT32 ulGroupIndex, UINT32 ulTrackIndex,                                               IHXValues* pValues);    /*     * IHXGroupSink methods     */    STDMETHOD(GroupAdded)		(THIS_					UINT16		uGroupIndex,					IHXGroup*	pGroup);    STDMETHOD(GroupRemoved)		(THIS_					UINT16		uGroupIndex,					IHXGroup*	pGroup);    STDMETHOD(AllGroupsRemoved)		(THIS);    STDMETHOD(TrackAdded)		(THIS_					UINT16		uGroupIndex,					UINT16		uTrackIndex,					IHXValues*	pTrack);    STDMETHOD(TrackRemoved)		(THIS_					UINT16		uGroupIndex,					UINT16		uTrackIndex,					IHXValues*	pTrack);    STDMETHOD(TrackStarted)		(THIS_					UINT16		uGroupIndex,					UINT16		uTrackIndex,					IHXValues*	pTrack);    STDMETHOD(TrackStopped)		(THIS_					UINT16		uGroupIndex,					UINT16		uTrackIndex,					IHXValues*	pTrack);    STDMETHOD(CurrentGroupSet)		(THIS_					UINT16		uGroupIndex,					IHXGroup*	pGroup);    /*     * IHXValues methods     */    STDMETHOD(SetPropertyULONG32)	(THIS_					const char*	 pPropertyName,					ULONG32		 uPropertyValue);    STDMETHOD(GetPropertyULONG32)	(THIS_					const char*	 pPropertyName,					REF(ULONG32)	 uPropertyValue);    STDMETHOD(GetFirstPropertyULONG32)	(THIS_					REF(const char*) pPropertyName,					REF(ULONG32)	 uPropertyValue);    STDMETHOD(GetNextPropertyULONG32)	(THIS_					REF(const char*) pPropertyName,					REF(ULONG32)	 uPropertyValue);    STDMETHOD(SetPropertyBuffer)	(THIS_					const char*	 pPropertyName,					IHXBuffer*	 pPropertyValue);    STDMETHOD(GetPropertyBuffer)	(THIS_					const char*	 pPropertyName,					REF(IHXBuffer*) pPropertyValue);    STDMETHOD(GetFirstPropertyBuffer)	(THIS_					REF(const char*) pPropertyName,					REF(IHXBuffer*) pPropertyValue);    STDMETHOD(GetNextPropertyBuffer)	(THIS_					REF(const char*) pPropertyName,					REF(IHXBuffer*) pPropertyValue);    STDMETHOD(SetPropertyCString)	(THIS_					const char*	 pPropertyName,					IHXBuffer*	 pPropertyValue);    STDMETHOD(GetPropertyCString)	(THIS_					const char*	 pPropertyName,					REF(IHXBuffer*) pPropertyValue);    STDMETHOD(GetFirstPropertyCString)	(THIS_					REF(const char*) pPropertyName,					REF(IHXBuffer*) pPropertyValue);    STDMETHOD(GetNextPropertyCString)	(THIS_					REF(const char*) pPropertyName,					REF(IHXBuffer*) pPropertyValue);    /*     *	IHXPassiveSiteWatcher methods     */    STDMETHOD(PositionChanged) (THIS_				HXxPoint* /*IN*/ pPoint);    STDMETHOD(SizeChanged) 	(THIS_				HXxSize* /*IN*/ pSize);    /*     * CSmil1ElementHandler methods     */    HX_RESULT handleAddGroup		(CSmil1AddGroup* pAddGroup);    HX_RESULT handleRegion		(CSmil1Region* pRegion);    HX_RESULT handleRootLayout		(CSmil1RootLayout* pRootLayout);    HX_RESULT handleSource		(CSmil1Source* pSource);    HX_RESULT handleMeta		(CSmil1Meta* pMeta);    HX_RESULT handleEndLayout		(CSmil1EndLayout* pSource);    HX_RESULT handleRendererPreFetch	(CSmil1RendererPreFetch* pRend);    HX_RESULT handleSourceUpdate	(CSmil1SourceUpdate* pUpdate);    /*     * CSmil1Parser methods     */    HX_RESULT onHeader			(IHXValues* pHeader);    HX_RESULT onTimeSync		(UINT32 ulTimeValue);    HX_RESULT onPreSeek			(UINT32 ulOldTime,					UINT32 ulNewTime);    HX_RESULT endStream			();    HX_RESULT seekTo			(const char* pElementID);    CSmil1BasicRegion* getRegion		(const char* pID);    void resizeRegion			(const char* pRegionName,					HXxSize* pNewSize);    void repositionRegion		(const char* pRegionName,					HXxPoint* pNewPosition);    void setTopLevelSiteSize		();    HX_RESULT HandleSurfaceUpdate	(HXxEvent* pEvent,					IHXSite* pSite,					HXxColor ulBGColor);    HX_RESULT getErrorInfo		(REF(UINT32) ulErrorLine,					 REF(UINT32) ulErrorColumn,					 REF(IHXBuffer*) pErrorText);    HX_RESULT		 GetElementProperties(UINT16		uGroupID, 					      UINT16		uTrackID, 					      REF(IHXValues*)	pProperties);    HX_RESULT		 GetElementStatus(UINT16	    uGroupID,					  UINT16	    uTrackID,					  UINT32	    ulCurrentTime,					  REF(IHXValues*)  pStatus);    HX_RESULT		 AttachElementLayout(UINT16	    uGroupID,					     UINT16	    uTrackID,					     IHXRenderer*  pRenderer,					     IHXStream*    pStream,					     IHXValues*    pProps);    HX_RESULT		 DetachElementLayout(IUnknown*	    pLSG);    BOOL				m_bSiteChangingSize;    BOOL				m_bNeedToAdjustSites;    UINT32				m_ulNoRootLayoutHeight;    UINT32				m_ulNoRootLayoutWidth;    BOOL                                isRootLayoutWidthSet() const  { return m_bRootLayoutWidthSet;  }    BOOL                                isRootLayoutHeightSet() const { return m_bRootLayoutHeightSet; }    friend class CSmil1Renderer;private:    HX_RESULT addSiteForRenderer	(SMIL1PlayToAssoc* pPlayToAssoc,					SMIL1SourceInfo* pSMIL1SourceInfo,					IHXRenderer* pRenderer,					BOOL bNoRegion);    void setPlayToAssoc			(UINT16 uGroupIndex, 					UINT16 uTrackIndex, 					const char* pID,					const char* pRepeatID, // /For SHAZAM					const char* pPlayTo,					const char* pRegionName);    SMIL1PlayToAssoc* getPlayToAssoc	(UINT16 uGroupIndex, 					UINT16 uTrackIndex);    SMIL1PlayToAssoc* getPlayToAssoc	(const char* pName);     void removeAllPlayToAssoc		();    void removeGroupsPlayToAssoc	(UINT16	uGroupIndex);    void removeSourcemap		(SMIL1PlayToAssoc* pPlayToAssoc);    HX_RESULT insertEvent		(CSmil1ShowSiteEvent* pEvent);

⌨️ 快捷键说明

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