Skip to content

Commit

Permalink
fix: round non-int video dimension values (#1007)
Browse files Browse the repository at this point in the history
  • Loading branch information
szuperaz authored Aug 29, 2023
1 parent 6d86925 commit baec0b5
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packages/client/src/Call.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1120,6 +1120,12 @@ export class Call {
const participants = this.state.updateParticipants(
Object.entries(changes).reduce<StreamVideoParticipantPatches>(
(acc, [sessionId, change]) => {
if (change.dimension?.height) {
change.dimension.height = Math.ceil(change.dimension.height);
}
if (change.dimension?.width) {
change.dimension.width = Math.ceil(change.dimension.width);
}
const prop: keyof StreamVideoParticipant | undefined =
kind === 'video'
? 'videoDimension'
Expand Down

0 comments on commit baec0b5

Please sign in to comment.