*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->IRIX man pages -> dmnet/dmnetregister (3d)              
Title
Content
Arch
Section
 

Contents


DMNETREGISTER(3dm)					    DMNETREGISTER(3dm)


NAME    [Toc]    [Back]

     dmNetRegisterPool,	dmNetRegisterBuffer - register memory with dmNet

SYNOPSIS    [Toc]    [Back]

     #include <dmedia/dmnet.h>

     DMstatus dmNetRegisterPool(DMnetconnection, DMbufferpool);

     DMstatus dmNetRegisterBuffer(DMnetconnection);

DESCRIPTION    [Toc]    [Back]

     dmNetRegisterPool and dmNetRegisterBuffer are the suite of	dmNet memory
     registration calls, relevant only to the receiver process.	One of these
     two calls must be made before a call to dmNetRecv is made,	or dmNetRecv
     will fail with ENOMEM.

     dmNetRegisterPool allows an application to	specify	a buffer pool from
     which dmNetRecv may allocate memory for incoming DMbuffers. The buffer
     must be returned to the pool with a call to dmBufferFree after the
     application is done with it, or dmNetRecv may fail	with ENOMEM when no
     buffers remain in the pool.

     It	is also	possible to pre-allocate buffers for dmNetRecv to use, in
     which case	dmNetRegisterBuffer must be called. dmNetRegisterBuffer	does
     not register a particular buffer, but indicates to	dmNet that the
     DMbuffer reference	passed to dmNetRecv is valid.

     Each registration call has	the effect of cancelling all previous
     registrations, i.e, only the last invocation of
     dmNetRegisterPool/dmNetRegisterBuffer will	be remembered by dmNet.

EXAMPLE    [Toc]    [Back]

     This is a contrived example to illustrate how multiple memory
     registration calls	may be made. 3 buffers are received, the first into
     pool1, and	the others into	pool2.

	      DMbuffer dmbuf[3];
	      dmNetRegisterPool(cnp, pool1);
	      dmNetRecv(cnp, &dmbuf[0]);
	      dmNetRegisterPool(cnp, pool2);
	      dmNetRecv(cnp, &dmbuf[1]);
	      dmNetRegisterBuffer(cnp);
	      dmBufferAllocate(pool2, &dmbuf[2]);
	      dmNetRecv(cnp, &dmbuf[2]);
	      dmNetRegisterPool(cnp, pool1);
	      etc.

SEE ALSO    [Toc]    [Back]

      
      
     dmNetRecv(3dm)


									PPPPaaaaggggeeee 1111
[ Back ]
 Similar pages
Name OS Title
dmnetopen IRIX open/close a dmNet connection to another process
xlate_get_reg_rule IRIX get register information
dh_installxfonts Linux register X fonts
dh_installwm Linux register a window manager
DEVICE_IDENTIFY FreeBSD identify a device, register it
auxreg OpenBSD SPARC auxiliary register
amregister IRIX register or deregister the system
xlate_expand_reg_info IRIX expand register instructions
xlate_pro_add_reg_info IRIX add register change information
tt_message_callback_add HP-UX register a callback function
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service