Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cycles : Remove dupli_generated and dupli_uv attributes #5719

Merged
merged 1 commit into from
Mar 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Changes.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Breaking Changes
----------------

- CyclesOptions : Removed `cycles:integrator:sampling_pattern` option. This is intended only for debugging, but is still available via a CustomOptions node.
- CyclesAttributes : Removed the `cycles:dupliGenerated` and `cycles:dupliUV` attributes.

1.4.0.0b3 (relative to 1.4.0.0b2)
=========
Expand Down
24 changes: 1 addition & 23 deletions python/GafferCyclesUI/CyclesAttributesUI.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def __visibilitySummary( plug ) :
def __renderingSummary( plug ) :

info = []
for childName in ( "useHoldout", "isShadowCatcher", "isCausticsCaster", "isCausticsReceiver", "dupliGenerated", "dupliUV", "lightGroup" ) :
for childName in ( "useHoldout", "isShadowCatcher", "isCausticsCaster", "isCausticsReceiver", "lightGroup" ) :
if plug[childName]["enabled"].getValue() :
info.append( IECore.CamelCase.toSpaced( childName ) + ( " On" if plug[childName]["value"].getValue() else " Off" ) )

Expand Down Expand Up @@ -245,28 +245,6 @@ def __shaderSummary( plug ) :

],

"attributes.dupliGenerated" : [

"description",
"""
Set a unique position offset. Accessible from a texture_coordinate
via the generated output plug and from_dupli enabled.
""",

"layout:section", "Rendering",
],

"attributes.dupliUV" : [

"description",
"""
Set a unique UV offset. Accessible from either a texture_coordinate
or uv_map node via the UV output plug and from_dupli enabled.
""",

"layout:section", "Rendering",
],

"attributes.lightGroup" : [

"description",
Expand Down
4 changes: 0 additions & 4 deletions src/GafferCycles/CyclesAttributes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,6 @@ CyclesAttributes::CyclesAttributes( const std::string &name )
attributes->addChild( new Gaffer::NameValuePlug( "cycles:volume_step_size", new IECore::FloatData( 0.0f ), false, "volumeStepSize" ) );
attributes->addChild( new Gaffer::NameValuePlug( "cycles:volume_object_space", new IECore::BoolData( true ), false, "volumeObjectSpace" ) );

// Per-object parameters
attributes->addChild( new Gaffer::NameValuePlug( "cycles:dupli_generated", new IECore::V3fData( Imath::V3f( 0.0f ) ), false, "dupliGenerated" ) );
attributes->addChild( new Gaffer::NameValuePlug( "cycles:dupli_uv", new IECore::V2fData( Imath::V2f( 0.0f ) ), false, "dupliUV" ) );

// Asset name for cryptomatte
attributes->addChild( new Gaffer::NameValuePlug( "cycles:asset_name", new IECore::StringData( "" ), false, "assetName" ) );

Expand Down
11 changes: 0 additions & 11 deletions src/GafferCycles/IECoreCyclesPreview/Renderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -840,9 +840,6 @@ IECore::InternedString g_maxLevelAttributeName( "cycles:max_level" );
IECore::InternedString g_dicingRateAttributeName( "cycles:dicing_rate" );
// Cycles Light
IECore::InternedString g_cyclesLightAttributeName( "cycles:light" );
// Dupli
IECore::InternedString g_dupliGeneratedAttributeName( "cycles:dupli_generated" );
IECore::InternedString g_dupliUVAttributeName( "cycles:dupli_uv" );
// Shader Assignment
IECore::InternedString g_cyclesSurfaceShaderAttributeName( "cycles:surface" );
IECore::InternedString g_oslSurfaceShaderAttributeName( "osl:surface" );
Expand Down Expand Up @@ -902,8 +899,6 @@ class CyclesAttributes : public IECoreScenePreview::Renderer::AttributesInterfac
m_maxLevel( 1 ),
m_dicingRate( 1.0f ),
m_color( Color3f( 1.0f ) ),
m_dupliGenerated( V3f( 0.0f ) ),
m_dupliUV( V2f( 0.0f) ),
m_volume( attributes ),
m_shaderAttributes( attributes ),
m_assetName( "" ),
Expand All @@ -926,8 +921,6 @@ class CyclesAttributes : public IECoreScenePreview::Renderer::AttributesInterfac
m_maxLevel = attributeValue<int>( g_maxLevelAttributeName, attributes, m_maxLevel );
m_dicingRate = attributeValue<float>( g_dicingRateAttributeName, attributes, m_dicingRate );
m_color = attributeValue<Color3f>( g_displayColorAttributeName, attributes, m_color );
m_dupliGenerated = attributeValue<V3f>( g_dupliGeneratedAttributeName, attributes, m_dupliGenerated );
m_dupliUV = attributeValue<V2f>( g_dupliUVAttributeName, attributes, m_dupliUV );
m_lightGroup = attributeValue<std::string>( g_lightGroupAttributeName, attributes, m_lightGroup );
m_assetName = attributeValue<std::string>( g_cryptomatteAssetAttributeName, attributes, m_assetName );
m_isCausticsCaster = attributeValue<bool>( g_isCausticsCasterAttributeName, attributes, m_isCausticsCaster );
Expand Down Expand Up @@ -1070,8 +1063,6 @@ class CyclesAttributes : public IECoreScenePreview::Renderer::AttributesInterfac
object->set_shadow_terminator_shading_offset( m_shadowTerminatorShadingOffset );
object->set_shadow_terminator_geometry_offset( m_shadowTerminatorGeometryOffset );
object->set_color( SocketAlgo::setColor( m_color ) );
object->set_dupli_generated( SocketAlgo::setVector( m_dupliGenerated ) );
object->set_dupli_uv( SocketAlgo::setVector( m_dupliUV ) );
object->set_asset_name( ccl::ustring( m_assetName.c_str() ) );
object->set_is_caustics_caster( m_isCausticsCaster );
object->set_is_caustics_receiver( m_isCausticsReceiver );
Expand Down Expand Up @@ -1307,8 +1298,6 @@ class CyclesAttributes : public IECoreScenePreview::Renderer::AttributesInterfac
int m_maxLevel;
float m_dicingRate;
Color3f m_color;
V3f m_dupliGenerated;
V2f m_dupliUV;
Volume m_volume;
ShaderAttributes m_shaderAttributes;
InternedString m_assetName;
Expand Down
Loading