/// <inheritdoc />
        public override void OnThumbnailDrawBegin(ThumbnailRequest request, ContainerControl guiRoot, GPUContext context)
        {
            _preview.CubeTexture = (CubeTexture)request.Asset;
            _preview.Parent      = guiRoot;
            _preview.SyncBackbufferSize();

            _preview.Task.OnDraw();
        }
Beispiel #2
0
        /// <inheritdoc />
        public override void OnThumbnailDrawPrepare(ThumbnailRequest request)
        {
            if (_preview == null)
            {
                _preview = new CubeTexturePreview(false);
                _preview.RenderOnlyWithWindow = false;
                _preview.Task.Enabled         = false;
                _preview.Size = new Vector2(PreviewsCache.AssetIconSize, PreviewsCache.AssetIconSize);
                _preview.SyncBackbufferSize();
            }

            // TODO: disable streaming for asset during thumbnail rendering (and restore it after)
        }
Beispiel #3
0
        /// <inheritdoc />
        public override void OnThumbnailDrawPrepare(ThumbnailRequest request)
        {
            if (_preview == null)
            {
                _preview = new CubeTexturePreview(false);
                _preview.RenderOnlyWithWindow = false;
                _preview.Task.Enabled         = false;
                _preview.PostFxVolume.Settings.Eye_Technique = EyeAdaptationTechnique.None;
                _preview.PostFxVolume.Settings.Eye_Exposure  = 0.1f;
                _preview.PostFxVolume.Settings.data.Flags4  |= 0b1001;
                _preview.Size = new Vector2(PreviewsCache.AssetIconSize, PreviewsCache.AssetIconSize);
                _preview.SyncBackbufferSize();
            }

            // TODO: disable streaming for asset during thumbnail rendering (and restore it after)
        }
        /// <inheritdoc />
        public override void OnThumbnailDrawPrepare(ThumbnailRequest request)
        {
            if (_preview == null)
            {
                _preview = new CubeTexturePreview(false);
                _preview.RenderOnlyWithWindow = false;
                _preview.Task.Enabled         = false;

                var eyeAdaptation = _preview.PostFxVolume.EyeAdaptation;
                eyeAdaptation.Mode                  = EyeAdaptationMode.None;
                eyeAdaptation.OverrideFlags        |= EyeAdaptationSettings.Override.Mode;
                _preview.PostFxVolume.EyeAdaptation = eyeAdaptation;

                _preview.Size = new Vector2(PreviewsCache.AssetIconSize, PreviewsCache.AssetIconSize);
                _preview.SyncBackbufferSize();
            }

            // TODO: disable streaming for asset during thumbnail rendering (and restore it after)
        }