Skip to content

Commit

Permalink
PopcornFX Plugin v2.19.3
Browse files Browse the repository at this point in the history
  • Loading branch information
PopcornFX Bot committed May 16, 2024
1 parent ac6ae3a commit 93c7350
Show file tree
Hide file tree
Showing 11 changed files with 43 additions and 12 deletions.
4 changes: 2 additions & 2 deletions Content/Materials/MFunc_PK_DiffuseRemap.uasset
Git LFS file not shown
4 changes: 2 additions & 2 deletions Content/Materials/MFunc_PK_RemapAlpha.uasset
Git LFS file not shown
2 changes: 1 addition & 1 deletion Download_SDK_Desktop.bat
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ setlocal

bitsadmin /reset
bitsadmin /create third_party_download_desktop
bitsadmin /addfile third_party_download_desktop https://downloads.popcornfx.com/Plugins/UE4/UnrealEngine_PopcornFXPlugin_2.19.2_Win64_Linux64_Mac64.7z "%~dp0\_PopcornFX_Runtime_SDK_Desktop.7z"
bitsadmin /addfile third_party_download_desktop https://downloads.popcornfx.com/Plugins/UE4/UnrealEngine_PopcornFXPlugin_2.19.3_Win64_Linux64_Mac64.7z "%~dp0\_PopcornFX_Runtime_SDK_Desktop.7z"
bitsadmin /setpriority third_party_download_desktop "FOREGROUND"
bitsadmin /resume third_party_download_desktop

Expand Down
2 changes: 1 addition & 1 deletion Download_SDK_Mobile.bat
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ setlocal

bitsadmin /reset
bitsadmin /create third_party_download_mobile
bitsadmin /addfile third_party_download_mobile https://downloads.popcornfx.com/Plugins/UE4/UnrealEngine_PopcornFXPlugin_2.19.2_iOS_Android.7z "%~dp0\_PopcornFX_Runtime_SDK_Mobile.7z"
bitsadmin /addfile third_party_download_mobile https://downloads.popcornfx.com/Plugins/UE4/UnrealEngine_PopcornFXPlugin_2.19.3_iOS_Android.7z "%~dp0\_PopcornFX_Runtime_SDK_Mobile.7z"
bitsadmin /setpriority third_party_download_mobile "FOREGROUND"
bitsadmin /resume third_party_download_mobile

Expand Down
4 changes: 2 additions & 2 deletions PopcornFX.uplugin
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"FileVersion": 3,
"Version": 21902,
"VersionName": "2.19.2",
"Version": 21903,
"VersionName": "2.19.3",
"FriendlyName": "PopcornFX",
"Description": "PopcornFX Realtime Particle Solution integration into Unreal Engine",
"Category": "PopcornFX",
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Unreal Engine PopcornFX Plugin

Integrates the **PopcornFX Runtime SDK** into **Unreal Engine 5** as a Plugin.
* **Version:** `v2.19.2`
* **Version:** `v2.19.3`
* **Unreal Engine:** `5.1`, `5.2` and `5.3`
* **Supported platforms:** `Windows`, `MacOS`, `Linux`, `iOS`, `Android`, `PS4`, `PS5`, `XboxOne`, `Xbox Series`, `Switch`

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -638,7 +638,11 @@ namespace
if (!PK_VERIFY(batch->RawMesh() != null))
return null;

PopcornFX::CShapeDescriptor_Mesh *shapeDesc = PK_NEW(PopcornFX::CShapeDescriptor_Mesh(batch->RawMesh()));
PK_ASSERT(self->Scale.GetMin() >= 0.0f);
const FVector3f safeMeshScale = FVector3f(self->Scale);
const CFloat3 scale = ToPk(safeMeshScale);

PopcornFX::CShapeDescriptor_Mesh *shapeDesc = PK_NEW(PopcornFX::CShapeDescriptor_Mesh(batch->RawMesh(), scale));

_RebuildSamplingStructs(self, shapeDesc);

Expand All @@ -651,6 +655,12 @@ namespace
{
const UPopcornFXAttributeSamplerShape *self = params.self;
PopcornFX::CShapeDescriptor_Mesh *shapeDesc = static_cast<PopcornFX::CShapeDescriptor_Mesh*>(params.shape);

PK_ASSERT(self->Scale.GetMin() >= 0.0f);
const FVector3f safeScale = FVector3f(self->Scale);
const CFloat3 scale = ToPk(safeScale);

shapeDesc->SetScale(scale);

_RebuildSamplingStructs(self, shapeDesc);
}
Expand Down Expand Up @@ -779,6 +789,7 @@ UPopcornFXAttributeSamplerShape::UPopcornFXAttributeSamplerShape(const FObjectIn
ShapeType = EPopcornFXAttribSamplerShapeType::Sphere;
BoxDimension = FVector(100.f);
Radius = 100.f;
Scale = FVector::OneVector;
InnerRadius = 0.f;
Height = 100.f;
StaticMesh = null;
Expand Down Expand Up @@ -849,6 +860,14 @@ void UPopcornFXAttributeSamplerShape::SetHeight(float height)

//----------------------------------------------------------------------------

void UPopcornFXAttributeSamplerShape::SetScale(FVector scale)
{
Scale = scale;
UpdateShapeProperties();
}

//----------------------------------------------------------------------------

PopcornFX::CMeshSurfaceSamplerStructuresRandom *UPopcornFXAttributeSamplerShape::SamplerSurface() const
{
return &m_Data->m_SamplerSurface;
Expand Down Expand Up @@ -908,6 +927,7 @@ void UPopcornFXAttributeSamplerShape::PostEditChangeProperty(FPropertyChangedEve
propertyName == TEXT("Radius") ||
propertyName == TEXT("InnerRadius") ||
propertyName == TEXT("Height") ||
propertyName == TEXT("Scale") ||
#if 0 // To re-enable when shape collections are supported by PopcornFX v2
propertyName == TEXT("CollectionSamplingHeuristic") ||
propertyName == TEXT("CollectionUseShapeWeights") ||
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ void FPopcornFXDetailsAttributeSamplerShape::CustomizeDetails(IDetailLayoutBuild
detailLayout.HideProperty("StaticMesh");
detailLayout.HideProperty("StaticMeshSubIndex");
detailLayout.HideProperty("Shapes");
detailLayout.HideProperty("Scale");
#if 0 // To re-enable when shape collections are supported by PopcornFX v2
detailLayout.HideProperty("CollectionSamplingHeuristic");
detailLayout.HideProperty("CollectionUseShapeWeights");
Expand All @@ -82,6 +83,7 @@ void FPopcornFXDetailsAttributeSamplerShape::CustomizeDetails(IDetailLayoutBuild
detailLayout.HideProperty("StaticMesh");
detailLayout.HideProperty("StaticMeshSubIndex");
detailLayout.HideProperty("Shapes");
detailLayout.HideProperty("Scale");
#if 0 // To re-enable when shape collections are supported by PopcornFX v2
detailLayout.HideProperty("CollectionSamplingHeuristic");
detailLayout.HideProperty("CollectionUseShapeWeights");
Expand All @@ -108,6 +110,7 @@ void FPopcornFXDetailsAttributeSamplerShape::CustomizeDetails(IDetailLayoutBuild
detailLayout.HideProperty("StaticMesh");
detailLayout.HideProperty("StaticMeshSubIndex");
detailLayout.HideProperty("Shapes");
detailLayout.HideProperty("Scale");
#if 0 // To re-enable when shape collections are supported by PopcornFX v2
detailLayout.HideProperty("CollectionSamplingHeuristic");
detailLayout.HideProperty("CollectionUseShapeWeights");
Expand All @@ -121,6 +124,7 @@ void FPopcornFXDetailsAttributeSamplerShape::CustomizeDetails(IDetailLayoutBuild
detailLayout.HideProperty("StaticMesh");
detailLayout.HideProperty("StaticMeshSubIndex");
detailLayout.HideProperty("Shapes");
detailLayout.HideProperty("Scale");
#if 0 // To re-enable when shape collections are supported by PopcornFX v2
detailLayout.HideProperty("CollectionSamplingHeuristic");
detailLayout.HideProperty("CollectionUseShapeWeights");
Expand All @@ -136,6 +140,7 @@ void FPopcornFXDetailsAttributeSamplerShape::CustomizeDetails(IDetailLayoutBuild
detailLayout.HideProperty("InnerRadius");
detailLayout.HideProperty("Height");
detailLayout.HideProperty("StaticMesh");
detailLayout.HideProperty("Scale");
detailLayout.HideProperty("StaticMeshSubIndex");
detailLayout.HideProperty("ShapeSamplingMode");
detailLayout.HideProperty("DensityColorChannel");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ FText FPopcornFXCustomizationSubRendererMaterial::OnGetThumbnailToolTip(int32 th
check(thumbId >= 0 && thumbId < PK_ARRAY_COUNT(m_Thumbs));
if (!m_Thumbs[thumbId].m_Pty->IsValidHandle())
return FText::FromString(TEXT("Invalid"));
UObject *obj;
UObject *obj = null;
m_Thumbs[thumbId].m_Pty->GetValue(obj);
if (obj == null)
return FText::FromString(TEXT("null"));
Expand Down
6 changes: 6 additions & 0 deletions Source/PopcornFX/Public/PopcornFXAttributeSamplerShape.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ class POPCORNFX_API UPopcornFXAttributeSamplerShape : public UPopcornFXAttribute

UFUNCTION(Category = "PopcornFX AttributeSampler", BlueprintCallable)
void SetHeight(float height);

UFUNCTION(Category = "PopcornFX AttributeSampler", BlueprintCallable)
void SetScale(FVector scale);
public:
UPROPERTY(Category="PopcornFX AttributeSampler", EditAnywhere)
TEnumAsByte<EPopcornFXAttribSamplerShapeType::Type> ShapeType;
Expand All @@ -75,6 +78,9 @@ class POPCORNFX_API UPopcornFXAttributeSamplerShape : public UPopcornFXAttribute
UPROPERTY(Category="PopcornFX AttributeSampler", EditAnywhere, BlueprintReadOnly, meta=(ClampMin = "0.0", UIMin = "0.0"))
float Height;

UPROPERTY(Category="PopcornFX AttributeSampler", EditAnywhere, BlueprintReadOnly, meta=(ClampMin = "0.0", UIMin = "0.0"))
FVector Scale;

/** Distribute sampling by the given CollectionSamplingHeuristic of sub-Shapes */
UPROPERTY(Category="PopcornFX AttributeSampler", EditAnywhere)
TEnumAsByte<EPopcornFXShapeCollectionSamplingHeuristic::Type> CollectionSamplingHeuristic;
Expand Down
2 changes: 1 addition & 1 deletion Source/PopcornFX/Public/PopcornFXVersionGenerated.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@

#define POPCORNFX_PLUGIN_VERSION_MAJOR 2
#define POPCORNFX_PLUGIN_VERSION_MINOR 19
#define POPCORNFX_PLUGIN_VERSION_PATCH 2
#define POPCORNFX_PLUGIN_VERSION_PATCH 3
#define POPCORNFX_PLUGIN_VERSION_TAG ""

0 comments on commit 93c7350

Please sign in to comment.