Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Video Compatibility on webOS 6.x #420

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/app/stream/session.c
Original file line number Diff line number Diff line change
Expand Up @@ -205,12 +205,13 @@ void streaming_set_hdr(session_t *session, bool hdr) {
populate_hdr_info_vui(&info, &session->config.stream);
SS4S_PlayerVideoSetHDRInfo(session->player, &info);
} else {
// Magic numbers from Stadia
SS4S_VideoHDRInfo info = {
.displayPrimariesX = {34000, 13250, 7500},
.displayPrimariesY = {16000, 34500, 3000},
.whitePointX = 15635,
.whitePointY = 16450,
.maxDisplayMasteringLuminance = 1000 * LUMINANCE_SCALE,
.maxDisplayMasteringLuminance = 1000,
.minDisplayMasteringLuminance = 50,
.maxContentLightLevel = 1000,
.maxPicAverageLightLevel = 400,
Expand Down
12 changes: 8 additions & 4 deletions src/app/stream/video/session_video.c
Original file line number Diff line number Diff line change
Expand Up @@ -104,12 +104,13 @@ int vdec_delegate_setup(int videoFormat, int width, int height, int redrawRate,
}

switch (SS4S_PlayerVideoOpen(player, &info)) {
case SS4S_VIDEO_OPEN_ERROR:
return CALLBACKS_SESSION_ERROR_VDEC_ERROR;
case SS4S_VIDEO_OPEN_OK: {
return 0;
}
case SS4S_VIDEO_OPEN_UNSUPPORTED_CODEC:
return CALLBACKS_SESSION_ERROR_VDEC_UNSUPPORTED;
default:
return 0;
return CALLBACKS_SESSION_ERROR_VDEC_ERROR;
}
}

Expand Down Expand Up @@ -169,8 +170,11 @@ int vdec_delegate_submit(PDECODE_UNIT decodeUnit) {
} else if (result == SS4S_VIDEO_FEED_ERROR) {
session_interrupt(session, false, STREAMING_INTERRUPT_DECODER);
return DR_OK;
} else {
} else if (result == SS4S_VIDEO_FEED_REQUEST_KEYFRAME) {
return DR_NEED_IDR;
} else {
commons_log_debug("Session", "Ignoring frame %d, feed result %d", decodeUnit->frameNumber, result);
return DR_OK;
}
}

Expand Down