White paper: Templates in web-to-print.  Free download

Application Settings

You can configure settings of the Dynamic Image application in the AppSettings.config file:

  <!-- License key -->
  <!--<add key="GraphicsMillLicenseKey" value="YOURLICENCEKEY" />-->

  <!-- API security key. -->
  <add key="ApiSecurityKey" value="" />

  <!-- Paths to the resources. -->
  <add key="FontPath" value=".\App_Data\assets\fonts" />
  <add key="ImagePath" value=".\App_Data\assets\images" />
  <add key="TemplatePath" value=".\App_Data\assets\templates" />

  <!-- Paths to the resulting hires files. -->
  <add key="ResultHiresPath" value=".\App_Data\Results\Pdf" />
  <!-- Paths to the resulting preview files. -->
  <add key="ResultPreviewPath" value=".\App_Data\Results\Images" />

  <!-- If `true`, it stores rendering results directly in the file system as .pdf and .png files.
      If this value is `false`, then the files are stored in the internal format, and you can limit the size and expiration time for both storages of the resulting files. -->
  <add key="SaveResultsToFileSystem" value="true" />

  <!-- The expiration time for resulting hires files, in seconds. For example, 864000 is 10 days. -->
  <add key="ResultHiresExpirationTimespan" value="0" />
  <!-- The maximum size of the resulting hires files, in bytes. For example, 4294967296 is 4 GiB. -->
  <add key="ResultHiresMaxSize" value="0" />

  <!-- The expiration time for resulting preview files, in seconds. For example, 864000 is 10 days. -->
  <add key="ResultPreviewExpirationTimespan" value="0" />
  <!-- The maximum size of the resulting preview files, in bytes. For example, 4294967296 is 4 GiB. -->
  <add key="ResultPreviewMaxSize" value="0" />

  <!-- Paths to the cache. -->
  <add key="CachePath" value=".\App_Data\Cache\FileCache" />
  <add key="FontCachePath" value=".\App_Data\Cache\FontCache" />

  <!-- Enables the cache. If true, it caches every render request. -->
  <add key="EnableCache" value="true" />
  <!-- Cache expiration time, in seconds. By default, it's 10 days. -->
  <add key="CacheExpirationTimespan" value="864000" />
  <!-- The maximum size of the cache, in bytes. By default, it's 4 GiB. -->
  <add key="CacheMaxSize" value="4294967296" />

  <!-- The resize interpolation mode for preview images. -->
  <add key="PreviewResizeInterpolationMode" value="Anisotropic9" />
  <!-- Allows for uploading images in the `ImagePath` folder through the Web API. -->
  <add key="AllowUploadImages" value="true" />

  <!-- The maximum number of tasks for rendering proof images and hi-res outputs that the Dynamic Image can perform at the same time. -->
  <add key="MaxConcurrentRenderingTasks" value="12" />
  <!-- Preloads external images before the rendering. If `true`, it could speed up the rendering. -->
  <add key="PreloadImages" value="false" />
  <!-- An experimental optimization that speeds up the rendering of preview images, but may blur them. Use with caution. -->
  <add key="OptimizePreview" value="false" />

  <!-- Debugging and logging. -->
  <add key="EnableSwagger" value="false" />
  <add key="LogAllRequests" value="false" />
  <add key="EnableDebugLogs" value="false" />

These are the default values.

If you set EnableSwagger to true, then you can navigate to <your-site-url>/swagger/ui/index and explore the interactive Web API in your browser.

For the complete list of available interpolation modes, you can refer to the GraphicsMill documentation.