Garry's Mod Wiki

Garry's Mod Wiki

  GM:RenderScreenspaceEffects()

Description

Used to render post processing effects.

This is a rendering hook which provides a 2d rendering context.

Example

Renders color modify and sobel effects to create a cartoon effect.

local tab = { ["$pp_colour_addr"] = 0, ["$pp_colour_addg"] = 0, ["$pp_colour_addb"] = 0, ["$pp_colour_brightness"] = -0.04, ["$pp_colour_contrast"] = 1.35, ["$pp_colour_colour"] = 5, ["$pp_colour_mulr"] = 0, ["$pp_colour_mulg"] = 0, ["$pp_colour_mulb"] = 0 } hook.Add("RenderScreenspaceEffects", "PostProcessingExample", function() DrawColorModify( tab ) --Draws Color Modify effect DrawSobel( 0.5 ) --Draws Sobel effect end )

This site is a community mirror of the official Garry's Mod wiki.. This site is not maintained by Facepunch Studios.

Page content is automatically updated four times a day. Edits and history are not available.

Last Parsed: Loading...