pre-usd texture format + remove header for now

This commit is contained in:
Asval 2026-07-04 00:36:19 +02:00
parent ee22243e3d
commit 924b52c544
6 changed files with 18 additions and 53 deletions

@ -1 +1 @@
Subproject commit 7d9115c2d6eb464c641efb6c2c41efcb0260673d
Subproject commit 2b00fcf9de27eb4047c8fb41aa509940e43a8475

View File

@ -575,6 +575,7 @@
</Style>
</ListBox.Style>
</ListBox>
<!-- once we need sorting, convert this to a listview (see search window) and add the header back (customize the template to re-add GridViewHeaderRowPresenter) -->
<ListBox x:Name="AssetsListExplorer"
ItemsSource="{Binding SelectedItem.CombinedEntries, ElementName=AssetsFolderName, IsAsync=True}"
Background="{DynamicResource {x:Static adonisUi:Brushes.Layer3BackgroundBrush}}"

View File

@ -60,8 +60,14 @@ public class ExportOptionsViewModel : ViewModel
if (value == EMeshFormat.USD)
{
_preUsdTextureFormat = SelectedTextureFormat;
SelectedTextureFormat = ETextureFormat.Png;
}
else if (_preUsdTextureFormat.HasValue)
{
SelectedTextureFormat = _preUsdTextureFormat.Value;
_preUsdTextureFormat = null;
}
}
}
@ -128,7 +134,10 @@ public class ExportOptionsViewModel : ViewModel
get;
set => SetProperty(ref field, value);
}
private ETextureFormat? _preUsdTextureFormat;
public bool TextureFormatsEnabled => SelectedMeshFormat != EMeshFormat.USD;
public bool ExportHdrTexturesAsHdr
{
get;

View File

@ -186,53 +186,11 @@
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ListBox}">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="28" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<Border Grid.Row="0"
Background="{DynamicResource {x:Static adonisUi:Brushes.Layer2BackgroundBrush}}"
BorderBrush="{DynamicResource {x:Static adonisUi:Brushes.Layer0BorderBrush}}"
BorderThickness="0,0,0,1">
<Grid Margin="8 0 24 0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="{StaticResource ExplorerNameColumn}" />
<ColumnDefinition Width="{StaticResource ExplorerTypeColumn}" />
<ColumnDefinition Width="{StaticResource ExplorerDetailsColumn}" />
</Grid.ColumnDefinitions>
<TextBlock Grid.Column="0"
Text="Name"
VerticalAlignment="Center"
FontSize="11"
FontWeight="Bold"
Foreground="{DynamicResource {x:Static adonisUi:Brushes.DisabledForegroundBrush}}" />
<TextBlock Grid.Column="1"
Text="Type"
VerticalAlignment="Center"
FontSize="11"
FontWeight="Bold"
Foreground="{DynamicResource {x:Static adonisUi:Brushes.DisabledForegroundBrush}}" />
<TextBlock Grid.Column="3"
Text="Details"
VerticalAlignment="Center"
HorizontalAlignment="Right"
FontSize="11"
FontWeight="Bold"
Foreground="{DynamicResource {x:Static adonisUi:Brushes.DisabledForegroundBrush}}" />
</Grid>
</Border>
<Border Grid.Row="1"
Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}">
<ScrollViewer Focusable="False"
VerticalScrollBarVisibility="{TemplateBinding ScrollViewer.VerticalScrollBarVisibility}"
HorizontalScrollBarVisibility="{TemplateBinding ScrollViewer.HorizontalScrollBarVisibility}">
<ItemsPresenter />
</ScrollViewer>
</Border>
</Grid>
<ScrollViewer Focusable="False"
VerticalScrollBarVisibility="{TemplateBinding ScrollViewer.VerticalScrollBarVisibility}"
HorizontalScrollBarVisibility="{TemplateBinding ScrollViewer.HorizontalScrollBarVisibility}">
<ItemsPresenter />
</ScrollViewer>
</ControlTemplate>
</Setter.Value>
</Setter>

View File

@ -353,7 +353,7 @@ public class Renderer : IDisposable
return;
}
if (!original.TryConvert(out var mesh, naniteFormat))
if (!original.TryConvert(out var mesh, EMeshQuality.Highest, naniteFormat))
return;
Options.Models[guid] = new StaticModel(original, mesh);
@ -597,7 +597,7 @@ public class Renderer : IDisposable
if (bSpline && model is SplineModel splineModel)
splineModel.AddComponent((USplineMeshComponent)staticMeshComp);
}
else if (m.TryConvert(out var mesh, UserSettings.Default.NaniteMeshExportFormat))
else if (m.TryConvert(out var mesh, EMeshQuality.Highest, UserSettings.Default.NaniteMeshExportFormat))
{
model = bSpline ? new SplineModel(m, mesh, (USplineMeshComponent)staticMeshComp, transform) : new StaticModel(m, mesh, transform);
model.IsTwoSided = actor.GetOrDefault("bMirrored", staticMeshComp.GetOrDefault("bDisallowMeshPaintPerInstance", model.IsTwoSided));

View File

@ -17,9 +17,6 @@ For installation, follow the instructions from [here](https://github.com/4sval/F
### Sponsorship:
<p>
<a href="https://www.jetbrains.com/">
<img src="https://cdn.fmodel.app/i/svg/jetbrains.svg" width="256px">
</a>
<a href="https://1password.com/">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://cdn.fmodel.app/i/svg/1password-light.svg">