Developing a Fax Application

BT_ZERO(args_strip);

args_strip.fmt = DATA_ASCII;

args_strip.resolution = RES_200H_100V; args_strip.width = WIDTH_A4; args_strip.left_margin = 5; args_strip.right_margin = 0; args_strip.line_spacing = 2; args_strip.eof_char = 0x1a; BfvFaxStripParams(lp,&args_strip);

Sets the ASCII parameters for the ASCII strip main.txt, since it differs from the default.

BT_ZERO(args_fax);

args_fax.fname = "main.txt"; args_fax.fmt = DATA_ASCII; BfvFaxSendFile(lp, &args_fax);

Sends the ASCII text body file main.txt to the driver.

BT_ZERO(args_strip); args_strip.fmt = DATA_G3; args_strip.resolution = RES_200H_100V; args_strip.width = WIDTH_A4; BfvFaxStripParams(lp,&args_strip);

Sets the G3 strip parameters for the G3 strip sig.G3.

BT_ZERO(args_fax);

args_fax.fname = "sig.g3"; args_fax.fmt = DATA_G3; BfvFaxSendFile(lp, &args_fax);

Sends the G3 signature file sig.G3 to the driver.

BT_ZERO(args_fax);

args_fax.resolution = RES_200H_100V; args_fax.width = WIDTH_A4; BfvFaxNextPageRaw(lp, &args_fax);

Sends an end-of-page command to the driver and indicates that another page (normal resolution and A4 width) follows.

BT_ZERO(args_page);

args_page.top_margin = 5; args_page.bottom_margin = 5; args_page.length = 1143; args_page.ascii_pad = 0; BfvFaxPageParams(lp,&args_page);

Sets the page parameters for this page since they differ from those of the first page.

November 2009

72

Page 72
Image 72
Dialogic 6.2 manual Sets the G3 strip parameters for the G3 strip sig.G3