Xojo Conferences
MBSOct2019CologneDE

DynaPDF Manual - Page 208

Previous Page 207   Index   Next Page 209

Function Reference
Page 208 of 770
Create3DAnnot
Syntax:
SI32 pdfCreate3DAnnot(
const PPDF* IPDF,
// Instance pointer
double PosX,
// X-Coordinate of the annotation
double PosY,
// Y-Coordinate of the annotation
double Width,
// Width of the annotation
double Height,
// Height of the Annotation
const char* Author,
// Optional author
const char* Name,
// Optional annotation name
const char* U3DFile, // Required U3D or PRC file
const char* Image)
// Optional image to display the closed annotation
The function creates a 3D annotation from a U3D or PRC file. The image is used to create the default
appearance of the annotation; it is shown when the annotation is deactivated or when viewing the
file with a viewer that does not support 3D annotations. If no image file is provided the background
is filled with the current field background color (see SetFieldBackColor()). Note that the default
background color is transparent, that means no background will be drawn if the color was not
changed beforehand.
The annotation’s name can be used to access the annotation from a JavaScript or JavaScript action.
The name must be unique if defined. Make sure that no other annotation exists with the same name.
Note that DynaPDF performs no duplicate check during creation of the annotation.
A 3D annotation requires usually at least a default view that defines the rendering mode and
lighting scheme to get suitable results (see Create3DView()). Without a view the viewer application
uses default settings to display the annotation.
Remarks:
This function is implemented in an Ansi and Unicode compatible version.
Return values:
If the function succeeds the return value is the annotation handle, a value greater or equal zero. If the
function fails the return value is a negative error code.
 

Previous topic: CopyChoiceValues

Next topic: Create3DBackground, Create3DGotoViewAction