Skip to content

Commit

Permalink
[Docs] Use XML documentation lists (#1948)
Browse files Browse the repository at this point in the history
  • Loading branch information
Fydar committed Oct 16, 2023
1 parent db628f4 commit e017fe1
Show file tree
Hide file tree
Showing 8 changed files with 65 additions and 34 deletions.
Expand Up @@ -40,8 +40,10 @@ private class ComponentTypeComparer : EqualityComparer<Type>

/// <summary>
/// Compares two component types and returns <c>true</c> if the types match, i.e.:
/// - both types are identical
/// - first type is a subclass of the second type (e.g. StartupScript is a subclass of ScriptComponent)
/// <list type="bullet">
/// <item>both types are identical</item>
/// <item>first type is a subclass of the second type (e.g. StartupScript is a subclass of ScriptComponent)</item>
/// </list>
/// </summary>
public override bool Equals([NotNull] Type x, [NotNull] Type y)
{
Expand Down
Expand Up @@ -20,10 +20,14 @@ namespace Stride.Editor.Thumbnails
{
/// <summary>
/// The base command to build stride thumbnails.
/// - It uses the underlying <see cref="ThumbnailGenerator"/> to build thumbnail via scenes.
/// - It extracts and exposes the thumbnail services from the <see cref="ThumbnailCompilerContext"/>,
/// - It defines the <see cref="CreateScene"/>, <see cref="DestroyScene"/> base functions to be overridden.
/// </summary>
/// <remarks>
/// <list type="bullet">
/// <item>It uses the underlying <see cref="ThumbnailGenerator"/> to build thumbnail via scenes.</item>
/// <item>It extracts and exposes the thumbnail services from the <see cref="ThumbnailCompilerContext"/>.</item>
/// <item>It defines the <see cref="CreateScene"/>, <see cref="DestroyScene"/> base functions to be overridden.</item>
/// </list>
/// </remarks>
public abstract class StrideThumbnailCommand<TRuntimeAsset> : ThumbnailCommand, IThumbnailCommand where TRuntimeAsset : class
{
private readonly AssetItem assetItem;
Expand Down
12 changes: 8 additions & 4 deletions sources/engine/Stride.Engine/Engine/AnimationComponent.cs
Expand Up @@ -193,11 +193,15 @@ public PlayingAnimation NewPlayingAnimation(string name)

/// <summary>
/// Returns an awaitable object that will be completed when the animation is removed from the PlayingAnimation list.
/// This happens when:
/// - RepeatMode is PlayOnce and animation reached end
/// - Animation faded out completely (due to blend to 0.0 or crossfade out)
/// - Animation was manually removed from AnimationComponent.PlayingAnimations
/// </summary>
/// <remarks>
/// This happens when:
/// <list type="bullet">
/// <item>RepeatMode is PlayOnce and animation reached end</item>
/// <item>Animation faded out completely (due to blend to 0.0 or crossfade out)</item>
/// <item>Animation was manually removed from AnimationComponent.PlayingAnimations</item>
/// </list>
/// </remarks>
/// <returns></returns>
public Task Ended(PlayingAnimation animation)
{
Expand Down
10 changes: 7 additions & 3 deletions sources/engine/Stride.Graphics/SDL/Window.cs
Expand Up @@ -577,10 +577,14 @@ public virtual void ProcessEvent(Event e)
}

/// <summary>
/// Platform specific handle for Window:
/// - On Windows: the HWND of the window
/// - On Unix: the Window ID (XID). Note that on Unix, the value is 32-bit (See X11/X.h for the typedef of XID).
/// Platform specific handle for Window.
/// </summary>
/// <remarks>
/// <list type="bullet">
/// <item>On Windows: the HWND of the window</item>
/// <item>On Unix: the Window ID (XID). Note that on Unix, the value is 32-bit (See X11/X.h for the typedef of XID).</item>
/// </list>
/// </remarks>
public IntPtr Handle { get; private set; }

/// <summary>
Expand Down
Expand Up @@ -14,8 +14,10 @@ namespace Stride.Rendering.Images
/// </summary>
/// <remarks>
/// To improve performance of this gaussian blur is using:
/// - a separable 1D horizontal and vertical blur
/// - linear filtering to reduce the number of taps
/// <list type="bullet">
/// <item>a separable 1D horizontal and vertical blur</item>
/// <item>linear filtering to reduce the number of taps</item>
/// </list>
/// </remarks>
[DataContract("GaussianBlur")]
[Display("Gaussian Blur")]
Expand Down
16 changes: 12 additions & 4 deletions sources/engine/Stride/CompilationMode.cs
Expand Up @@ -12,7 +12,9 @@ public enum CompilationMode
/// </summary>
/// <remarks>
/// Impact on compilation on other components:
/// - Shaders are compiled in debug mode with debug information.
/// <list type="bullet">
/// <item>Shaders are compiled in debug mode with debug information.</item>
/// </list>
/// </remarks>
Debug,

Expand All @@ -21,7 +23,9 @@ public enum CompilationMode
/// </summary>
/// <remarks>
/// Impact on compilation on other components:
/// - Shaders are compiled in optimization level 1 with debug information.
/// <list type="bullet">
/// <item>Shaders are compiled in optimization level 1 with debug information.</item>
/// </list>
/// </remarks>
Release,

Expand All @@ -30,7 +34,9 @@ public enum CompilationMode
/// </summary>
/// <remarks>
/// Impact on compilation on other components:
/// - Shaders are compiled in optimization level 2 with <c>no debug</c> information.
/// <list type="bullet">
/// <item>Shaders are compiled in optimization level 2 with <c>no debug</c> information.</item>
/// </list>
/// </remarks>
AppStore,

Expand All @@ -39,7 +45,9 @@ public enum CompilationMode
/// </summary>
/// <remarks>
/// Impact on compilation on other components:
/// - Shaders are compiled in debug mode with debug information.
/// <list type="bullet">
/// <item>Shaders are compiled in debug mode with debug information.</item>
/// </list>
/// </remarks>
Testing,
}
Expand Down
Expand Up @@ -21,12 +21,17 @@
namespace Stride.Core.Shaders.Convertor
{
/// <summary>
/// HLSL to GLSL conversion requires several steps:
/// - Replace input/output structure access by varying variables.
/// - Replace common types such as float4 =&gt; vec4.
/// - Change main signature.
/// - Convert return statements into GLSL out assignments.
/// A converter for transforming HLSL into GLSL.
/// </summary>
/// <remarks>
/// HLSL to GLSL conversion requires several steps:
/// <list type="bullet">
/// <item>Replace input/output structure access by varying variables.</item>
/// <item>Replace common types such as float4 =&gt; vec4.</item>
/// <item>Change main signature.</item>
/// <item>Convert return statements into GLSL out assignments.</item>
/// </list>
/// </remarks>
public class HlslToGlslConvertor : ShaderRewriter
{
// Each sampler+texture pair will map to a GLSL sampler.
Expand Down
24 changes: 13 additions & 11 deletions sources/shared/ConsoleProgram.cs
Expand Up @@ -34,19 +34,21 @@ namespace Stride
{
/// <summary>
/// Reusable, reflection based helper for parsing commandline options.
/// Greetings to Shawn Hargreaves, original code http://blogs.msdn.com/b/shawnhar/archive/2012/04/20/a-reusable-reflection-based-command-line-parser.aspx
/// This is a modified version of command line parser that adds:
/// - .NET 2.0 compatible
/// - Allow inheritance to simplify declaration
/// - Print exe banner, using AssemblyTitle and AssemblyCopyright.
/// - Better padding of options, add descriptor and value text overrides.
/// - Add support for - and / starting options.
/// - Remove usage of ":" to separate option from parsed option
/// - Add "&lt;options&gt;" to the Usage when options are defined
/// - Add Console Color handling
/// </summary>
/// <remarks>
/// This single file is intended to be directly included in the project that needs to handle command line without requiring any SharpDX assembly dependencies.
/// <para>Greetings to Shawn Hargreaves, original code http://blogs.msdn.com/b/shawnhar/archive/2012/04/20/a-reusable-reflection-based-command-line-parser.aspx</para>
/// <para>This is a modified version of command line parser that adds:</para>
/// <list type="bullet">
/// <item>.NET 2.0 compatible</item>item>
/// <item>Allow inheritance to simplify declaration</item>
/// <item>Print exe banner, using AssemblyTitle and AssemblyCopyright.</item>
/// <item>Better padding of options, add descriptor and value text overrides.</item>
/// <item>Add support for - and / starting options.</item>
/// <item>Remove usage of ":" to separate option from parsed option</item>
/// <item>Add "&lt;options&gt;" to the Usage when options are defined</item>
/// <item>Add Console Color handling</item>
/// </list>
/// <para>This single file is intended to be directly included in the project that needs to handle command line without requiring any SharpDX assembly dependencies.</para>
/// </remarks>
class ConsoleProgram
{
Expand Down

0 comments on commit e017fe1

Please sign in to comment.