Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 // Implement a DirectShow input pin used for receiving captured frames from | |
| 6 // a DirectShow Capture filter. | |
| 7 | |
| 8 #ifndef MEDIA_VIDEO_CAPTURE_WIN_SINK_INPUT_PIN_WIN_H_ | |
| 9 #define MEDIA_VIDEO_CAPTURE_WIN_SINK_INPUT_PIN_WIN_H_ | |
| 10 #pragma once | |
| 11 | |
| 12 #include "media/video/capture/video_capture_device.h" | |
| 13 #include "media/video/capture/win/sink_filter_win.h" | |
| 14 #include "media/video/capture/win/pin_base_win.h" | |
| 15 | |
| 16 namespace media { | |
| 17 | |
| 18 // Input pin of the SinkFilter. | |
| 19 class SinkInputPin : public PinBase { | |
| 20 public: | |
| 21 explicit SinkInputPin(IBaseFilter* filter, | |
|
scherkus (not reviewing)
2011/06/24 20:15:26
>1 params -> no explicit
Per K
2011/06/27 11:47:50
Done.
| |
| 22 SinkFilter::SinkFilterObserver* observer); | |
| 23 virtual ~SinkInputPin(); | |
| 24 | |
| 25 void SetRequestedMediaCapability( | |
| 26 const VideoCaptureDevice::Capability& capability); | |
| 27 // Returns the capability that is negotiated when this | |
| 28 // pin is connected to a media filter. | |
| 29 const VideoCaptureDevice::Capability& ResultingCapability(); | |
| 30 | |
| 31 // Implement PinBase. | |
| 32 virtual bool IsMediaTypeValid(const AM_MEDIA_TYPE* media_type); | |
| 33 virtual bool GetValidMediaType(int index, AM_MEDIA_TYPE* media_type); | |
| 34 | |
| 35 STDMETHOD(Receive)(IMediaSample* media_sample); | |
| 36 | |
| 37 private: | |
| 38 VideoCaptureDevice::Capability requested_capability_; | |
| 39 VideoCaptureDevice::Capability resulting_capability_; | |
| 40 SinkFilter::SinkFilterObserver* const observer_; | |
|
scherkus (not reviewing)
2011/06/24 20:15:26
no need for const pointers
Per K
2011/06/27 11:47:50
Done.
| |
| 41 | |
| 42 DISALLOW_IMPLICIT_CONSTRUCTORS(SinkInputPin); | |
| 43 }; | |
| 44 | |
| 45 } // namespace media | |
| 46 | |
| 47 #endif // MEDIA_VIDEO_CAPTURE_WIN_SINK_INPUT_PIN_WIN_H_ | |
| OLD | NEW |