Exemplo n.º 1
0
        public LightArea(ShadowmapSize shadowmapSize)
        {
            int baseSize = 2 << (int)shadowmapSize;
            LightAreaSize = new Vector2(baseSize, baseSize);
            renderTarget = new RenderImage("LightArea"+ shadowmapSize,(uint)baseSize, (uint)baseSize);

            Mask = IoCManager.Resolve<IResourceManager>().GetSprite("whitemask");
        }
Exemplo n.º 2
0
        public ShadowMapResolver(ShadowmapSize maxShadowmapSize, ShadowmapSize maxDepthBufferSize,
                                 IResourceManager resourceManager)
        {
            _resourceManager = resourceManager;

            reductionChainCount = (int) maxShadowmapSize;
            baseSize = 2 << reductionChainCount;
            depthBufferSize = 2 << (int) maxDepthBufferSize;
        }
Exemplo n.º 3
0
        public LightArea(ShadowmapSize size)
        {
            int baseSize = 2 << (int)size;

            LightAreaSize = new Vector2D(baseSize, baseSize);
            renderTarget  = new RenderImage("lightTest" + baseSize + IoCManager.Resolve <IRand>().Next(100000, 999999),
                                            baseSize, baseSize, ImageBufferFormats.BufferRGB888A8);
            Mask = IoCManager.Resolve <IResourceManager>().GetSprite("whitemask");
        }
Exemplo n.º 4
0
        public ShadowMapResolver(ShadowmapSize maxShadowmapSize, ShadowmapSize maxDepthBufferSize,
                                 IResourceManager resourceManager)
        {
            _resourceManager = resourceManager;


            reductionChainCount = (int)maxShadowmapSize;
            baseSize            = 2 << reductionChainCount;
            depthBufferSize     = 2 << (int)maxDepthBufferSize;
        }
Exemplo n.º 5
0
        public ShadowMapResolver(QuadRenderer quad, ShadowmapSize maxShadowmapSize, ShadowmapSize maxDepthBufferSize,
                                 IResourceManager resourceManager)
        {
            _resourceManager = resourceManager;
            quadRender       = quad;

            //reductionChainCount =  maxShadowmapSize;
            //baseSize = 2 << reductionChainCount;
            //depthBufferSize = 2 << maxDepthBufferSize;
        }
        public ShadowMapResolver(QuadRenderer quad, ShadowmapSize maxShadowmapSize, ShadowmapSize maxDepthBufferSize,
                                 IResourceManager resourceManager)
        {
            _resourceManager = resourceManager;
            quadRender = quad;

            //reductionChainCount =  maxShadowmapSize;
            //baseSize = 2 << reductionChainCount;
            //depthBufferSize = 2 << maxDepthBufferSize;
        }
Exemplo n.º 7
0
        public LightArea(ShadowmapSize shadowmapSize)
        {
            int baseSize = 2 << (int)shadowmapSize;

            LightAreaSize = new Vector2f(baseSize, baseSize);
            RenderTarget  = new RenderImage("LightArea" + shadowmapSize, (uint)baseSize, (uint)baseSize);


            Mask = IoCManager.Resolve <IResourceManager>().GetSprite("whitemask");
        }
Exemplo n.º 8
0
 public LightArea(ShadowmapSize shadowmapSize)
 {
     // TODO: Complete member initialization
     this.shadowmapSize = shadowmapSize;
 }
Exemplo n.º 9
0
 private LightArea GetLightArea(ShadowmapSize size)
 {
     switch (size)
     {
         case ShadowmapSize.Size128:
             return lightArea128;
         case ShadowmapSize.Size256:
             return lightArea256;
         case ShadowmapSize.Size512:
             return lightArea512;
         case ShadowmapSize.Size1024:
             return lightArea1024;
         default:
             return lightArea1024;
     }
 }