Announcement

Collapse
No announcement yet.

Creating a PostProcessVolume from C++, anyone done that yet?

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

    Creating a PostProcessVolume from C++, anyone done that yet?

    Hi,

    I'm struggling to create a PostProcessVolume from C++, as I don't know how to apply the brush to the volume.
    If anyone has any examples, I would appreciate it. I've checked both the samples and the engine and this is how far I've got:

    Code:
    TSubobjectPtr<APostProcessVolume> PostProcessVolume = PCIP.CreateDefaultSubobject <APostProcessVolume> (this, TEXT("PostProcessVolume"));
    	PostProcessVolume->Settings.GrainIntensity = 1.0f;
    	PostProcessVolume->Settings.GrainJitter = 1.0f;
    	PostProcessVolume->BlendRadius = Radius;
    	PostProcessVolume->BlendWeight = 1.0f;
    	PostProcessVolume->Settings.AutoExposureMaxBrightness = 3.0f;
    	PostProcessVolume->Settings.AutoExposureMinBrightness = 0.75f;
    	PostProcessVolume->Settings.AutoExposureBias = 2.0f;
    	PostProcessVolume->BrushComponent = PCIP.CreateDefaultSubobject <UBrushComponent> (this, TEXT("BrushComponent"));
    I have no idea how to apply a sphere shape to this brush so that's where I'm stuck.

    Thanks!

    #2
    Because volumes are defined using a BSP BrushComponent, which is very hard to build from code, this isn't really something we support. You might be better off applying your postprocess changes to the cameracomponent instead.
    Lead Programmer - UE4 Animation/Physics/Audio Team - Epic Games
    Twitter: @EpicJamesG

    Comment

    Working...
    X