Project Example Files
Back to Developer Documentation
These project examples were newly written for this documentation using public entry points verified against the existing implementation. They are not same-named classes/nodes already present after product installation, nor are they source code from non-exposed modules. This directory does not participate in the current plugin build. Copy the required examples into the same module of your own project and configure dependencies according to the C++ chapter.
C++ Files
| Example | Files | Entry points |
|---|---|---|
| External Actor motion | ProjectDmxMotionController.h, cpp | NativeLightInitialization, NativeSuperDMXTick |
| Custom material parameters | ProjectDmxMaterialController.h, cpp | NativeLightInitialization, NativeSuperDMXChanged |
| NDI texture application and Blueprint bridge | ProjectMediaReceiver.h, cpp | OnActiveTextureChanged |
There is no project Tick override or Event Tick polling approach. DMX projects use only public SuperCore headers. Media projects must verify that the official SDK's header dependencies are complete before compiling the corresponding two files; do not add the media example if NDI is not needed.
The motion example uses explicit world-space Start/End configuration and is disabled by default. The material example requires your own ProjectColor/ProjectEffect/ProjectSpeed/ProjectWidth material parameters. The media example requires a ProjectMedia texture parameter. Missing parameters do not cause a material graph to be created automatically.
Native JSON Libraries
| File | Relative channels | Description |
|---|---|---|
| Motion6Axis_12CH.json | XPos1/2, YPos3/4, ZPos5/6, XRot7/8, YRot9/10, ZRot11/12 | Names/bit depths match the existing six-axis machinery's reads |
| MaterialControl_6CH.json | Red1, Green2, Blue3, Effect4, Speed5, Width6 | Uses the verified material-parameter read pattern with a project-defined 6CH layout |
| CommandControl_2CH.json | Mode1, Trigger2 | New project mode and edge-trigger protocol |
| MultiObject_6CH.json | Three modules with Patch1/3/5, each with ZPos1/2 | New project multi-target position protocol |
Import into new data assets using the library creation steps. JSON keys have been checked against the existing parser. A JSON file is not a uasset and cannot be assigned directly to FixtureLibrary. Import overwrites Modules; read back and validate addresses afterward.
Validation Status
The files have undergone static interface and protocol checks. UHT/compilation/linking against a customer SDK, import inside UE, real network input, and packaged-build acceptance testing have not yet been completed. Record actual operations according to the AI execution procedure; do not present static review as a passed runtime test.
ProjectDmxMotionController.h
#pragma once
#include "CoreMinimal.h"
#include "SuperDmxActorBase.h"
#include "ProjectDmxMotionController.generated.h"
// Project example: continuous DMX motion through the Super event only.
UCLASS(Blueprintable)
class AProjectDmxMotionController : public ASuperDmxActorBase
{
GENERATED_BODY()
public:
AProjectDmxMotionController();
UPROPERTY(EditInstanceOnly, BlueprintReadWrite, Category="Project|Motion")
TObjectPtr<AActor> TargetActor;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Motion")
FSuperDMXAttribute PositionInput;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Motion")
FVector StartPosition = FVector::ZeroVector;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Motion")
FVector EndPosition = FVector(0, 0, 300);
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Motion")
bool bEnabled = false;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Motion")
bool bPreviewInEditor = false;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Motion")
bool bInterpolate = false;
(EditAnywhere, BlueprintReadWrite, Category=, meta=(ClampMin=))
InterpSpeed = ;
(VisibleInstanceOnly, BlueprintReadOnly, Category=)
PositionAlpha = ;
:
;
;
:
;
};
ProjectDmxMotionController.cpp
#include "ProjectDmxMotionController.h"
#include "Engine/World.h"
AProjectDmxMotionController::AProjectDmxMotionController()
{
PositionInput = MakeDmx(TEXT("ZPos"), true);
}
void AProjectDmxMotionController::NativeLightInitialization()
{
Super::NativeLightInitialization();
// StartPosition and EndPosition are explicit world-space configuration.
// Repeated construction must not capture the moved target as a new origin.
PositionAlpha = FMath::Clamp(PositionAlpha, 0.0f, 1.0f);
}
void AProjectDmxMotionController::NativeSuperDMXTick()
{
Super::NativeSuperDMXTick();
ReadDMXAndApply();
}
void AProjectDmxMotionController::ReadDMXAndApply()
{
if (!bEnabled || ControlMode == ESuperDMXControlMode::Property) return;
if (!IsValid(TargetActor.Get()) || TargetActor.Get() == this) return;
UWorld* World = GetWorld();
if (!World) return;
if (World->IsGameWorld())
{
if (!HasActorBegunPlay()) return;
}
(!bPreviewInEditor) ;
(PositionInput.DMXChannelType != EDMXChannelType::Fine) ;
int32 C = , F = , U = ;
(!(PositionInput.InstanceIndex,
PositionInput.AttribName, C, F, U)) ;
(C < || C > || F < || F > ) ;
(PositionInput, PositionAlpha);
PositionAlpha = FMath::(PositionAlpha, , );
FVector Desired = FMath::(StartPosition, EndPosition, PositionAlpha);
FVector Applied = bInterpolate
? FMath::(TargetActor->(), Desired,
World->(), InterpSpeed)
: Desired;
TargetActor->(Applied);
}
ProjectDmxMaterialController.h
#pragma once
#include "CoreMinimal.h"
#include "SuperDmxActorBase.h"
#include "ProjectDmxMaterialController.generated.h"
class AStaticMeshActor;
class UMaterialInterface;
class UMaterialInstanceDynamic;
// Project example: material initialization and DMX parameter changes.
UCLASS(Blueprintable)
class AProjectDmxMaterialController : public ASuperDmxActorBase
{
GENERATED_BODY()
public:
UPROPERTY(EditInstanceOnly, BlueprintReadWrite, Category="Project|Material")
TObjectPtr<AStaticMeshActor> TargetActor;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Material")
TObjectPtr<UMaterialInterface> BaseMaterial;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Material", meta=(ClampMin="0"))
int32 MaterialIndex = 0;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Material")
bool bEnabled = false;
protected:
virtual void NativeLightInitialization() override;
virtual void NativeSuperDMXChanged ;
:
(Transient)
TObjectPtr<UMaterialInstanceDynamic> Material;
(Transient)
TObjectPtr<UMaterialInterface> ActiveBaseMaterial;
FLinearColor Color = FLinearColor::White;
Effect = ;
Speed = ;
Width = ;
;
;
};
ProjectDmxMaterialController.cpp
#include "ProjectDmxMaterialController.h"
#include "Engine/StaticMeshActor.h"
#include "Components/StaticMeshComponent.h"
#include "Materials/MaterialInterface.h"
#include "Materials/MaterialInstanceDynamic.h"
bool AProjectDmxMaterialController::EnsureMaterial()
{
if (!bEnabled || HasAnyFlags(RF_ClassDefaultObject)) return false;
if (!IsValid(TargetActor.Get()) || !IsValid(BaseMaterial.Get())) return false;
UStaticMeshComponent* Mesh = TargetActor->GetStaticMeshComponent();
if (!IsValid(Mesh) || MaterialIndex < 0 || MaterialIndex >= Mesh->GetNumMaterials()) return false;
if (!IsValid(Material.Get()) || Material->GetOuter() != this
|| ActiveBaseMaterial.Get() != BaseMaterial.Get())
{
Material = UMaterialInstanceDynamic::Create(BaseMaterial.Get(), this);
ActiveBaseMaterial = BaseMaterial;
}
if (!IsValid(Material.())) ;
Mesh->(MaterialIndex, Material.());
;
}
{
Super::();
(()) ();
}
{
Super::();
(ControlMode == ESuperDMXControlMode::Property || !()) ;
FName Names[] = {(), (), (),
(), (), ()};
( FName Name : Names)
{
int32 C = , F = , U = ;
(!(, Name, C, F, U) || C < || C > ) ;
}
((()), (()),
(()), Color);
((()), Effect);
((()), Speed);
((()), Width);
();
}
{
(!(Material.())) ;
Material->((), Color);
Material->((), FMath::(, , Effect));
Material->((), FMath::(, , Speed));
Material->((), FMath::(, , Width));
}
ProjectMediaReceiver.h
#pragma once
#include "CoreMinimal.h"
#include "SuperMediaBase.h"
#include "ProjectMediaReceiver.generated.h"
class AStaticMeshActor;
class UMaterialInterface;
class UMaterialInstanceDynamic;
class UTexture;
// Project example. These Blueprint nodes/events are project additions.
UCLASS(Blueprintable)
class AProjectMediaReceiver : public ASuperMediaBase
{
GENERATED_BODY()
public:
UPROPERTY(EditInstanceOnly, BlueprintReadWrite, Category="Project|Media")
TObjectPtr<AStaticMeshActor> TargetActor;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Media")
TObjectPtr<UMaterialInterface> BaseMaterial;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Media", meta=(ClampMin="0"))
int32 MaterialIndex = 0;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Media")
FName TextureParameter = TEXT("ProjectMedia");
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Project|Media")
TObjectPtr<UTexture> FallbackTexture;
UFUNCTION(BlueprintPure, Category="Project|Media")
UTexture* GetProjectTexture ;
:
;
(BlueprintImplementableEvent, Category=)
;
:
(Transient)
TObjectPtr<UMaterialInstanceDynamic> Material;
(Transient)
TObjectPtr<UMaterialInterface> ActiveBaseMaterial;
};
ProjectMediaReceiver.cpp
#include "ProjectMediaReceiver.h"
#include "Engine/StaticMeshActor.h"
#include "Engine/Texture.h"
#include "Engine/World.h"
#include "Components/StaticMeshComponent.h"
#include "Materials/MaterialInterface.h"
#include "Materials/MaterialInstanceDynamic.h"
UTexture* AProjectMediaReceiver::GetProjectTexture() const
{
UTexture* Active = GetActiveTexture();
return IsValid(Active) ? Active : FallbackTexture.Get();
}
void AProjectMediaReceiver::OnActiveTextureChanged()
{
Super::OnActiveTextureChanged();
if (HasAnyFlags(RF_ClassDefaultObject)) return;
UTexture* Texture = GetProjectTexture();
if (IsValid(TargetActor.Get()) && IsValid(BaseMaterial.Get()))
{
UStaticMeshComponent* Mesh = TargetActor->GetStaticMeshComponent();
if (IsValid(Mesh) && MaterialIndex >= 0 && MaterialIndex < Mesh->GetNumMaterials())
{
if (!IsValid(Material.()) || Material->() !=
|| ActiveBaseMaterial.() != BaseMaterial.())
{
Material = UMaterialInstanceDynamic::(BaseMaterial.(), );
ActiveBaseMaterial = BaseMaterial;
}
((Material.()))
{
Mesh->(MaterialIndex, Material.());
Material->(TextureParameter, Texture);
}
}
}
(() && ()->() && ())
{
(Texture);
}
}
Motion6Axis_12CH.json
{
"FixtureName": "Project Motion 6 Axis 12CH",
"Manufacturer": "Project",
"MA2FixtureLibraryPath": "",
"GDTFFixtureLibraryPath": "",
"PowerConsumption": 0,
"Weight": 0,
"BeamAngle": 0,
"BeamIntensity": 0,
"BodySize": [
0,
0,
0
],
"Modules": [
{
"ModuleName": "Main",
"Patch": 1,
"AttributeDefs": [
MaterialControl_6CH.json
{
"FixtureName": "Project Material Control 6CH",
"Manufacturer": "Project",
"MA2FixtureLibraryPath": "",
"GDTFFixtureLibraryPath": "",
"PowerConsumption": 0,
"Weight": 0,
"BeamAngle": 0,
"BeamIntensity": 0,
"BodySize": [
0,
0,
0
],
"Modules": [
{
"ModuleName": "Main",
"Patch": 1,
"AttributeDefs": [
CommandControl_2CH.json
{
"FixtureName": "Project Command Control 2CH",
"Manufacturer": "Project",
"MA2FixtureLibraryPath": "",
"GDTFFixtureLibraryPath": "",
"PowerConsumption": 0,
"Weight": 0,
"BeamAngle": 0,
"BeamIntensity": 0,
"BodySize": [
0,
0,
0
],
"Modules": [
{
"ModuleName": "Main",
"Patch": 1,
"AttributeDefs": [
MultiObject_6CH.json
{
"FixtureName": "Project Three Object Position 6CH",
"Manufacturer": "Project",
"MA2FixtureLibraryPath": "",
"GDTFFixtureLibraryPath": "",
"PowerConsumption": 0,
"Weight": 0,
"BeamAngle": 0,
"BeamIntensity": 0,
"BodySize": [
0,
0,
0
],
"Modules": [
{
"ModuleName": "ObjectA",
"Patch": 1,
"AttributeDefs": [