Page 1 of 1

HUD Rendering

Posted: 23 Jan 2019, 23:48
by Khonan

I'm working on some kind of HUD but as soon as I attach a noesisview to my cam, noesis fill the entire screen (and not only the controls from the xaml file). How to make the xaml "root" transparent... Where is defined the background color ? ( I could set the alpha to 0, at least :))

If someone got an idea ;)


Re: HUD Rendering

Posted: 24 Jan 2019, 09:11
by Khonan
I'll add this to my log:

It appears I was using noesistheme.xaml (for testing theming styles) and noesistheme makes the background opaque.
As soon as I removed Style or using another one (like NocturnalStyle.xaml) I get back my 3d view behind the HUD :

ResourceDictionary style = (ResourceDictionary)Noesis.GUI.LoadXaml("Assets/NoesisGUI/Samples/test/NocturnalStyle.xaml");
Noesis.GUI.LoadComponent(this, "Assets/NoesisGUI/Samples/test/MainWindow.xaml");

Let's move on.

(XAML code in unity is really great ! Thanks to the team)

Re: HUD Rendering

Posted: 24 Jan 2019, 11:03
by sfernandez
NoesisTheme makes the background opaque
I'm curious, what kind of control were you using as root of your xaml?
Because base controls like Control, ContentControl, UserControl, ItemsControl... all have a null background and shouldn't fill the screen.
And Panel classes like Grid, Canvas, DockPanel,... that are normally used as root have also a null background as default.

Re: HUD Rendering

Posted: 31 Jan 2019, 11:22
by Khonan
I was using a UserControl,

<UserControl x:Class="Atome2.MainWindow"
xmlns=" ... esentation"
xmlns:d="" xmlns:mc=" ... ility/2006" mc:Ignorable="d"
Background="#FF1A1A1D" Height="Auto" d:DesignWidth="1000" VerticalAlignment="Top">

<Grid Height="Auto" HorizontalAlignment="Stretch">


Re: HUD Rendering

Posted: 31 Jan 2019, 13:49
by sfernandez
Ok, makes sense now, you were setting the Background of the root control.