Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
system_context_size(3)		 Arcan Lua API		system_context_size(3)

NAME
       system_context_size  - Change the number	of vids	allowed	at once	in new
       contexts.

SYNOPSIS
       nil
       system_context_size( newlim )

DESCRIPTION
       There is	a low limit on the amount of video objects that	are allowed to
       be alive	in a context. Attempts to allocate beyond this limit is	a ter-
       minal state transition, as a means of allowing early resource leak  de-
       tection and as a	means of encouraging use of the	context- stack to keep
       resource	usage low.

NOTES
       1      Accepted values for newlim is 0 <	n <= 65536

       2      These changes will not effect the	currently active context, only
	      those  that gets activated when the current context is pushed or
	      when the outmost context is poped.

       3      Invalid context sizes is a terminal state	transition.

       4      The default initial context size is set to 1k, which  should  be
	      enough for everyone.

EXAMPLE
       function	system_context_size0()
	     local a, b	= current_context_usage();
	     warning("current: " .. a);
	     warning("requesting new size");
	     system_context_size(64);
	     a,	b = current_context_usage();
	     warning("current: " .. a);
	     warning("poping");
	     pop_video_context();
	     a,	b = current_context_usage();
	     warning("current: " .. a);
       end

MISUSE
       function	system_context_size0()
	     system_context_size(-10);
       end

MISUSE
       function	system_context_size1()
	     system_context_size(0);
       end

system				  April	2025		system_context_size(3)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=system_context_size&sektion=3&manpath=FreeBSD+Ports+14.3.quarterly>

home | help