From 92703af5558258da078d876b1d46e916b1065978 Mon Sep 17 00:00:00 2001 From: gdkchan Date: Wed, 1 Jan 2020 12:39:09 -0300 Subject: Address PR feedback --- Ryujinx.Graphics.Gpu/Image/AutoDeleteCache.cs | 11 ++++++++--- Ryujinx.Graphics.Gpu/Image/FormatInfo.cs | 10 ++++++++-- Ryujinx.Graphics.Gpu/Image/Pool.cs | 4 +++- Ryujinx.Graphics.Gpu/Image/ReductionFilter.cs | 4 +++- Ryujinx.Graphics.Gpu/Image/Texture.cs | 4 +++- Ryujinx.Graphics.Gpu/Image/TextureBindingInfo.cs | 4 +++- Ryujinx.Graphics.Gpu/Image/TextureBindingsManager.cs | 8 ++++---- Ryujinx.Graphics.Gpu/Image/TextureManager.cs | 4 +++- 8 files changed, 35 insertions(+), 14 deletions(-) (limited to 'Ryujinx.Graphics.Gpu/Image') diff --git a/Ryujinx.Graphics.Gpu/Image/AutoDeleteCache.cs b/Ryujinx.Graphics.Gpu/Image/AutoDeleteCache.cs index fc30d03c..d66eab93 100644 --- a/Ryujinx.Graphics.Gpu/Image/AutoDeleteCache.cs +++ b/Ryujinx.Graphics.Gpu/Image/AutoDeleteCache.cs @@ -24,9 +24,11 @@ namespace Ryujinx.Graphics.Gpu.Image /// /// Adds a new texture to the cache, even if the texture added is already on the cache. + /// + /// /// Using this method is only recommended if you know that the texture is not yet on the cache, /// otherwise it would store the same texture more than once. - /// + /// /// The texture to be added to the cache public void Add(Texture texture) { @@ -48,9 +50,12 @@ namespace Ryujinx.Graphics.Gpu.Image /// /// Adds a new texture to the cache, or just moves it to the top of the list if the - /// texture is already on the cache. Moving the texture to the top of the list prevents - /// it from being deleted, as the textures on the bottom of the list are deleted when new ones are added. + /// texture is already on the cache. /// + /// + /// Moving the texture to the top of the list prevents it from being deleted, + /// as the textures on the bottom of the list are deleted when new ones are added. + /// /// The texture to be added, or moved to the top public void Lift(Texture texture) { diff --git a/Ryujinx.Graphics.Gpu/Image/FormatInfo.cs b/Ryujinx.Graphics.Gpu/Image/FormatInfo.cs index 4f73bfa8..12f3aecb 100644 --- a/Ryujinx.Graphics.Gpu/Image/FormatInfo.cs +++ b/Ryujinx.Graphics.Gpu/Image/FormatInfo.cs @@ -18,13 +18,19 @@ namespace Ryujinx.Graphics.Gpu.Image public Format Format { get; } /// - /// The block width for compressed formats. Must be 1 for non-compressed formats. + /// The block width for compressed formats. /// + /// + /// Must be 1 for non-compressed formats. + /// public int BlockWidth { get; } /// - /// The block height for compressed formats. Must be 1 for non-compressed formats. + /// The block height for compressed formats. /// + /// + /// Must be 1 for non-compressed formats. + /// public int BlockHeight { get; } /// diff --git a/Ryujinx.Graphics.Gpu/Image/Pool.cs b/Ryujinx.Graphics.Gpu/Image/Pool.cs index bb55d40e..e4cefe9c 100644 --- a/Ryujinx.Graphics.Gpu/Image/Pool.cs +++ b/Ryujinx.Graphics.Gpu/Image/Pool.cs @@ -17,8 +17,10 @@ namespace Ryujinx.Graphics.Gpu.Image /// /// The maximum ID value of resources on the pool (inclusive). - /// The maximum amount of resources on the pool is equal to this value plus one. /// + /// + /// The maximum amount of resources on the pool is equal to this value plus one. + /// public int MaximumId { get; } /// diff --git a/Ryujinx.Graphics.Gpu/Image/ReductionFilter.cs b/Ryujinx.Graphics.Gpu/Image/ReductionFilter.cs index 94b3f542..1f7d9b07 100644 --- a/Ryujinx.Graphics.Gpu/Image/ReductionFilter.cs +++ b/Ryujinx.Graphics.Gpu/Image/ReductionFilter.cs @@ -2,8 +2,10 @@ namespace Ryujinx.Graphics.Gpu.Image { /// /// Represents a filter used with texture minification linear filtering. - /// This feature is only supported on NVIDIA GPUs. /// + /// + /// This feature is only supported on NVIDIA GPUs. + /// enum ReductionFilter { Average, diff --git a/Ryujinx.Graphics.Gpu/Image/Texture.cs b/Ryujinx.Graphics.Gpu/Image/Texture.cs index 4bbefd0b..be3d622f 100644 --- a/Ryujinx.Graphics.Gpu/Image/Texture.cs +++ b/Ryujinx.Graphics.Gpu/Image/Texture.cs @@ -190,9 +190,11 @@ namespace Ryujinx.Graphics.Gpu.Image /// /// Changes the texture size. + /// + /// /// This operation may also change the size of all mipmap levels, including from the parent /// and other possible child textures, to ensure that all sizes are consistent. - /// + /// /// The new texture width /// The new texture height /// The new texture depth (for 3D textures) or layers (for layered textures) diff --git a/Ryujinx.Graphics.Gpu/Image/TextureBindingInfo.cs b/Ryujinx.Graphics.Gpu/Image/TextureBindingInfo.cs index 94225406..91a5fcf6 100644 --- a/Ryujinx.Graphics.Gpu/Image/TextureBindingInfo.cs +++ b/Ryujinx.Graphics.Gpu/Image/TextureBindingInfo.cs @@ -21,8 +21,10 @@ namespace Ryujinx.Graphics.Gpu.Image /// /// Indicates if the texture is a bindless texture. - /// For those textures, Handle is ignored. /// + /// + /// For those textures, Handle is ignored. + /// public bool IsBindless { get; } /// diff --git a/Ryujinx.Graphics.Gpu/Image/TextureBindingsManager.cs b/Ryujinx.Graphics.Gpu/Image/TextureBindingsManager.cs index 4d50c46e..984d45a9 100644 --- a/Ryujinx.Graphics.Gpu/Image/TextureBindingsManager.cs +++ b/Ryujinx.Graphics.Gpu/Image/TextureBindingsManager.cs @@ -52,7 +52,7 @@ namespace Ryujinx.Graphics.Gpu.Image _texturePoolCache = texturePoolCache; _isCompute = isCompute; - int stages = isCompute ? 1 : Constants.TotalShaderStages; + int stages = isCompute ? 1 : Constants.ShaderStages; _textureBindings = new TextureBindingInfo[stages][]; _imageBindings = new TextureBindingInfo[stages][]; @@ -135,7 +135,7 @@ namespace Ryujinx.Graphics.Gpu.Image /// /// Ensures that the bindings are visible to the host GPU. - /// This actually performs the binding using the host graphics API. + /// Note: this actually performs the binding using the host graphics API. /// public void CommitBindings() { @@ -164,7 +164,7 @@ namespace Ryujinx.Graphics.Gpu.Image /// /// Ensures that the texture bindings are visible to the host GPU. - /// This actually performs the binding using the host graphics API. + /// Note: this actually performs the binding using the host graphics API. /// /// The current texture pool /// The shader stage using the textures to be bound @@ -242,7 +242,7 @@ namespace Ryujinx.Graphics.Gpu.Image /// /// Ensures that the image bindings are visible to the host GPU. - /// This actually performs the binding using the host graphics API. + /// Note: this actually performs the binding using the host graphics API. /// /// The current texture pool /// The shader stage using the textures to be bound diff --git a/Ryujinx.Graphics.Gpu/Image/TextureManager.cs b/Ryujinx.Graphics.Gpu/Image/TextureManager.cs index e0a8908a..387e908d 100644 --- a/Ryujinx.Graphics.Gpu/Image/TextureManager.cs +++ b/Ryujinx.Graphics.Gpu/Image/TextureManager.cs @@ -753,9 +753,11 @@ namespace Ryujinx.Graphics.Gpu.Image /// /// Removes a texture from the cache. + /// + /// /// This only removes the texture from the internal list, not from the auto-deletion cache. /// It may still have live references after the removal. - /// + /// /// The texture to be removed public void RemoveTextureFromCache(Texture texture) { -- cgit v1.2.3