diff options
Diffstat (limited to 'modules/webrtc/webrtc_data_channel_js.cpp')
-rw-r--r-- | modules/webrtc/webrtc_data_channel_js.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/modules/webrtc/webrtc_data_channel_js.cpp b/modules/webrtc/webrtc_data_channel_js.cpp index dfbec80c86..31d6a0568c 100644 --- a/modules/webrtc/webrtc_data_channel_js.cpp +++ b/modules/webrtc/webrtc_data_channel_js.cpp @@ -46,6 +46,7 @@ extern int godot_js_rtc_datachannel_id_get(int p_id); extern int godot_js_rtc_datachannel_max_packet_lifetime_get(int p_id); extern int godot_js_rtc_datachannel_max_retransmits_get(int p_id); extern int godot_js_rtc_datachannel_is_negotiated(int p_id); +extern int godot_js_rtc_datachannel_get_buffered_amount(int p_id); extern char *godot_js_rtc_datachannel_label_get(int p_id); // Must free the returned string. extern char *godot_js_rtc_datachannel_protocol_get(int p_id); // Must free the returned string. extern void godot_js_rtc_datachannel_destroy(int p_id); @@ -181,6 +182,10 @@ bool WebRTCDataChannelJS::is_negotiated() const { return godot_js_rtc_datachannel_is_negotiated(_js_id); } +int WebRTCDataChannelJS::get_buffered_amount() const { + return godot_js_rtc_datachannel_get_buffered_amount(_js_id); +} + WebRTCDataChannelJS::WebRTCDataChannelJS() { } |