#include <codecs.h>
Inheritance diagram for H323VideoCodec:
Public Types | |
enum | BitRateModeBits { None = 0x00, DynamicVideoQuality = 0x01, AdaptivePacketDelay = 0x02 } |
Public Member Functions | |
H323VideoCodec (const char *mediaFormat, Direction direction) | |
~H323VideoCodec () | |
virtual BOOL | Open (H323Connection &connection) |
virtual void | Close () |
virtual void | OnMiscellaneousCommand (const H245_MiscellaneousCommand_type &type) |
virtual void | OnMiscellaneousIndication (const H245_MiscellaneousIndication_type &type) |
virtual void | OnFreezePicture () |
virtual void | OnFastUpdatePicture () |
virtual void | OnFastUpdateGOB (unsigned firstGOB, unsigned numberOfGOBs) |
virtual void | OnFastUpdateMB (int firstGOB, int firstMB, unsigned numberOfMBs) |
virtual void | OnVideoIndicateReadyToActivate () |
virtual void | OnVideoTemporalSpatialTradeOffCommand (int newQuality) |
virtual void | OnVideoTemporalSpatialTradeOffIndication (int newQuality) |
virtual void | OnVideoNotDecodedMBs (unsigned firstMB, unsigned numberOfMBs, unsigned temporalReference) |
virtual void | OnLostPartialPicture () |
virtual void | OnLostPicture () |
int | GetWidth () const |
int | GetHeight () const |
virtual void | SetTxQualityLevel (int qlevel) |
virtual void | SetTxMinQuality (int qlevel) |
virtual void | SetTxMaxQuality (int qlevel) |
virtual void | SetBackgroundFill (int idle) |
unsigned | GetVideoMode (void) |
unsigned | SetVideoMode (unsigned mode) |
virtual BOOL | SetMaxBitRate (unsigned bitRate) |
virtual BOOL | SetTargetFrameTimeMs (unsigned ms) |
void | SendMiscCommand (unsigned command) |
virtual int | GetFrameNum () |
Protected Attributes | |
int | frameWidth |
int | frameHeight |
int | fillLevel |
unsigned | videoBitRateControlModes |
int | bitRateHighLimit |
unsigned | oldLength |
PTimeInterval | oldTime |
PTimeInterval | newTime |
int | targetFrameTimeMs |
int | frameBytes |
int | sumFrameTimeMs |
int | sumAdjFrameTimeMs |
int | sumFrameBytes |
int | videoQMax |
int | videoQMin |
int | videoQuality |
PTimeInterval | frameStartTime |
PTimeInterval | grabInterval |
int | frameNum |
int | packetNum |
int | oldPacketNum |
int | framesPerSec |
PMutex | videoHandlerActive |
An application may create a descendent off this class and override functions as required for descibing a specific codec.
|
|
|
Create a new video codec. This opens the standard image output device, for input and output and allows descendent codec classes to do video I/O after decoding/encoding.
|
|
|
|
Close down the codec. This will close the codec breaking any block on the Read() or Write() functions. The default behaviour will close the rawDataChannel if it is not NULL and thene delete it if delteChannel is TRUE. Implements H323Codec. |
|
Returns the number of frames transmitted or received so far. |
|
Get height of video |
|
Get the current value for video control mode |
|
Get width of video |
|
Process a FastUpdateGOB command from remote endpoint. The default behaviour does nothing. |
|
Process a FastUpdateMB command from remote endpoint. The default behaviour does nothing. |
|
Process a FastUpdatePicture command from remote endpoint. The default behaviour does nothing. Reimplemented in H323_H261Codec. |
|
Process a FreezePicture command from remote endpoint. The default behaviour does nothing. |
|
Process a request for a new frame, as part of the picture has been lost. Reimplemented in H323_Cu30Codec, and H323_H261Codec. |
|
Process a request for a new frame, as the entire picture has been lost. Reimplemented in H323_Cu30Codec, and H323_H261Codec. |
|
Process a miscellaneous command on the logical channel. The default behaviour does nothing.
Reimplemented from H323Codec. |
|
Process a miscellaneous indication on the logical channel. The default behaviour does nothing.
Reimplemented from H323Codec. |
|
Process a H.245 videoIndicateReadyToActivate indication from remote endpoint. The default behaviour does nothing. |
|
Process a H.245 videoNotDecodedMBs indication from remote endpoint. The default behaviour does nothing. |
|
Process a H.245 ideoTemporalSpatialTradeOff command from remote endpoint. The default behaviour does nothing. |
|
Process a H.245 videoTemporalSpatialTradeOff indication from remote endpoint. The default behaviour does nothing. |
|
Open the codec. This will open the codec for encoding or decoding. This is primarily used to delay allocation of resources until the last minute. The default behaviour calls the H323EndPoint::OpenVideoDevice() function and assigns the result of that function to the raw data channel in the H323Codec class.
Reimplemented from H323Codec. |
|
Send a miscellaneous command to the remote transmitting video codec. This message is sent via the H245 Logical Channel. |
|
number of blocks (that haven't changed) transmitted with each frame. These blocks fill in the background Reimplemented in H323_H261Codec. |
|
Set maximum bitrate when transmitting video. A value of 0 disables bit rate control. The average bitrate will be less depending on channel dead time, i.e. time that the channel could be transmitting bits but is not.
|
|
Set target time in milliseconds between video frames going through the channel. This sets the video frame rate through the channel, which is <= grabber frame rate. Encoder quality will be adjusted dynamically by the codec to find a frame size that allows sending at this rate. Default = 167 ms = 6 frames per second. A value of 0 means the channel will attempt to run at the video grabber frame rate Sometimes the channel cannot transmit as fast as the video grabber.
|
|
Maximum quality limit for the transmitted video. Default is 24. Encode quality will not be set above this value. Reimplemented in H323_H261Codec. |
|
Minimum quality limit for the transmitted video. Default is 1. Encode quality will not be set below this value. Reimplemented in H323_H261Codec. |
|
Quality of the transmitted video. 1 is good, 31 is poor. Reimplemented in H323_H261Codec. |
|
Set the current value for video control mode return the resulting value video control mode |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|