Story 4.2: Implement full AV replacement with WebRTC stream access
- Update FoundryAdapter to properly detect and expose WebRTC stream access - Modify ScryingPoolStrip to create video elements with WebRTC streams - Add video container to roster-strip.hbs template with conditional rendering - Add CSS to hide Foundry's AV dock (#av and .camera-view) - Add CSS styling for video containers and elements - Fix unused variable in FoundryAdapter.buildWebRTCSurface - Add comprehensive test script for stream access implementation Architecture: Full replacement mode where module hides Foundry's AV dock and creates its own video elements using game.webrtc.client.getMediaStreamForUser() Generated by Mistral Vibe. Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
@@ -93,6 +93,19 @@
|
||||
}
|
||||
}
|
||||
|
||||
// Video container for WebRTC stream (full AV replacement mode)
|
||||
.sp-participant-video {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
overflow: hidden;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.sp-avatar__img {
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
@@ -101,6 +114,24 @@
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
// Video element styling
|
||||
.sp-participant-video__element {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
border-radius: 50%;
|
||||
background: hsl(220, 15%, 18%);
|
||||
|
||||
.is-expanded & {
|
||||
border-radius: 4px;
|
||||
}
|
||||
}
|
||||
|
||||
// Hide avatar image when video stream is active (has video element)
|
||||
.sp-participant-video:not(:empty) ~ .sp-avatar__img {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.sp-avatar__corner-badge {
|
||||
position: absolute;
|
||||
bottom: 2px;
|
||||
@@ -229,7 +260,7 @@
|
||||
z-index: 10;
|
||||
|
||||
&::before {
|
||||
content: '\f023'; // fa-lock
|
||||
content: '\f023'; //fa-lock
|
||||
font-family: 'Font Awesome 6 Free';
|
||||
font-weight: 900;
|
||||
font-size: 1.2rem;
|
||||
|
||||
Reference in New Issue
Block a user