#include <RTCP.h>
Inheritance diagram for TAO_AV_RTCP_Object:


Public Member Functions | |
| TAO_AV_RTCP_Object (TAO_AV_Callback *client_cb, TAO_AV_RTCP_Callback *&rtcp_cb, TAO_AV_Transport *transport=0) | |
| constructor. | |
| virtual | ~TAO_AV_RTCP_Object (void) |
| Destructor. | |
| virtual int | handle_input (void) |
| virtual int | handle_control_input (ACE_Message_Block *frame, const ACE_Addr &peer_address) |
| Called on a control object. | |
| virtual int | handle_control_output (ACE_Message_Block *frame) |
| virtual int | set_policies (const TAO_AV_PolicyList &policy_list) |
| set/get policies. | |
| virtual int | start (void) |
| start/stop the flow. | |
| virtual int | stop (void) |
| virtual int | send_frame (ACE_Message_Block *frame, TAO_AV_frame_info *frame_info=0) |
| send a data frame. | |
| virtual int | send_frame (const iovec *iov, int iovcnt, TAO_AV_frame_info *frame_info=0) |
| send a frame in iovecs. | |
| virtual int | send_frame (const char *buf, size_t len) |
| virtual int | destroy (void) |
| end the stream. | |
| void | ssrc (ACE_UINT32 ssrc) |
| ACE_UINT32 | ssrc (void) |
| void | ts_offset (ACE_UINT32 ts_offset) |
Private Attributes | |
| TAO_AV_Callback * | client_cb_ |
| TAO_AV_RTCP_Callback | rtcp_cb_ |
| ACE_UINT32 | ssrc_ |
Definition at line 199 of file RTCP.h.
|
||||||||||||||||
|
constructor.
Definition at line 431 of file RTCP.cpp. References client_cb_, and rtcp_cb_.
00434 :TAO_AV_Protocol_Object (&rtcp_cb_, transport) 00435 { 00436 rtcp_cb = &this->rtcp_cb_; 00437 this->client_cb_ = client_cb; 00438 00439 } |
|
|
Destructor.
Definition at line 441 of file RTCP.cpp.
00442 {
00443 }
|
|
|
end the stream.
Implements TAO_AV_Protocol_Object. Definition at line 446 of file RTCP.cpp. References TAO_AV_Callback::handle_destroy().
00447 {
00448 this->callback_->handle_destroy ();
00449 delete this;
00450
00451 return 0;
00452 }
|
|
||||||||||||
|
Called on a control object.
Reimplemented from TAO_AV_Protocol_Object. Definition at line 473 of file RTCP.cpp. References TAO_AV_Callback::receive_frame().
00475 {
00476 return this->callback_->receive_frame (frame,
00477 0,
00478 peer_address);
00479 }
|
|
|
Definition at line 482 of file RTCP.cpp. References TAO_AV_RTCP_Callback::send_frame(). Referenced by TAO_AV_RTP_Object::send_frame().
00483 {
00484 TAO_AV_RTCP_Callback *cb = dynamic_cast<TAO_AV_RTCP_Callback*> (this->callback_);
00485
00486 return cb->send_frame (frame);
00487 }
|
|
|
Implements TAO_AV_Protocol_Object. Definition at line 384 of file RTCP.cpp. References ACE_DEBUG, TAO_AV_Transport::get_peer_addr(), LM_ERROR, TAO_AV_Transport::mtu(), ACE_Message_Block::rd_ptr(), TAO_AV_Callback::receive_control_frame(), TAO_AV_Transport::recv(), TAO_debug_level, and ACE_Message_Block::wr_ptr().
00385 {
00386 size_t bufsiz = 2*this->transport_->mtu ();
00387 ACE_Message_Block data (bufsiz);
00388
00389 int n = this->transport_->recv (data.rd_ptr (),bufsiz);
00390 if (n == 0)
00391 {
00392 if (TAO_debug_level > 0)
00393 ACE_DEBUG ((LM_ERROR, "TAO_AV_RTCP::handle_input:connection closed\n"));
00394 return -1;
00395 }
00396 if (n < 0)
00397 {
00398 if (TAO_debug_level > 0)
00399 ACE_DEBUG ((LM_ERROR,"TAO_AV_RTCP::handle_input:recv error\n"));
00400 return -1;
00401 }
00402 data.wr_ptr (n);
00403 ACE_Addr *peer_addr = this->transport_->get_peer_addr ();
00404 this->callback_->receive_control_frame (&data,*peer_addr);
00405 return 0;
00406 }
|
|
||||||||||||
|
Implements TAO_AV_Protocol_Object. Definition at line 425 of file RTCP.cpp.
00427 {
00428 return 0;
00429 }
|
|
||||||||||||||||
|
send a frame in iovecs.
Implements TAO_AV_Protocol_Object. Definition at line 416 of file RTCP.cpp. References TAO_AV_Transport::send().
00419 {
00420 return this->transport_->send (iov,
00421 iovcnt);
00422 }
|
|
||||||||||||
|
send a data frame.
Implements TAO_AV_Protocol_Object. Definition at line 409 of file RTCP.cpp. References TAO_AV_Transport::send().
00411 {
00412 return this->transport_->send (frame);
00413 }
|
|
|
set/get policies.
Reimplemented from TAO_AV_Protocol_Object. Definition at line 455 of file RTCP.cpp. References TAO_AV_PolicyList.
00456 {
00457 return -1;
00458 }
|
|
|
Definition at line 239 of file RTCP.h.
00239 { return this->ssrc_; }
|
|
|
Definition at line 238 of file RTCP.h. Referenced by TAO_AV_RTP_Object::control_object(), TAO_AV_RTP_Object::send_frame(), and TAO_AV_RTCP_Callback::send_report().
00238 {this->ssrc_ = ssrc; }
|
|
|
start/stop the flow.
Reimplemented from TAO_AV_Protocol_Object. Definition at line 461 of file RTCP.cpp. References TAO_AV_Callback::handle_start().
00462 {
00463 return this->callback_->handle_start ();
00464 }
|
|
|
Reimplemented from TAO_AV_Protocol_Object. Definition at line 467 of file RTCP.cpp. References TAO_AV_Callback::handle_stop().
00468 {
00469 return this->callback_->handle_stop ();
00470 }
|
|
|
Definition at line 490 of file RTCP.cpp. References TAO_AV_RTCP_Callback::ts_offset(). Referenced by TAO_AV_RTP_Object::control_object().
00491 {
00492 TAO_AV_RTCP_Callback *cb = dynamic_cast<TAO_AV_RTCP_Callback*> (this->callback_);
00493 cb->ts_offset (ts_offset);
00494 }
|
|
|
Definition at line 245 of file RTCP.h. Referenced by TAO_AV_RTCP_Object(). |
|
|
Definition at line 246 of file RTCP.h. Referenced by TAO_AV_RTCP_Object(). |
|
|
|
1.3.6