GraphicsDevice is null

Oct 1, 2013 at 5:46 PM
Edited Oct 1, 2013 at 5:47 PM
Hi,

i have problem with balder on windows phone 7.8, i waint to try only simple application with 1 object(box) and still have this problem.
  1. i added refereces to wp version of balder.dll and ninject.dll
  2. add Balder.Display.WP7.Display.Initialize(); into app.xaml.cs
    private void Application_Launching(object sender, LaunchingEventArgs e)
    {
        Balder.Display.WP7.Display.Initialize();
    }
    private void Application_Activated(object sender, ActivatedEventArgs e)
    {
        Balder.Display.WP7.Display.Initialize();
    }
    
  3. add those into mainpage.xaml
    xmlns:Execution="clr-namespace:Balder.Execution;assembly=Balder"
    xmlns:Lighting="clr-namespace:Balder.Lighting;assembly=Balder"
    xmlns:Geometries="clr-namespace:Balder.Objects.Geometries;assembly=Balder"
    xmlns:View="clr-namespace:Balder.View;assembly=Balder"
and finally add this
    <Execution:Game Width="480" Height="600">
        <Execution:Game.Camera>
            <View:Camera Position="-50,25,-100"/>
        </Execution:Game.Camera>
        <Lighting:OmniLight 
    Ambient="Black"
    Diffuse="Black" 
    Specular="White" 
    Position="0,0,-40"
    Strength="0.5"/>
        <Geometries:Box Dimension="10,10,10"/>
    </Execution:Game>
where i made a mistake? thanks!