Is your feature request related to a problem? Please describe.
The current REGISTER_PEDHEADSHOT and REGISTER_PEDHEADSHOT_TRANSPARENT natives render ped headshots at a fixed, low resolution (128x128 / 256x256).
While this was optimal for PS3/Xbox 360-era memory limits and small in-game phone icons, it creates a significant visual downgrade on modern UI elements (1080p, 1440p, 4K display standards). On custom NUI elements like character selectors, IDs, licenses, and MDT/CAD systems, these native headshots appear extremely pixelated and blurry.
Currently, the only workaround for developers is to rely on external frame-capturing scripts (e.g., screenshot-basic) and stream captures via Discord Webhooks or external image hosts. This approach:
- Adds unnecessary network traffic/latency for both clients and servers.
- Requires third-party infrastructure for storing images.
- Creates edge cases where captures fail due to bad network conditions or slow camera transitions.
Describe the solution you’d like
It would be a massive quality-of-life improvement for UI/UX developers if FiveM provided a native way to request higher-resolution headshot textures directly from the RAGE engine render target.
Potential implementations:
- New Native / Extended Native: An extended native such as
REGISTER_PEDHEADSHOT_EX(ped, width, height)allowing developers to specify custom dimensions (e.g.,512x512or1024x1024). - Global Config Option: A resource manifest or runtime entry to scale up the default render target allocation for pedheadshots.
Describe alternatives you’ve considered
screenshot-basic/ Webhooks: Functional, but relies on taking a full screen/viewport capture, hiding HUDs, uploading to an external server, and fetching the URL back into NUI. It is inefficient compared to directly binding a local texture dictionary (txd) in UI.- In-engine Camera Target Buffers: Complex to maintain, resource-intensive, and prone to depth/clipping bugs when rendering ped heads dynamically in small UI components.
Additional Context
Providing native HD headshots would allow servers to display crisp, instant character previews natively in NUI/Scaleform without any external dependencies or network overhead.