Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
nheko
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Nheko Reborn
nheko
Commits
459c5990
Commit
459c5990
authored
4 years ago
by
trilene
Committed by
Nicolas Werner
4 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fix one-way video calls
parent
71240249
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
resources/qml/voip/ActiveCallBar.qml
+1
-1
1 addition, 1 deletion
resources/qml/voip/ActiveCallBar.qml
src/CallManager.h
+2
-0
2 additions, 0 deletions
src/CallManager.h
src/WebRTCSession.cpp
+23
-1
23 additions, 1 deletion
src/WebRTCSession.cpp
src/WebRTCSession.h
+1
-0
1 addition, 0 deletions
src/WebRTCSession.h
with
27 additions
and
2 deletions
resources/qml/voip/ActiveCallBar.qml
+
1
−
1
View file @
459c5990
...
...
@@ -148,7 +148,7 @@ Rectangle {
}
ImageButton
{
visible
:
CallManager
.
is
Video
visible
:
CallManager
.
haveLocal
Video
width
:
24
height
:
24
buttonTextColor
:
"
#000000
"
...
...
This diff is collapsed.
Click to expand it.
src/CallManager.h
+
2
−
0
View file @
459c5990
...
...
@@ -25,6 +25,7 @@ class CallManager : public QObject
Q_PROPERTY
(
bool
haveCallInvite
READ
haveCallInvite
NOTIFY
newInviteState
)
Q_PROPERTY
(
bool
isOnCall
READ
isOnCall
NOTIFY
newCallState
)
Q_PROPERTY
(
bool
isVideo
READ
isVideo
NOTIFY
newInviteState
)
Q_PROPERTY
(
bool
haveLocalVideo
READ
haveLocalVideo
NOTIFY
newCallState
)
Q_PROPERTY
(
webrtc
::
State
callState
READ
callState
NOTIFY
newCallState
)
Q_PROPERTY
(
QString
callParty
READ
callParty
NOTIFY
newInviteState
)
Q_PROPERTY
(
QString
callPartyAvatarUrl
READ
callPartyAvatarUrl
NOTIFY
newInviteState
)
...
...
@@ -40,6 +41,7 @@ public:
bool
haveCallInvite
()
const
{
return
haveCallInvite_
;
}
bool
isOnCall
()
const
{
return
session_
.
state
()
!=
webrtc
::
State
::
DISCONNECTED
;
}
bool
isVideo
()
const
{
return
isVideo_
;
}
bool
haveLocalVideo
()
const
{
return
session_
.
haveLocalVideo
();
}
webrtc
::
State
callState
()
const
{
return
session_
.
state
();
}
QString
callParty
()
const
{
return
callParty_
;
}
QString
callPartyAvatarUrl
()
const
{
return
callPartyAvatarUrl_
;
}
...
...
This diff is collapsed.
Click to expand it.
src/WebRTCSession.cpp
+
23
−
1
View file @
459c5990
...
...
@@ -555,7 +555,10 @@ getResolution(GstPad *pad)
void
addCameraView
(
GstElement
*
pipe
,
const
std
::
pair
<
int
,
int
>
&
videoCallSize
)
{
GstElement
*
tee
=
gst_bin_get_by_name
(
GST_BIN
(
pipe
),
"videosrctee"
);
GstElement
*
tee
=
gst_bin_get_by_name
(
GST_BIN
(
pipe
),
"videosrctee"
);
if
(
!
tee
)
return
;
GstElement
*
queue
=
gst_element_factory_make
(
"queue"
,
nullptr
);
GstElement
*
videorate
=
gst_element_factory_make
(
"videorate"
,
nullptr
);
gst_bin_add_many
(
GST_BIN
(
pipe
),
queue
,
videorate
,
nullptr
);
...
...
@@ -1152,6 +1155,19 @@ WebRTCSession::addVideoPipeline(int vp8PayloadType)
return
true
;
}
bool
WebRTCSession
::
haveLocalVideo
()
const
{
if
(
isVideo_
&&
state_
>=
State
::
INITIATED
)
{
GstElement
*
tee
=
gst_bin_get_by_name
(
GST_BIN
(
pipe_
),
"videosrctee"
);
if
(
tee
)
{
gst_object_unref
(
tee
);
return
true
;
}
}
return
false
;
}
bool
WebRTCSession
::
isMicMuted
()
const
{
...
...
@@ -1326,6 +1342,12 @@ WebRTCSession::havePlugins(bool, std::string *)
return
false
;
}
bool
WebRTCSession
::
haveLocalVideo
()
const
{
return
false
;
}
bool
WebRTCSession
::
createOffer
(
bool
)
{
...
...
This diff is collapsed.
Click to expand it.
src/WebRTCSession.h
+
1
−
0
View file @
459c5990
...
...
@@ -43,6 +43,7 @@ public:
bool
havePlugins
(
bool
isVideo
,
std
::
string
*
errorMessage
=
nullptr
);
webrtc
::
State
state
()
const
{
return
state_
;
}
bool
isVideo
()
const
{
return
isVideo_
;
}
bool
haveLocalVideo
()
const
;
bool
isOffering
()
const
{
return
isOffering_
;
}
bool
isRemoteVideoRecvOnly
()
const
{
return
isRemoteVideoRecvOnly_
;
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment