<?xml version="1.0" encoding="utf-8" standalone="yes"?>

<?xml-stylesheet href="./_c74_ref.xsl" type="text/xsl"?>

<!--This is an automatically generated file. DO NOT EDIT THIS FILE DIRECTLY. Rather, use the _ref.xml files found in the 'edits' folder.-->
<c74object name="jit.gl.asyncread" module="jit" category="Jitter OpenGL">
	<digest>
		Read back from an OpenGL framebuffer
	</digest>
	<description>
		Uses Pixel Buffer Objects (PBOs) to perform asynchronous reads of the OpenGL context at high framerates. The performance gain comes from using two pixel buffer objects in tandem to amortize the cost of the read operation over time without blocking other rendering commands from executing as is typically the case when naive methods are used.
	</description>
	<!--METADATA-->
	<metadatalist>
		<metadata name="author">
			Cycling '74
		</metadata>
		<metadata name="tag">
			Jitter
		</metadata>
		<metadata name="tag">
			Jitter OpenGL
		</metadata>
	</metadatalist>
	<!--INLETS-->
	<inletlist>
		<inlet id="0" type="INLET_TYPE">
			<digest>
				messages to this 3d object
			</digest>
			<description>
			</description>
		</inlet>
		<inlet id="1" type="INLET_TYPE">
			<digest>
			</digest>
			<description>
				TEXT_HERE
			</description>
		</inlet>
	</inletlist>
	<!--OUTLETS-->
	<outletlist>
		<outlet id="0" type="OUTLET_TYPE">
			<digest>
				matrix output if enabled
			</digest>
			<description>
				Outputs a Jitter matrix equivalent in size to <o>jit.window</o> object it is reading.
			</description>
		</outlet>
		<outlet id="1" type="OUTLET_TYPE">
			<digest>
				dumpout
			</digest>
			<description>
				Outputs 'get' queries.
			</description>
		</outlet>
	</outletlist>
	<objarglist>
		<objarg name="OBJARG_NAME" optional="0" type="OBJARG_TYPE">
			<digest>
				TEXT_HERE
			</digest>
			<description>
				TEXT_HERE
			</description>
		</objarg>
	</objarglist>
	<!--OB3D-->
	<OB3D />
	<!--MESSAGES-->
	<jittermethodlist>
		<jittermethod name="bang" />
		<jittermethod name="anim_grow" />
		<jittermethod name="anim_move" />
		<jittermethod name="anim_reset" />
		<jittermethod name="anim_turn" />
		<jittermethod name="draw" />
		<jittermethod name="drawimmediate" />
		<jittermethod name="drawraw" />
		<jittermethod name="exportattrs" />
		<jittermethod name="exportsummary" />
		<jittermethod name="getattributes" />
		<jittermethod name="getstate" />
		<jittermethod name="importattrs" />
		<jittermethod name="summary" />
		<jittermethod name="update_node" />
	</jittermethodlist>
	<!--ATTRIBUTES-->
	<attributelist>
		<attribute name="matrixoutput" get="1" set="1" type="int" size="1">
			<digest>
				Output a copy of the frame buffer
			</digest>
			<description>
				Output a copy of the frame buffer (OpenGL render context). The output matrix dimensions adapt to the size of the window.
			</description>
			<attributelist>
				<attribute name="label" get="1" set="1" type="symbol" size="1" value="Matrix Output" />
			</attributelist>
		</attribute>
		<attribute name="mode" get="1" set="1" type="symbol" size="1">
			<digest>
				Reading mode
			</digest>
			<description>
				Sets the reading mode. The available modes are:
				<br />
				<br />
				split: Split reads a single frame in two passes and the output is concurrent.
				<br />
				interleaved: Interleaved reads an entire frame into each internal buffer, switching buffers every other frame. In interleaved mode, the readback is delayed for one frame.
			</description>
			<attributelist>
				<attribute name="basic" get="1" set="1" type="int" size="1" value="1" />
				<attribute name="label" get="1" set="1" type="symbol" size="1" value="Mode" />
			</attributelist>
		</attribute>
		<attribute name="out_name" get="1" set="0" type="symbol" size="1">
			<digest>
				The internal frame buffer name
			</digest>
			<description>
				Returns the name of the internal frame buffer (OpenGL render context).
			</description>
		</attribute>
	</attributelist>
	<jitterattributelist>
		<jitterattribute name="anchor" />
		<jitterattribute name="anim" />
		<jitterattribute name="animmode" />
		<jitterattribute name="automatic" />
		<jitterattribute name="axes" />
		<jitterattribute name="boundcalc" />
		<jitterattribute name="bounds" />
		<jitterattribute name="dest_dim" />
		<jitterattribute name="drawbounds" />
		<jitterattribute name="drawto" />
		<jitterattribute name="enable" />
		<jitterattribute name="filterclass" />
		<jitterattribute name="inherit_all" />
		<jitterattribute name="inherit_color" />
		<jitterattribute name="inherit_depth" />
		<jitterattribute name="inherit_fog" />
		<jitterattribute name="inherit_material" />
		<jitterattribute name="inherit_poly" />
		<jitterattribute name="inherit_texture" />
		<jitterattribute name="inherit_transform" />
		<jitterattribute name="layer" />
		<jitterattribute name="material" />
		<jitterattribute name="name" />
		<jitterattribute name="position" />
		<jitterattribute name="shader" />
	</jitterattributelist>
	<!--EXAMPLE-->
	<examplelist>
		<example img="jit.gl.asyncread.png" />
	</examplelist>
	<!--SEEALSO-->
	<seealsolist>
		<seealso name="jit.gl.slab" />
		<seealso name="jit.gl.videoplane" />
	</seealsolist>
	<discussion>
		This object requires one argument: the name of a drawing context. A named drawing context is a named instance of a <o>jit.window</o>, <o>jit.pwindow</o>, or <o>jit.matrix</o> object that has an instance of the <o>jit.gl.render</o> object associated with it. Additionally it can reference the name of a <o>jit.gl.node</o> sub-context. This value may also be set via the OB3D <at>drawto</at> attribute. If no argument is present, the object is implicitly added to the first valid drawing context or sub-context found in the current patch or by searching up the patcher hierarchy.
	</discussion>
</c74object>
