Skip to content

Commit

Permalink
Merge pull request #8929 from vkrushelnitskyi/DynamoAlias_perfomanceI…
Browse files Browse the repository at this point in the history
…ssue

Tune Dynamo rendering precision
  • Loading branch information
kronz authored Jun 20, 2018
2 parents 41e2503 + d8b4947 commit ec10f93
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions src/DynamoCoreWpf/ViewModels/RenderPackageFactoryViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@ public int MaxTessellationDivisions
set
{
if (factory.TessellationParameters.MaxTessellationDivisions == value) return;

factory.TessellationParameters.MaxTessellationDivisions = value;
if (value >= 8 && value <= 12)
factory.TessellationParameters.Tolerance = 0;
else
factory.TessellationParameters.Tolerance = -1;

RaisePropertyChanged("MaxTessellationDivisions");
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/DynamoCoreWpf/Views/Core/DynamoView.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -688,7 +688,7 @@
<TextBlock Text="{x:Static p:Resources.DynamoViewSettingMenuLowRenderPrecision}"
Margin="0,0,10,0"></TextBlock>
<Slider Width="100"
Minimum="12"
Minimum="8"
Maximum="512"
Value="{Binding Path=RenderPackageFactoryViewModel.MaxTessellationDivisions, Mode=TwoWay}"></Slider>
<TextBlock Text="{x:Static p:Resources.DynamoViewSettingMenuHighRenderPrecision}"
Expand Down

0 comments on commit ec10f93

Please sign in to comment.