Common IStereoRenderTargetManager implementation that can be used by HMD implementations in order to get default implementations for most methods. 更多...
#include <XRRenderTargetManager.h>
类 FXRRenderTargetManager 继承关系图:Public 成员函数 | |
| virtual void | CalculateRenderTargetSize (const class FViewport &Viewport, uint32 &InOutSizeX, uint32 &InOutSizeY) override |
| Calculates dimensions of the render target texture for direct rendering of distortion. 更多... | |
| virtual bool | NeedReAllocateViewportRenderTarget (const class FViewport &Viewport) override |
| Returns true, if render target texture must be re-calculated. | |
| virtual void | UpdateViewport (bool bUseSeparateRenderTarget, const class FViewport &Viewport, class SViewport *ViewportWidget=nullptr) override |
| Updates viewport for direct rendering of distortion. 更多... | |
Public 成员函数 继承自 IStereoRenderTargetManager | |
| virtual bool | AllocateDepthTexture (uint32 Index, uint32 SizeX, uint32 SizeY, uint8 Format, uint32 NumMips, ETextureCreateFlags Flags, ETextureCreateFlags TargetableTextureFlags, FTexture2DRHIRef &OutTargetableTexture, FTexture2DRHIRef &OutShaderResourceTexture, uint32 NumSamples=1) |
| Allocates a depth texture. 更多... | |
| virtual bool | AllocateFoveationTexture (uint32 Index, uint32 RenderSizeX, uint32 RenderSizeY, uint8 Format, uint32 NumMips, ETextureCreateFlags Flags, ETextureCreateFlags TargetableTextureFlags, FTexture2DRHIRef &OutTexture, FIntPoint &OutTextureSize) |
| Allocates a foveation texture. 更多... | |
| virtual bool | AllocateRenderTargetTexture (uint32 Index, uint32 SizeX, uint32 SizeY, uint8 Format, uint32 NumMips, ETextureCreateFlags Flags, ETextureCreateFlags TargetableTextureFlags, FTexture2DRHIRef &OutTargetableTexture, FTexture2DRHIRef &OutShaderResourceTexture, uint32 NumSamples=1) |
| Allocates a render target texture. 更多... | |
| virtual void | CalculateRenderTargetSize (const class FViewport &Viewport, uint32 &InOutSizeX, uint32 &InOutSizeY)=0 |
| Calculates dimensions of the render target texture for direct rendering of distortion. | |
| virtual uint32 | GetNumberOfBufferedFrames () const |
| Returns number of required buffered frames. | |
| virtual bool | NeedReAllocateDepthTexture (const TRefCountPtr< struct IPooledRenderTarget > &DepthTarget) |
| Returns true, if render target texture must be re-calculated. | |
| virtual bool | NeedReAllocateFoveationTexture (const TRefCountPtr< struct IPooledRenderTarget > &FoveationTarget) |
| Returns true, if foveation texture must be re-calculated. | |
| virtual bool | NeedReAllocateViewportRenderTarget (const class FViewport &Viewport)=0 |
| Returns true, if render target texture must be re-calculated. | |
| virtual bool | ShouldUseSeparateRenderTarget () const =0 |
| Whether a separate render target should be used or not. 更多... | |
| virtual void | UpdateViewport (bool bUseSeparateRenderTarget, const class FViewport &Viewport, class SViewport *ViewportWidget=nullptr)=0 |
| Updates viewport for direct rendering of distortion. 更多... | |
Protected 成员函数 | |
| virtual class FXRRenderBridge * | GetActiveRenderBridge_GameThread (bool bUseSeparateRenderTarget) |
| Return the current render bridge for use by the current viewport. 更多... | |
| virtual void | UpdateViewportRHIBridge (bool bUseSeparateRenderTarget, const class FViewport &Viewport, FRHIViewport *const ViewportRHI) |
| Optional method for custom present specific actions called at the end of UpdateViewport. 更多... | |
| virtual void | UpdateViewportWidget (bool bUseSeparateRenderTarget, const class FViewport &Viewport, class SViewport *ViewportWidget) |
| Optional method called when the ViewportWidget is not null | |
Common IStereoRenderTargetManager implementation that can be used by HMD implementations in order to get default implementations for most methods.
|
overridevirtual |
Calculates dimensions of the render target texture for direct rendering of distortion.
This implementation calculates the size based on the current value of vr.pixeldensity.
|
inlineprotectedvirtual |
Return the current render bridge for use by the current viewport.
Override this method if your device implements a custom FXRRenderBridge. Should only return non-null if the render bridge is initialized and should be used for the current frame
|
overridevirtual |
Updates viewport for direct rendering of distortion.
Should be called on a game thread.
| bUseSeparateRenderTarget | Set to true if a separate render target will be used. Can potentiallt be true even if ShouldUseSeparateRenderTarget() returned false earlier. |
| Viewport | The Viewport instance calling this method. |
| ViewportWidget | (optional) The Viewport widget containing the view. Can be used to access SWindow object. |
|
protectedvirtual |
Optional method for custom present specific actions called at the end of UpdateViewport.
The default implementation will invoke UpdateViewport on the result of GetRenderBridge_GameThread if it returns non-null.
Most implementations don't need to override this method and override GetActiveRenderBridge_GameThread instead.