UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
LocalFogVolumeComponent.h
Go to the documentation of this file.
1// Copyright Epic Games, Inc. All Rights Reserved.
2
3#pragma once
4
5#include "CoreMinimal.h"
7#include "Math/Color.h"
8#include "LocalFogVolumeComponent.generated.h"
9
11
12UCLASS(ClassGroup = Rendering, collapsecategories, hidecategories = (Object, Mobility, Activation, "Components|Activation"), editinlinenew, meta = (BlueprintSpawnableComponent), MinimalAPI)
13class ULocalFogVolumeComponent : public USceneComponent
14{
16
18
20 UPROPERTY(EditAnywhere, BlueprintReadOnly, interp, Category = "Radial Fog Distribution", meta = (DisplayName = "Radial Fog Density", UIMin = "0", UIMax = "2.0", SliderExponent = 2.0, ClampMin = 0.0))
21 float RadialFogExtinction = 1.0f;
22
24 UPROPERTY(EditAnywhere, BlueprintReadOnly, interp, Category = "Height Fog Distribution", meta = (DisplayName = "Height Fog Density", UIMin = "0", UIMax = "2.0", SliderExponent = 2.0, ClampMin = 0.0))
25 float HeightFogExtinction = 1.0f;
26
28 UPROPERTY(EditAnywhere, BlueprintReadOnly, interp, Category = "Height Fog Distribution", meta = (UIMin = "1.0", UIMax = "5000", SliderExponent = 2.0, ClampMin = 1.0))
29 float HeightFogFalloff = 1000.0f;
30
32 UPROPERTY(EditAnywhere, BlueprintReadOnly, interp, Category = "Height Fog Distribution", meta = (UIMin = "-2.0", UIMax = "2.0"))
33 float HeightFogOffset = 0.0f;
34
36 UPROPERTY(EditAnywhere, BlueprintReadOnly, interp, Category = "Shading", meta = (DisplayName = "Scattering Distribution", UIMin = "0.0", UIMax = "0.999", ClampMin = 0.0, ClampMax = 0.999))
37 float FogPhaseG = 0.2f;
38
40 UPROPERTY(EditAnywhere, BlueprintReadOnly, interp, Category = "Shading", meta = (ClampMin = 0.0, ClampMax = 1.0))
41 FLinearColor FogAlbedo = FLinearColor::White;
42
44 UPROPERTY(EditAnywhere, BlueprintReadOnly, interp, Category = "Shading", meta = (ClampMin = 0.0, ClampMax = 1.0))
45 FLinearColor FogEmissive = FLinearColor::Black;
46
48 UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = "Sorting", meta = (UIMin = "-127", UIMax = "127", ClampMin = -127, ClampMax = 127))
49 int32 FogSortPriority = 0;
50
51 UFUNCTION(BlueprintCallable, Category = "Rendering", meta = (DisplayName = "Set Radial Fog Density"))
52 ENGINE_API void SetRadialFogExtinction(float NewValue);
53 UFUNCTION(BlueprintCallable, Category = "Rendering", meta = (DisplayName = "Set Height Fog Density"))
54 ENGINE_API void SetHeightFogExtinction(float NewValue);
55 UFUNCTION(BlueprintCallable, Category = "Rendering")
56 ENGINE_API void SetHeightFogFalloff(float NewValue);
57 UFUNCTION(BlueprintCallable, Category = "Rendering")
58 ENGINE_API void SetHeightFogOffset(float NewValue);
59 UFUNCTION(BlueprintCallable, Category = "Rendering", meta = (DisplayName = "Set Scattering Distribution"))
60 ENGINE_API void SetFogPhaseG(float NewValue);
61 UFUNCTION(BlueprintCallable, Category = "Rendering")
63 UFUNCTION(BlueprintCallable, Category = "Rendering")
65
66public:
67
69 {
70 return 500.0f; // This is immutable and cannot be changed without transform data conversion of the component.
71 }
72
73 //~ Begin UObject Interface
74#if WITH_EDITOR
75 virtual bool CanEditChange(const FProperty* InProperty) const override;
76 virtual void PostEditChangeProperty(FPropertyChangedEvent& PropertyChangedEvent) override;
77#endif // WITH_EDITOR
78 //~ End UObject Interface
79
81 ENGINE_API FLocalFogVolumeSceneProxy* CreateSceneProxy();
82
83protected:
84 //~ Begin UActorComponent Interface.
85 virtual void CreateRenderState_Concurrent(FRegisterComponentContext* Context) override;
86 virtual void SendRenderTransform_Concurrent() override;
87 virtual void DestroyRenderState_Concurrent() override;
88 //~ End UActorComponent Interface.
89
91
92private:
93
95};
96
FPlatformTypes::int32 int32
A 32-bit signed integer.
Definition Platform.h:1125
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
#define UPROPERTY(...)
UObject definition macros.
Definition ObjectMacros.h:744
#define UFUNCTION(...)
Definition ObjectMacros.h:745
#define GENERATED_UCLASS_BODY(...)
Definition ObjectMacros.h:768
#define UCLASS(...)
Definition ObjectMacros.h:776
USkinnedMeshComponent float
Definition SkinnedMeshComponent.h:60
Definition LocalFogVolumeSceneProxy.h:12
Definition UnrealType.h:174
Definition ActorComponent.h:47
Definition Color.h:48
Definition UnrealType.h:6865