Introduction
This section outlines possible reasons why some CAD documents rendered differently than expected.
My CAD drawing makes PrizmDoc unresponsive
NOTE: We recommend using Hybrid Viewing because the PDF format requires much less resources for displaying in the browser than the SVG format used in the viewer. It further saves resources by not converting the document to SVG on the server.
Another option for viewing complex documents is using the raster view option, alwaysUseRaster
. This can be done with the following steps:
-
Set the server-side central configuration option:
viewing.sessionConstraints.render.alwaysUseRaster.allowedValues: [false,true]
NOTE: Setting it to [true] rejects client requests which don't set alwaysUseRaster to true.
Skip this step if you are using PrizmDoc Cloud; it already has this option set to allow raster viewing.
-
In your client, specify
alwaysUseRaster
in the request body when creating a viewing session with POST /ViewingSession API. For example, in the hello-prizmdoc-viewer-with-nodejs-and-html sample it can be specified as follows:// 1. Create a new viewing session prizmdocRes = await pas.post('/ViewingSession', { // See https://help.accusoft.com/PrizmDoc/latest/HTML/pas-viewing-sessions.html json: { source: { type: 'upload', displayName: DOCUMENT_NAME }, // Add this block to enable the alwaysUseRaster mode: render: { html5: { alwaysUseRaster: true } } } });
The downside of this option is that you won't be able to see the finest details at high zoom factors (because it will be a raster view). If the vector view is necessary, contact Accusoft to see if it is possible to improve the rendering of your files so that the resulting SVG uses less browser resources.