Garry's Mod Wiki

Revision Difference

Structures/ViewData#516697

<cat>struct</cat> <structure> <description> {{Structure |Description=Table structure used for <page>render.RenderView</page>. Table structure used for <page>render.RenderView</page>. Unless stated otherwise, the default values for all these keys would be inherited from the engine's CViewSetup and do not have static representations. </description> |Fields={{StructureField|Vector|origin|The view's original position}}{{StructureField|Angle|angles|The view's angles}}{{StructureField|number|aspectratio|Default width divided by height}}{{StructureField|number|x|The x position of the viewport to render in}}{{StructureField|number|y|The y position of the viewport to render in}}{{StructureField|number|w|The width of the viewport to render in}}{{StructureField|number|h|The height of the viewport to render in}}{{StructureField|boolean|drawhud|Draw the HUD and call the hud painting related hooks|false}}{{StructureField|boolean|drawmonitors|Draw monitors|false}}{{StructureField|boolean|drawviewmodel|The weapon's viewmodel|true}}{{StructureField|number|viewmodelfov|The viewmodel's FOV}}{{StructureField|number|fov|The main view's FOV}}{{StructureField|boolean|ortho|Render the view orthogonal. Can also be a table with these keys: ( In which case orthogonal view is automatically set to true ) <fields>{{StructureField|Vector|origin|The view's original position</fields> </structure> {{StructureField|Angle|angles|The view's angles}}{{StructureField|number|aspectratio|Default width divided by height}}{{StructureField|number|x|The x position of the viewport to render in}}{{StructureField|number|y|The y position of the viewport to render in}}{{StructureField|number|w|The width of the viewport to render in}}{{StructureField|number|h|The height of the viewport to render in}}{{StructureField|boolean|drawhud|Draw the HUD and call the hud painting related hooks|false}}{{StructureField|boolean|drawmonitors|Draw monitors|false}}{{StructureField|boolean|drawviewmodel|The weapon's viewmodel|true}}{{StructureField|number|viewmodelfov|The viewmodel's FOV}}{{StructureField|number|fov|The main view's FOV}}{{StructureField|boolean|ortho|Render the view orthogonal. Can also be a table with these keys: ( In which case orthogonal view is automatically set to true ) * left * right * top * bottom|false }}{{StructureField|number|ortholeft|Coordinate for the left clipping plane}}{{StructureField|number|orthoright|Coordinate for the right clipping plane}}{{StructureField|number|orthotop|Coordinate for the top clipping plane}}{{StructureField|number|orthobottom|Coordinate for the bottom clipping plane}}{{StructureField|number|znear|The distance of the view's origin to the near clipping plane}}{{StructureField|number|zfar|The distance of the view's origin to the far clipping plane}}{{StructureField|number|znearviewmodel|The distance of the view's origin to the near clipping plane for the viewmodel}}{{StructureField|number|zfarviewmodel|The distance of the view's origin to the far clipping plane for the viewmodel}}{{StructureField|boolean|dopostprocess|&lt;!--Call the <page>GM:RenderScreenspaceEffects</page> hook--&gt; Currently works identically to the "bloomtone" option (it also overrides it if you set this to false).|false }}{{StructureField|boolean|bloomtone|Disables default engine bloom and pauses the "brightness changes" on HDR maps.|true}}{{StructureField|table|offcenter|This allows you to "zoom in" on a part of the screen - for example, the top-left quarter of the screen. This is similar to how [poster splits the screen](https://garry.tv/2012/02/25/poster-screenshots/) into separate renders. It's a table with 4 keys, controlling what portion of the screen to draw: * left - where the left edge starts. Natural value is 0. * right - where the right edge ends. Natural value is equal to w (the width of the viewport). * top - where the `bottom` edge starts. Natural value is 0. * bottom - where the `top` edge ends. Natural value is equal to h (the height of the viewport). Note that top and bottom are reversed. Values outside the viewport are allowed, but not recommended - instead you should increase the view FOV. }} }}