예제 #1
0
 public RenderState(RenderManager renderManager)
 {
     m_renderManager = renderManager;
     for(int i = 0; i < RenderManager.MAX_TEXTURES; ++i)
     {
         m_currentTexture[i] = new Stack<Texture2D>();
     }
 }
예제 #2
0
 public EffectEnumeratorNode(RenderManager renderManager)
 {
     m_renderManager = renderManager;
 }
예제 #3
0
 public CameraEnumeratorNode(RenderManager renderManager)
 {
     m_renderManager = renderManager;
 }
예제 #4
0
 public RenderManager(Game game, GraphicsDeviceManager deviceManager)
     : base(game)
 {
     _construct(game, deviceManager);
     m_current = this;
 }
예제 #5
0
        public RenderTargetEnumeratorNode(RenderManager renderManager)
        {
            m_renderManager = renderManager;

            m_subs.addNode(new CameraEnumeratorNode(m_renderManager));

            m_subs.addNode(new EffectEnumeratorNode(m_renderManager));
        }
예제 #6
0
        public RenderManagerNode(RenderManager renderManager)
        {
            m_renderManager = renderManager;

            // build the resourcetree
            m_subs.addNode(new ColorNode(m_renderManager.Game
                                        , "AmbientLighting"
                                        , m_renderManager.RenderState.SetAmbientLighting
                                        , m_renderManager.RenderState.GetAmbientLighting));
            m_subs.addNode(new ColorNode(m_renderManager.Game
                                        , "BackgroundColor"
                                        , m_renderManager.RenderState.SetClearColor
                                        , m_renderManager.RenderState.GetClearColor));
            m_subs.addNode(new ColorNode(m_renderManager.Game
                                        , "FogColor"
                                        , m_renderManager.RenderState.SetFogColor
                                        , m_renderManager.RenderState.GetFogColor));

            m_subs.addNode(new RenderTargetEnumeratorNode(m_renderManager));

            m_subs.addNode(new CameraEnumeratorNode(m_renderManager));

            m_subs.addNode(new EffectEnumeratorNode(m_renderManager));
        }
예제 #7
0
        public TestGame(int processId = 0, string window = "")
        {
            //graphics = new GraphicsDeviceManager(this);
            //graphics.PreferredDepthStencilFormat = DepthFormat.Depth24;
            //graphics.ApplyChanges();
            Content.RootDirectory = "Content";

            // Frame rate is 30 fps by default for Windows Phone.
            TargetElapsedTime = TimeSpan.FromTicks(333333);

            m_core = new Core(this);
            m_scriptExecutor = XmlScriptExecutor.GetInstance(this);
            m_scriptCompiler = new XmlScriptCompilerService(this);
            m_collisionManager = new CollisionManager(this);
            m_sceneManager = new SceneManager(this);
            m_inputManager = new InputManager(this);
            m_animationService = new AnimationService(this);
            // graphics should be inserted last, as they should be updated at the end of a frame
            //RenderManager.TargetWindow target = new RenderManager.TargetWindow();
            //target.ProcessId = processId;
            //target.ChildWndCaption = window;
            //m_renderManager = new RenderManager(this, graphics, target);
            m_renderManager = new RenderManager(this, graphics);
            #if WINDOWS
            m_netCtrl = new NetCtrlService(this);
            #endif
        }