---
title: "RenderProof Method (Stream, Surface, RenderingConfig, Nullable(Size), Nullable())"
canonical: https://customerscanvas.com/docs/cc6/M_Aurigma_DesignAtoms_Rendering_IProductRenderer_RenderProof_5_d06a095b.htm
archived: true
applies_to:
  - product: "Customer's Canvas On-Premises"
  - product: "Design Atoms .NET"
    versions: ["6.0.0", "6.x (may differ)"]
---

**You’re viewing outdated documentation.** [View the latest Customer’s Canvas On-Premises documentation](https://customerscanvas.com/docs/on-premises/).

# RenderProof Method (Stream, Surface, RenderingConfig, Nullable(Size), Nullable())

**Applies to:** Customer's Canvas On-Premises; Design Atoms .NET 6.0.0, 6.x (may differ) · **Archived documentation**
 
Renders a [Surface](https://customerscanvas.com/docs/cc6/T_Aurigma_DesignAtoms_Model_Surface.htm.md) to a Stream.
 
**Namespace:** [Aurigma.DesignAtoms.Rendering](https://customerscanvas.com/docs/cc6/N_Aurigma_DesignAtoms_Rendering.htm.md) 
 **Assembly:** Aurigma.DesignAtoms (in Aurigma.DesignAtoms.dll)
 
## Syntax
  
```csharp
void RenderProof(Stream stream,Surface surface,RenderingConfig renderingConfig,Nullable<Size> maxSize,Nullable<ResizeMode> resizeMode
)
```
 
### Parameters
 
 - stream
     - Type: System.IO.Stream

 - surface
     - Type: [Aurigma.DesignAtoms.Model.Surface](https://customerscanvas.com/docs/cc6/T_Aurigma_DesignAtoms_Model_Surface.htm.md)
A [Surface](https://customerscanvas.com/docs/cc6/T_Aurigma_DesignAtoms_Model_Surface.htm.md) to render.

 - renderingConfig
     - Type: [Aurigma.DesignAtoms.Configuration.RenderingConfig.RenderingConfig](https://customerscanvas.com/docs/cc6/T_Aurigma_DesignAtoms_Configuration_RenderingConfig_RenderingConfig.htm.md)
Rendering properties. You can pass `null` to use the [dafault configuration](https://customerscanvas.com/docs/cc6/configuring-high-resolution-and-proof-images.htm.md).

 - maxSize
     - Type: System.Nullable&lt;Size&gt;
The width and height of the rendered proof image, in pixels. By default, proof images are 500 x 500 pixels.

 - resizeMode
     - Type: System.Nullable&lt;ResizeMode&gt;
Defines how the proof image should appear in the specified bounds. For the values, you can refer to the [ResizeMode](https://www.graphicsmill.com/docs/gm/T_Aurigma_GraphicsMill_Transforms_ResizeMode.htm) enumeration.
 
## Examples
  
```csharp
using Aurigma.GraphicsMill.Codecs;
using Aurigma.DesignAtoms.Configuration.RenderingConfig;
using Aurigma.DesignAtoms.Rendering;

// Create the output file.
using (var fileStream = File.Create("thumbnail.jpg"))
{
    // Read the default rendering config.
    var config = RenderingConfig.GetDefault();
    // Set the JPEG image format.
    config.DefaultProofRendering.FileFormat = FileFormat.Jpeg;
    // Set the new image size.
    var maxSize = new Size(300, 300);

    // Instantiate IProductRenderer and render the first product page.
    var renderer = Injector.Instance.Resolve<IProductRenderer>();
    renderer.RenderProof(fileStream, product.Surfaces.First(), config, maxSize);
}
```
 
## See Also
  
### Reference
 
- [IProductRenderer Interface](https://customerscanvas.com/docs/cc6/T_Aurigma_DesignAtoms_Rendering_IProductRenderer.htm.md)
- [RenderProof Overload](https://customerscanvas.com/docs/cc6/O_T_Aurigma_DesignAtoms_Rendering_IProductRenderer_RenderProof.htm.md)
- [Aurigma.DesignAtoms.Rendering Namespace](https://customerscanvas.com/docs/cc6/N_Aurigma_DesignAtoms_Rendering.htm.md)

### Manual
 
- [Rendering Products](https://customerscanvas.com/docs/cc6/rendering-products-in-daf.htm.md)
- [ResizeMode enumeration](https://www.graphicsmill.com/docs/gm/T_Aurigma_GraphicsMill_Transforms_ResizeMode.htm)
