Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

56 lines
1.5 KiB

  1. //------------------------------------------------------------------------------
  2. // File: AMExtra.h
  3. //
  4. // Desc: DirectShow base classes.
  5. //
  6. // Copyright (c) 1992-2001 Microsoft Corporation. All rights reserved.
  7. //------------------------------------------------------------------------------
  8. #ifndef __AMEXTRA__
  9. #define __AMEXTRA__
  10. // Simple rendered input pin
  11. //
  12. // NOTE if your filter queues stuff before rendering then it may not be
  13. // appropriate to use this class
  14. //
  15. // In that case queue the end of stream condition until the last sample
  16. // is actually rendered and flush the condition appropriately
  17. class CRenderedInputPin : public CBaseInputPin
  18. {
  19. public:
  20. CRenderedInputPin(TCHAR *pObjectName,
  21. CBaseFilter *pFilter,
  22. CCritSec *pLock,
  23. HRESULT *phr,
  24. LPCWSTR pName);
  25. #ifdef UNICODE
  26. CRenderedInputPin(CHAR *pObjectName,
  27. CBaseFilter *pFilter,
  28. CCritSec *pLock,
  29. HRESULT *phr,
  30. LPCWSTR pName);
  31. #endif
  32. // Override methods to track end of stream state
  33. STDMETHODIMP EndOfStream();
  34. STDMETHODIMP EndFlush();
  35. HRESULT Active();
  36. HRESULT Run(REFERENCE_TIME tStart);
  37. protected:
  38. // Member variables to track state
  39. BOOL m_bAtEndOfStream; // Set by EndOfStream
  40. BOOL m_bCompleteNotified; // Set when we notify for EC_COMPLETE
  41. private:
  42. void DoCompleteHandling();
  43. };
  44. #endif // __AMEXTRA__