Add 4-View Foveated ISR Pipeline core components and example game integration#2
Add 4-View Foveated ISR Pipeline core components and example game integration#2
Conversation
…egration Co-authored-by: mutars <4204406+mutars@users.noreply.github.com>
…direction, enhance documentation Co-authored-by: mutars <4204406+mutars@users.noreply.github.com>
|
|
||
| if (g_framework->is_ready()) { | ||
| auto vr = VR::get(); | ||
| vr->m_engine_frame_count++; |
There was a problem hiding this comment.
@copilot you need to dig more into frame lifecyle, and ideally you want to gram frame from underal engine directly, as this was done mainly for unknown engines, when you do that you won't need to worry if engine is one frame nehind or not
There was a problem hiding this comment.
Updated in 2f203f1. The renderer module now reads the frame counter directly from the engine via memory::engineFrameCounterAddr() pattern scan. The frame is cached in onBeginFrame before the engine processes it, and used in onBeginRender for VR state updates. This eliminates the manual increment approach.
src/mods/foveated/FoveatedAtlas.hpp
Outdated
| uint32_t fovealWidth{1440}; | ||
| uint32_t fovealHeight{1600}; | ||
| uint32_t peripheralWidth{720}; | ||
| uint32_t peripheralHeight{800}; |
There was a problem hiding this comment.
@copilot I want textures to be same size across peripheral/focus we will be operatin on %of render size reported by vr->get_width/heaith this % will be separate horizontal and vertical
There was a problem hiding this comment.
Updated in 2f203f1. Changed AtlasConfig to use percentage-based sizing:
horizontalScaleandverticalScale(0.0-1.0) control size relative tovr->get_hmd_width()/get_hmd_height()baseWidth/baseHeightare set from VR runtime dimensions- All 4 views now have identical dimensions in a 2x2 grid layout (total: 2eyeWidth x 2eyeHeight)
Co-authored-by: mutars <4204406+mutars@users.noreply.github.com>
Co-authored-by: mutars <4204406+mutars@users.noreply.github.com>
src/mods/foveated/StereoEmulator.hpp- manages 4 emulated views with projection/frustum dataViewInjector.hpp- hooks D3D12 viewport/RT calls to redirect to atlasFoveatedAtlas.hpp- double-height render target for 4-view outputVisibilityCache.hpp- mega-frustum optimization for culling resultssrc/games/ExampleUE/ExampleUEEntry.h/cppExampleUERendererModule.h/cppExampleUECameraModule.h/cppmemory/offsets.hOriginal prompt
I'll analyze the
mutars/acsvrrepository to understand the integration pattern, then provide a condensed, actionable design specification. Now I have a clear understanding of theacsvrintegration pattern. Let me create a condensed, agent-friendly specification document with the example integration folder structure.4-View Foveated ISR Pipeline - Design Specification
Requirements
Prerequisites
vrframeworkas submodule/dependencyFolder Structure for Game Integration
Architecture (Flat)
Core Components
1. StereoEmulator
Manages 4 emulated views with projection/frustum data.
2. ViewInjector
Hooks D3D12 viewport/RT calls to redirect to atlas.
3. FoveatedAtlas
Double-height render target for 4-view output.