Overview
LG WebOS is the Smart TV platform used in LG televisions. The Adgent SDK provides native support for WebOS, including platform-specific remote control key codes, video player integration, and device capabilities detection.Supported Versions
- WebOS 3.0+: Fully supported
- Recommended: WebOS 4.0 or higher for optimal performance
Platform Detection
The SDK automatically detects WebOS platforms using the following patterns:- User agent matches
/Web0S/ior/WebOS/i - User agent matches
/LG.*NetCast/ior/LGE.*TV/i - Global object
window.webOSorwindow.PalmSystemexists
Platform-Specific Features
Native Video Player
WebOS provides native video player integration with hardware acceleration support:HDR & Advanced Codecs
WebOS TVs support advanced video capabilities:- HDR: Full HDR support
- Dolby Vision: Supported on compatible models
- Dolby Atmos: Supported for audio
- HEVC (H.265): Hardware decode support
- 4K Resolution: Up to 3840x2160
Voice Control
WebOS TVs include voice control capabilities through the Magic Remote:Hardware Decode Info
WebOS provides hardware video decode information for optimal streaming:Remote Control Key Codes
WebOS uses platform-specific key codes for remote control buttons:| Key Action | Key Code | Description |
|---|---|---|
| Enter | 13 | OK/Select button |
| Back | 461 | WebOS-specific back button |
| Left | 37 | Navigate left |
| Up | 38 | Navigate up |
| Right | 39 | Navigate right |
| Down | 40 | Navigate down |
| Play | 415 | Play media |
| Pause | 19 | Pause media |
| Stop | 413 | Stop playback |
| Fast Forward | 417 | Skip forward |
| Rewind | 412 | Skip backward |
| Info | 457 | Information button |
| Red | 403 | Red color button |
| Green | 404 | Green color button |
| Yellow | 405 | Yellow color button |
| Blue | 406 | Blue color button |
| Channel Up | 33 | Channel up |
| Channel Down | 34 | Channel down |
Key Code Normalization
Device Information
Access WebOS-specific device information:Code Example
Complete example for WebOS platform:Known Limitations
WebOS 3.0 Restrictions
- Limited HDR support on WebOS 3.x (HDR10 only, no Dolby Vision)
- 4K playback may be unstable on entry-level models
- Voice control requires WebOS 3.5+
Network Performance
- WebOS WiFi chips may struggle with bitrates > 10 Mbps on older models
- Recommend using adaptive bitrate streaming for best results
- External link opening (via
openExternalLink) is supported but may require user confirmation
Memory Constraints
- Long-running apps should call
sdk.destroy()to free resources - Avoid loading multiple high-bitrate ads in quick succession
- Monitor memory usage using
adapter.debug()for WebOS toast notifications
Video Codec Support
- HEVC support varies by model year (2016-2017 models have limited support)
- VP9 codec support is inconsistent across WebOS versions
- Always provide H.264 fallback for maximum compatibility
Debugging
WebOS provides native toast notifications for debugging:Best Practices
- Use Native Video Attributes: Apply WebOS-specific video attributes for immersive playback
- Handle Back Button: Always implement WebOS back button (key code 461) handling
- Optimize Bitrate: Use recommended 15 Mbps max for high-end WebOS TVs
- Test on Real Hardware: WebOS emulator behavior differs from actual TV hardware
- Clean Up Resources: Call
sdk.destroy()when navigating away from ad playback
