<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://cegui.org/wiki/index.php?action=history&amp;feed=atom&amp;title=Performing_custom_rendering_at_the_right_time</id>
		<title>Performing custom rendering at the right time - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://cegui.org/wiki/index.php?action=history&amp;feed=atom&amp;title=Performing_custom_rendering_at_the_right_time"/>
		<link rel="alternate" type="text/html" href="http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;action=history"/>
		<updated>2026-10-01T07:59:49Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.24.1</generator>

	<entry>
		<id>http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=4168&amp;oldid=prev</id>
		<title>Capek: Robot: Cosmetic changes</title>
		<link rel="alternate" type="text/html" href="http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=4168&amp;oldid=prev"/>
				<updated>2011-03-03T23:23:34Z</updated>
		
		<summary type="html">&lt;p&gt;Robot: Cosmetic changes&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 23:23, 3 March 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{VersionBadge|0.7}} &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;[[category: Tutorials]]&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{VersionBadge|0.7}}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==What is this tutorial?==&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== What is this tutorial? ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;This is an advanced tutorial showing one of the ways in which it is possible to hook into the CEGUI rendering process to draw custom imagery using the underlying rendering API directly.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;This is an advanced tutorial showing one of the ways in which it is possible to hook into the CEGUI rendering process to draw custom imagery using the underlying rendering API directly.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The actual code that is shown here demonstrates a window that has a link to another window, and that link is indicated graphically by way of a line with two arrows. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;This was inspired by [http://www.cegui.org.uk/phpBB2/viewtopic.php?f=10&amp;amp;t=5389 this forum post], but I think that it is important to state that the technique can also be used for totally different purposes too.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The actual code that is shown here demonstrates a window that has a link to another window, and that link is indicated graphically by way of a line with two arrows. This was inspired by [http://www.cegui.org.uk/phpBB2/viewtopic.php?f=10&amp;amp;t=5389 this forum post], but I think that it is important to state that the technique can also be used for totally different purposes too.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The example code is using OpenGL, although similar things are possible with the other APIs too.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The example code is using OpenGL, although similar things are possible with the other APIs too.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Overview==&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Overview ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;It is probably worthwhile discussing why some 'advanced technique' is required in order to perform certain types of custom rendering in the first place.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;It is probably worthwhile discussing why some 'advanced technique' is required in order to perform certain types of custom rendering in the first place.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;All of the things rendered internally by CEGUI are cached and queued for later drawing. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;This means that when a window draws itself, it has not at that stage actually drawn anything, but rather it has queued some instructions for what to draw when the actual rendering is performed later on.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;All of the things rendered internally by CEGUI are cached and queued for later drawing. This means that when a window draws itself, it has not at that stage actually drawn anything, but rather it has queued some instructions for what to draw when the actual rendering is performed later on.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The biggest issue with this arises when you need custom rendering that relates to a given window, as opposed to custom rendering done before or after the CEGUI::System::renderGUI call. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;How does one know precisely when to do this custom rendering such that it is layered correctly in regards to the other CEGUI based rendering? &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;You can't render directly in response to the window events that signal a window's rendering has started or ended, because these events relate to CEGUI based rendering which can be – and is – cached.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The biggest issue with this arises when you need custom rendering that relates to a given window, as opposed to custom rendering done before or after the CEGUI::System::renderGUI call. How does one know precisely when to do this custom rendering such that it is layered correctly in regards to the other CEGUI based rendering? You can't render directly in response to the window events that signal a window's rendering has started or ended, because these events relate to CEGUI based rendering which can be – and is – cached.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;What you actually need to do is hook into the part of the process that queues things for rendering, and queue your own custom object to perform whatever rendering you need. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;The objects that get queued are based on the CEGUI::GeometryBuffer interface, the key thing to know is that the only function of that interface used during the final rendering process is the GeometryBuffer::draw function. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;This means that it's possible to implement a custom GeometryBuffer whose draw function renders directly to the active CEGUI::RenderingSurface (such as the screen / back buffer), rather than drawing some buffered geometry like the regular implementation for the CEGUI::Renderer that you use.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;What you actually need to do is hook into the part of the process that queues things for rendering, and queue your own custom object to perform whatever rendering you need. The objects that get queued are based on the CEGUI::GeometryBuffer interface, the key thing to know is that the only function of that interface used during the final rendering process is the GeometryBuffer::draw function. This means that it's possible to implement a custom GeometryBuffer whose draw function renders directly to the active CEGUI::RenderingSurface (such as the screen / back buffer), rather than drawing some buffered geometry like the regular implementation for the CEGUI::Renderer that you use.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The basic scenario is that we need a subclass of some CEGUI::Window type so we can override the Window::drawSelf function in order to queue our custom GeometryBuffer implementation. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;And, of course, a custom GeometryBuffer implementation that will perform whatever rendering we desire. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;These will now be discussed.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The basic scenario is that we need a subclass of some CEGUI::Window type so we can override the Window::drawSelf function in order to queue our custom GeometryBuffer implementation. And, of course, a custom GeometryBuffer implementation that will perform whatever rendering we desire. These will now be discussed.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Implementation==&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Implementation ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;===LinkedWindow class===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;=== LinkedWindow class ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;For this example, we will develop a LinkedWindow class that is based on the existing FrameWindow type. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;The class declaration looks like this:&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;For this example, we will develop a LinkedWindow class that is based on the existing FrameWindow type. The class declaration looks like this:&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;class LinkedWindow : public CEGUI::FrameWindow&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;class LinkedWindow : public CEGUI::FrameWindow&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 50:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 50:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The key thing included here is the drawSelf override, the rest is either boilerplate or related to the specific implementation of this demo. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;Perhaps it's worthwhile to point out the pointer to a GeometryBuffer though, since this will actually point to an instance of our custom implementation of GeometryBuffer and is initialised in the LinkedWindow constructor.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The key thing included here is the drawSelf override, the rest is either boilerplate or related to the specific implementation of this demo. Perhaps it's worthwhile to point out the pointer to a GeometryBuffer though, since this will actually point to an instance of our custom implementation of GeometryBuffer and is initialised in the LinkedWindow constructor.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;====The Window::drawSelf override====&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==== The Window::drawSelf override ====&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Since - at least for this demo - we want our custom rendering to appear between windows, we need to ensure that the RenderingSurface we use is not a surface local to the window. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;Here we see the code tests to see if the surface we are given in the context is a rendering window, and if it is, we choose to use the owner of that RenderingWindow instead. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;This is intended to avoid the AutoRenderingSurface of a FrameWindow, though in the demo we switch this off anyway. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;Depending on your own specific circumstances the code below may not be entirely robust (but it will suffice for most normal uses).&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Since - at least for this demo - we want our custom rendering to appear between windows, we need to ensure that the RenderingSurface we use is not a surface local to the window. Here we see the code tests to see if the surface we are given in the context is a rendering window, and if it is, we choose to use the owner of that RenderingWindow instead. This is intended to avoid the AutoRenderingSurface of a FrameWindow, though in the demo we switch this off anyway. Depending on your own specific circumstances the code below may not be entirely robust (but it will suffice for most normal uses).&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; RenderingSurface* surface;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; RenderingSurface* surface;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 63:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 63:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The next part is key, and is in fact, single most important line in the tutorial. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;This is where we queue our custom GeometryBuffer instance to the surface we chose above.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The next part is key, and is in fact, single most important line in the tutorial. This is where we queue our custom GeometryBuffer instance to the surface we chose above.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; surface-&amp;gt;addGeometryBuffer(ctx.queue, *d_linksGeometry);\&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; surface-&amp;gt;addGeometryBuffer(ctx.queue, *d_linksGeometry);\&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 73:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 73:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;===LinkGeometryBuffer class===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;=== LinkGeometryBuffer class ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The class declaration for LinkGeometryBuffer is as follows:&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The class declaration for LinkGeometryBuffer is as follows:&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 111:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 111:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;As you can see it's pretty much just the required functions as specified by the CEGUI::GeometryBuffer interface, along with a couple of helper functions which are specific to this demo.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;As you can see it's pretty much just the required functions as specified by the CEGUI::GeometryBuffer interface, along with a couple of helper functions which are specific to this demo.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;====The GeometryBuffer::draw override====&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==== The GeometryBuffer::draw override ====&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Below is the code for the custom drawing function. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;There is little to discuss, since this is just some very basic code and OpenGL calls. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;We basically determine the source and destination locations which will be the end points of the link line, and call a helper function that makes the GL calls to draw. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;It's probably worth highlighting the calls that save and restore the GL attributes, we do this because CEGUI will not expect its states to get messed up mid-way through rendering! &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;We don't save the model-view matrix, since this is reset by each GeometryBuffer anyway.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Below is the code for the custom drawing function. There is little to discuss, since this is just some very basic code and OpenGL calls. We basically determine the source and destination locations which will be the end points of the link line, and call a helper function that makes the GL calls to draw. It's probably worth highlighting the calls that save and restore the GL attributes, we do this because CEGUI will not expect its states to get messed up mid-way through rendering! We don't save the model-view matrix, since this is reset by each GeometryBuffer anyway.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; if (!d_owner-&amp;gt;getTarget())&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; if (!d_owner-&amp;gt;getTarget())&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 146:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 146:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;And that really is all there is to it!&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;And that really is all there is to it!&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;===Registering the new window type===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;=== Registering the new window type ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The new window type is registered using the WindowFactoryManager and the templatised WindowFactory, like so:&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The new window type is registered using the WindowFactoryManager and the templatised WindowFactory, like so:&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 161:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 161:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Conclusion==&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Conclusion ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Here we have seen how to hook into the CEGUI rendering process by queueing a custom GeometryBuffer implementation along with (or instead of) the regular GeometryBuffer queued by the Window's drawSelf function. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt; &lt;/del&gt;This allows any custom rendering to be performed at the correct time so it appears at the same layered position as a window in the output.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Here we have seen how to hook into the CEGUI rendering process by queueing a custom GeometryBuffer implementation along with (or instead of) the regular GeometryBuffer queued by the Window's drawSelf function. This allows any custom rendering to be performed at the correct time so it appears at the same layered position as a window in the output.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Example Code==&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Example Code ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;===LinkedWindow Class Declaration (LinkedWindow.h)===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;=== LinkedWindow Class Declaration (LinkedWindow.h) ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#ifndef _LINKED_WINDOW_H&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#ifndef _LINKED_WINDOW_H&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 209:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 209:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;===LinkedWindow Class Implementation (LinkedWindow.cpp)===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;=== LinkedWindow Class Implementation (LinkedWindow.cpp) ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#include &amp;lt;CEGUIRenderingWindow.h&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#include &amp;lt;CEGUIRenderingWindow.h&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 275:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 275:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;===LinkGeometryBuffer Class Declaration (LinkGeometryBuffer.h)===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;=== LinkGeometryBuffer Class Declaration (LinkGeometryBuffer.h) ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#ifndef _LINK_GEOMETRY_BUFFER_H&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#ifndef _LINK_GEOMETRY_BUFFER_H&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 331:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 331:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;===LinkGeometryBuffer Class Implementation (LinkGeometryBuffer.cpp)===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;=== LinkGeometryBuffer Class Implementation (LinkGeometryBuffer.cpp) ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#include &amp;quot;LinkGeometryBuffer.h&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#include &amp;quot;LinkGeometryBuffer.h&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 405:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 405:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;===Demo App code using GLUT (main.cpp)===&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;=== Demo App code using GLUT (main.cpp) ===&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#include &amp;lt;GL/glut.h&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#include &amp;lt;GL/glut.h&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 610:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 610:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;//----------------------------------------------------------------------------//&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;//----------------------------------------------------------------------------//&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category:Tutorials]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Capek</name></author>	</entry>

	<entry>
		<id>http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=4087&amp;oldid=prev</id>
		<title>Kulik at 16:56, 2 March 2011</title>
		<link rel="alternate" type="text/html" href="http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=4087&amp;oldid=prev"/>
				<updated>2011-03-02T16:56:30Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;a href=&quot;http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;amp;diff=4087&amp;amp;oldid=3674&quot;&gt;Show changes&lt;/a&gt;</summary>
		<author><name>Kulik</name></author>	</entry>

	<entry>
		<id>http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=3674&amp;oldid=prev</id>
		<title>Tss at 12:11, 26 February 2011</title>
		<link rel="alternate" type="text/html" href="http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=3674&amp;oldid=prev"/>
				<updated>2011-02-26T12:11:30Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 12:11, 26 February 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{VersionBadge|0.7}}&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{VersionBadge|0.7}} &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;[[category: Tutorials]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==What is this tutorial?==&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==What is this tutorial?==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;This is an advanced tutorial showing one of the ways in which it is possible to hook into the CEGUI rendering process to draw custom imagery using the underlying rendering API directly.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;This is an advanced tutorial showing one of the ways in which it is possible to hook into the CEGUI rendering process to draw custom imagery using the underlying rendering API directly.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Tss</name></author>	</entry>

	<entry>
		<id>http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=3618&amp;oldid=prev</id>
		<title>Crazyeddie: /* The GeometryBuffer::draw override */   OMG apostrophe abuse!</title>
		<link rel="alternate" type="text/html" href="http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=3618&amp;oldid=prev"/>
				<updated>2011-01-25T12:43:46Z</updated>
		
		<summary type="html">&lt;p&gt;‎&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;The GeometryBuffer::draw override: &lt;/span&gt;   OMG apostrophe abuse!&lt;/span&gt;&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 12:43, 25 January 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 102:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 102:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;====The GeometryBuffer::draw override====&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;====The GeometryBuffer::draw override====&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Below is the code for the custom drawing function.&amp;#160; There is little to discuss, since this is just some very basic code and OpenGL calls.&amp;#160; We basically determine the source and destination locations which will be the end points of the link line, and call a helper function that makes the GL calls to draw.&amp;#160; It's probably worth highlighting the calls that save and restore the GL attributes, we do this because CEGUI will not expect &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;it's &lt;/del&gt;states to get messed up mid-way through rendering!&amp;#160; We don't save the model-view matrix, since this is reset by each GeometryBuffer anyway.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Below is the code for the custom drawing function.&amp;#160; There is little to discuss, since this is just some very basic code and OpenGL calls.&amp;#160; We basically determine the source and destination locations which will be the end points of the link line, and call a helper function that makes the GL calls to draw.&amp;#160; It's probably worth highlighting the calls that save and restore the GL attributes, we do this because CEGUI will not expect &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;its &lt;/ins&gt;states to get messed up mid-way through rendering!&amp;#160; We don't save the model-view matrix, since this is reset by each GeometryBuffer anyway.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;code&amp;gt;&amp;#160; &amp;#160; if (!d_owner-&amp;gt;getTarget())&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;code&amp;gt;&amp;#160; &amp;#160; if (!d_owner-&amp;gt;getTarget())&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; &amp;#160; &amp;#160; return;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; &amp;#160; &amp;#160; return;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Crazyeddie</name></author>	</entry>

	<entry>
		<id>http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=3617&amp;oldid=prev</id>
		<title>Crazyeddie: add version badge</title>
		<link rel="alternate" type="text/html" href="http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=3617&amp;oldid=prev"/>
				<updated>2011-01-25T12:34:59Z</updated>
		
		<summary type="html">&lt;p&gt;add version badge&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 12:34, 25 January 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;{{VersionBadge|0.7}}&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==What is this tutorial?==&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==What is this tutorial?==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;This is an advanced tutorial showing one of the ways in which it is possible to hook into the CEGUI rendering process to draw custom imagery using the underlying rendering API directly.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;This is an advanced tutorial showing one of the ways in which it is possible to hook into the CEGUI rendering process to draw custom imagery using the underlying rendering API directly.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Crazyeddie</name></author>	</entry>

	<entry>
		<id>http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=3616&amp;oldid=prev</id>
		<title>Crazyeddie: New tutorial</title>
		<link rel="alternate" type="text/html" href="http://cegui.org/wiki/index.php?title=Performing_custom_rendering_at_the_right_time&amp;diff=3616&amp;oldid=prev"/>
				<updated>2011-01-25T12:18:39Z</updated>
		
		<summary type="html">&lt;p&gt;New tutorial&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==What is this tutorial?==&lt;br /&gt;
This is an advanced tutorial showing one of the ways in which it is possible to hook into the CEGUI rendering process to draw custom imagery using the underlying rendering API directly.&lt;br /&gt;
&lt;br /&gt;
The actual code that is shown here demonstrates a window that has a link to another window, and that link is indicated graphically by way of a line with two arrows.  This was inspired by [http://www.cegui.org.uk/phpBB2/viewtopic.php?f=10&amp;amp;t=5389 this forum post], but I think that it is important to state that the technique can also be used for totally different purposes too.&lt;br /&gt;
&lt;br /&gt;
The example code is using OpenGL, although similar things are possible with the other APIs too.&lt;br /&gt;
&lt;br /&gt;
==Overview==&lt;br /&gt;
It is probably worthwhile discussing why some 'advanced technique' is required in order to perform certain types of custom rendering in the first place.&lt;br /&gt;
&lt;br /&gt;
All of the things rendered internally by CEGUI are cached and queued for later drawing.  This means that when a window draws itself, it has not at that stage actually drawn anything, but rather it has queued some instructions for what to draw when the actual rendering is performed later on.&lt;br /&gt;
&lt;br /&gt;
The biggest issue with this arises when you need custom rendering that relates to a given window, as opposed to custom rendering done before or after the CEGUI::System::renderGUI call.  How does one know precisely when to do this custom rendering such that it is layered correctly in regards to the other CEGUI based rendering?  You can't render directly in response to the window events that signal a window's rendering has started or ended, because these events relate to CEGUI based rendering which can be – and is – cached.&lt;br /&gt;
&lt;br /&gt;
What you actually need to do is hook into the part of the process that queues things for rendering, and queue your own custom object to perform whatever rendering you need.  The objects that get queued are based on the CEGUI::GeometryBuffer interface, the key thing to know is that the only function of that interface used during the final rendering process is the GeometryBuffer::draw function.  This means that it's possible to implement a custom GeometryBuffer whose draw function renders directly to the active CEGUI::RenderingSurface (such as the screen / back buffer), rather than drawing some buffered geometry like the regular implementation for the CEGUI::Renderer that you use.&lt;br /&gt;
&lt;br /&gt;
The basic scenario is that we need a subclass of some CEGUI::Window type so we can override the Window::drawSelf function in order to queue our custom GeometryBuffer implementation.  And, of course, a custom GeometryBuffer implementation that will perform whatever rendering we desire.  These will now be discussed.&lt;br /&gt;
&lt;br /&gt;
==Implementation==&lt;br /&gt;
===LinkedWindow class===&lt;br /&gt;
For this example, we will develop a LinkedWindow class that is based on the existing FrameWindow type.  The class declaration looks like this:&lt;br /&gt;
&amp;lt;code&amp;gt;class LinkedWindow : public CEGUI::FrameWindow&lt;br /&gt;
{&lt;br /&gt;
public:&lt;br /&gt;
    //! 'Namespace' string used for global events on this class.&lt;br /&gt;
    static const CEGUI::String EventNamespace;&lt;br /&gt;
    //! String holding the type name of this widget.&lt;br /&gt;
    static const CEGUI::String WidgetTypeName;&lt;br /&gt;
&lt;br /&gt;
    //! set window that will be the target of our link line.&lt;br /&gt;
    void setTarget(const CEGUI::Window* target);&lt;br /&gt;
    //! return pointer that is our current link target.&lt;br /&gt;
    const CEGUI::Window* getTarget() const;&lt;br /&gt;
&lt;br /&gt;
    LinkedWindow(const CEGUI::String&amp;amp; type, const CEGUI::String&amp;amp; name);&lt;br /&gt;
    ~LinkedWindow();&lt;br /&gt;
&lt;br /&gt;
protected:&lt;br /&gt;
    // overridden from base class.&lt;br /&gt;
    void drawSelf(const CEGUI::RenderingContext&amp;amp; ctx);&lt;br /&gt;
    bool testClassName_impl(const CEGUI::String&amp;amp; class_name) const;&lt;br /&gt;
&lt;br /&gt;
    //! pointer to a GeometryBuffer that will render our link line.&lt;br /&gt;
    CEGUI::GeometryBuffer* d_linksGeometry;&lt;br /&gt;
    //! pointer to the target window of our link line.  May be zero.&lt;br /&gt;
    const CEGUI::Window* d_target;&lt;br /&gt;
};&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The key thing included here is the drawSelf override, the rest is either boilerplate or related to the specific implementation of this demo.  Perhaps it's worthwhile to point out the pointer to a GeometryBuffer though, since this will actually point to an instance of our custom implementation of GeometryBuffer and is initialised in the LinkedWindow constructor.&lt;br /&gt;
&lt;br /&gt;
====The Window::drawSelf override====&lt;br /&gt;
Since - at least for this demo - we want our custom rendering to appear between windows, we need to ensure that the RenderingSurface we use is not a surface local to the window.  Here we see the code tests to see if the surface we are given in the context is a rendering window, and if it is, we choose to use the owner of that RenderingWindow instead.  This is intended to avoid the AutoRenderingSurface of a FrameWindow, though in the demo we switch this off anyway.  Depending on your own specific circumstances the code below may not be entirely robust (but it will suffice for most normal uses).&lt;br /&gt;
&amp;lt;code&amp;gt;    RenderingSurface* surface;&lt;br /&gt;
&lt;br /&gt;
    if (ctx.surface-&amp;gt;isRenderingWindow())&lt;br /&gt;
        surface = &amp;amp;static_cast&amp;lt;RenderingWindow*&amp;gt;(ctx.surface)-&amp;gt;getOwner();&lt;br /&gt;
    else&lt;br /&gt;
        surface = ctx.surface;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The next part is key, and is in fact, single most important line in the tutorial.  This is where we queue our custom GeometryBuffer instance to the surface we chose above.&lt;br /&gt;
&amp;lt;code&amp;gt;    surface-&amp;gt;addGeometryBuffer(ctx.queue, *d_linksGeometry); &amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally we call the base class implementation so that the regular FrameWindow rendering is now performed (actually, it's queued - just like our custom GeometryBuffer above!)&lt;br /&gt;
&amp;lt;code&amp;gt;    FrameWindow::drawSelf(ctx);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===LinkGeometryBuffer class===&lt;br /&gt;
The class declaration for LinkGeometryBuffer is as follows:&lt;br /&gt;
&amp;lt;code&amp;gt;class LinkGeometryBuffer : public CEGUI::GeometryBuffer&lt;br /&gt;
{&lt;br /&gt;
public:&lt;br /&gt;
    LinkGeometryBuffer(LinkedWindow* owner);&lt;br /&gt;
&lt;br /&gt;
    // required interface functions for base class.&lt;br /&gt;
    void draw() const;&lt;br /&gt;
    void setTranslation(const CEGUI::Vector3&amp;amp; v) {}&lt;br /&gt;
    void setRotation(const CEGUI::Vector3&amp;amp; r) {}&lt;br /&gt;
    void setPivot(const CEGUI::Vector3&amp;amp; p) {}&lt;br /&gt;
    void setClippingRegion(const CEGUI::Rect&amp;amp; region) {}&lt;br /&gt;
    void appendVertex(const CEGUI::Vertex&amp;amp; vertex) {}&lt;br /&gt;
    void appendGeometry(const CEGUI::Vertex* const vbuff, CEGUI::uint vertex_count) {}&lt;br /&gt;
    void setActiveTexture(CEGUI::Texture* texture) {}&lt;br /&gt;
    void reset() {}&lt;br /&gt;
    CEGUI::Texture* getActiveTexture() const {return 0;}&lt;br /&gt;
    CEGUI::uint getVertexCount() const {return 0;}&lt;br /&gt;
    CEGUI::uint getBatchCount() const {return 0;}&lt;br /&gt;
    void setRenderEffect(CEGUI::RenderEffect* effect) {}&lt;br /&gt;
    CEGUI::RenderEffect* getRenderEffect() {return 0;}&lt;br /&gt;
&lt;br /&gt;
protected:&lt;br /&gt;
    //! helper that uses GL calls to render the link line&lt;br /&gt;
    static void drawLink(const CEGUI::Vector2&amp;amp; source, const CEGUI::Vector2&amp;amp; dest,&lt;br /&gt;
                         float source_size, float dest_size);&lt;br /&gt;
    //! helper that uses GL calls to render an arrow.&lt;br /&gt;
    static void drawArrowRight(float x, float y, float sz);&lt;br /&gt;
&lt;br /&gt;
    //! LinkedWindow that created and owns the GeometryBuffer.&lt;br /&gt;
    LinkedWindow* d_owner;&lt;br /&gt;
};&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As you can see it's pretty much just the required functions as specified by the CEGUI::GeometryBuffer interface, along with a couple of helper functions which are specific to this demo.&lt;br /&gt;
&lt;br /&gt;
====The GeometryBuffer::draw override====&lt;br /&gt;
Below is the code for the custom drawing function.  There is little to discuss, since this is just some very basic code and OpenGL calls.  We basically determine the source and destination locations which will be the end points of the link line, and call a helper function that makes the GL calls to draw.  It's probably worth highlighting the calls that save and restore the GL attributes, we do this because CEGUI will not expect it's states to get messed up mid-way through rendering!  We don't save the model-view matrix, since this is reset by each GeometryBuffer anyway.&lt;br /&gt;
&amp;lt;code&amp;gt;    if (!d_owner-&amp;gt;getTarget())&lt;br /&gt;
        return;&lt;br /&gt;
&lt;br /&gt;
    const Rect src_area(d_owner-&amp;gt;getUnclippedOuterRect());&lt;br /&gt;
    const Rect dst_area(d_owner-&amp;gt;getTarget()-&amp;gt;getUnclippedOuterRect());&lt;br /&gt;
&lt;br /&gt;
    const Vector2 source(&lt;br /&gt;
        src_area.d_right,&lt;br /&gt;
        src_area.d_top + ((src_area.d_bottom - src_area.d_top) / 2));&lt;br /&gt;
&lt;br /&gt;
    const Vector2 dest(&lt;br /&gt;
        dst_area.d_left,&lt;br /&gt;
        dst_area.d_top + ((dst_area.d_bottom - dst_area.d_top) / 2));&lt;br /&gt;
&lt;br /&gt;
    glPushClientAttrib(GL_CLIENT_ALL_ATTRIB_BITS);&lt;br /&gt;
    glPushAttrib(GL_ALL_ATTRIB_BITS);&lt;br /&gt;
&lt;br /&gt;
    glMatrixMode(GL_MODELVIEW);&lt;br /&gt;
    glLoadIdentity();&lt;br /&gt;
&lt;br /&gt;
    glBindTexture(GL_TEXTURE_2D, 0);&lt;br /&gt;
    glDisable(GL_SCISSOR_TEST);&lt;br /&gt;
&lt;br /&gt;
    glColor3f(0.1, 1, 0.2);&lt;br /&gt;
    drawLink(source, dest, 15, 9);&lt;br /&gt;
&lt;br /&gt;
    glPopAttrib();&lt;br /&gt;
    glPopClientAttrib();&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And that really is all there is to it!&lt;br /&gt;
&lt;br /&gt;
===Registering the new window type===&lt;br /&gt;
The new window type is registered using the WindowFactoryManager and the templatised WindowFactory, like so:&lt;br /&gt;
&amp;lt;code&amp;gt;WindowFactoryManager::getSingleton().addFactory&amp;lt;TplWindowFactory&amp;lt;LinkedWindow&amp;gt; &amp;gt;();&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For this example, the falagard mapping that makes this usable is specified in code, but it's just as easily added to your XML scheme file:&lt;br /&gt;
&amp;lt;code&amp;gt;WindowFactoryManager::getSingleton().&lt;br /&gt;
    addFalagardWindowMapping(&amp;quot;TaharezLook/LinkedWindow&amp;quot;,&lt;br /&gt;
                             &amp;quot;LinkedWindow&amp;quot;,&lt;br /&gt;
                             &amp;quot;TaharezLook/FrameWindow&amp;quot;,&lt;br /&gt;
                             &amp;quot;Falagard/FrameWindow&amp;quot;);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Conclusion==&lt;br /&gt;
Here we have seen how to hook into the CEGUI rendering process by queueing a custom GeometryBuffer implementation along with (or instead of) the regular GeometryBuffer queued by the Window's drawSelf function.  This allows any custom rendering to be performed at the correct time so it appears at the same layered position as a window in the output.&lt;br /&gt;
&lt;br /&gt;
==Example Code==&lt;br /&gt;
===LinkedWindow Class Declaration (LinkedWindow.h)===&lt;br /&gt;
&amp;lt;code&amp;gt;#ifndef _LINKED_WINDOW_H&lt;br /&gt;
#define _LINKED_WINDOW_H&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;elements/CEGUIFrameWindow.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
/*!&lt;br /&gt;
\brief&lt;br /&gt;
    Custom subclass of FrameWindow.  The main purpose of this is so we can&lt;br /&gt;
    override the Window::drawSelf function in order to add an instance of&lt;br /&gt;
    our custom GeometryBuffer at an appropriate place - which will then&lt;br /&gt;
    render the link lines when it's draw function is called.&lt;br /&gt;
*/&lt;br /&gt;
class LinkedWindow : public CEGUI::FrameWindow&lt;br /&gt;
{&lt;br /&gt;
public:&lt;br /&gt;
    //! 'Namespace' string used for global events on this class.&lt;br /&gt;
	static const CEGUI::String EventNamespace;&lt;br /&gt;
    //! String holding the type name of this widget.&lt;br /&gt;
    static const CEGUI::String WidgetTypeName;&lt;br /&gt;
&lt;br /&gt;
    //! set window that will be the target of our link line.&lt;br /&gt;
    void setTarget(const CEGUI::Window* target);&lt;br /&gt;
    //! return pointer that is our current link target.&lt;br /&gt;
    const CEGUI::Window* getTarget() const;&lt;br /&gt;
&lt;br /&gt;
    LinkedWindow(const CEGUI::String&amp;amp; type, const CEGUI::String&amp;amp; name);&lt;br /&gt;
    ~LinkedWindow();&lt;br /&gt;
&lt;br /&gt;
protected:&lt;br /&gt;
    // overridden from base class.&lt;br /&gt;
    void drawSelf(const CEGUI::RenderingContext&amp;amp; ctx);&lt;br /&gt;
    bool testClassName_impl(const CEGUI::String&amp;amp; class_name) const;&lt;br /&gt;
&lt;br /&gt;
    //! pointer to a GeometryBuffer that will render our link line.&lt;br /&gt;
    CEGUI::GeometryBuffer* d_linksGeometry;&lt;br /&gt;
    //! pointer to the target window of our link line.  May be zero.&lt;br /&gt;
    const CEGUI::Window* d_target;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
#endif&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===LinkedWindow Class Implementation (LinkedWindow.cpp)===&lt;br /&gt;
&amp;lt;code&amp;gt;#include &amp;lt;CEGUIRenderingWindow.h&amp;gt;&lt;br /&gt;
#include &amp;lt;CEGUIRenderingContext.h&amp;gt;&lt;br /&gt;
#include &amp;quot;LinkedWindow.h&amp;quot;&lt;br /&gt;
#include &amp;quot;LinkGeometryBuffer.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
using namespace CEGUI;&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
const String LinkedWindow::EventNamespace(&amp;quot;LinkedWindow&amp;quot;);&lt;br /&gt;
const String LinkedWindow::WidgetTypeName(&amp;quot;LinkedWindow&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
LinkedWindow::LinkedWindow(const CEGUI::String&amp;amp; type, const CEGUI::String&amp;amp; name) :&lt;br /&gt;
    FrameWindow(type, name),&lt;br /&gt;
    d_linksGeometry(new LinkGeometryBuffer(this)),&lt;br /&gt;
    d_target(0)&lt;br /&gt;
{&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
void LinkedWindow::setTarget(const CEGUI::Window* target)&lt;br /&gt;
{&lt;br /&gt;
    d_target = target;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
const Window* LinkedWindow::getTarget() const&lt;br /&gt;
{&lt;br /&gt;
    return d_target;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
LinkedWindow::~LinkedWindow()&lt;br /&gt;
{&lt;br /&gt;
    delete d_linksGeometry;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
void LinkedWindow::drawSelf(const RenderingContext&amp;amp; ctx)&lt;br /&gt;
{&lt;br /&gt;
    RenderingSurface* surface;&lt;br /&gt;
&lt;br /&gt;
    if (ctx.surface-&amp;gt;isRenderingWindow())&lt;br /&gt;
        surface = &amp;amp;static_cast&amp;lt;RenderingWindow*&amp;gt;(ctx.surface)-&amp;gt;getOwner();&lt;br /&gt;
    else&lt;br /&gt;
        surface = ctx.surface;&lt;br /&gt;
&lt;br /&gt;
    surface-&amp;gt;addGeometryBuffer(ctx.queue, *d_linksGeometry); &lt;br /&gt;
&lt;br /&gt;
    FrameWindow::drawSelf(ctx);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
bool LinkedWindow::testClassName_impl(const CEGUI::String&amp;amp; class_name) const&lt;br /&gt;
{&lt;br /&gt;
    if (class_name == LinkedWindow::WidgetTypeName)&lt;br /&gt;
        return true;&lt;br /&gt;
&lt;br /&gt;
    return FrameWindow::testClassName_impl(class_name);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===LinkGeometryBuffer Class Declaration (LinkGeometryBuffer.h)===&lt;br /&gt;
&amp;lt;code&amp;gt;#ifndef _LINK_GEOMETRY_BUFFER_H&lt;br /&gt;
#define _LINK_GEOMETRY_BUFFER_H&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;CEGUIGeometryBuffer.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
class LinkedWindow;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
/*!&lt;br /&gt;
/brief&lt;br /&gt;
    Custom GeometryBuffer used for drawing links from a LinkedWindow to its&lt;br /&gt;
    target window.&lt;br /&gt;
&lt;br /&gt;
\note&lt;br /&gt;
    The only part of the regular GeometryBuffer interface we will implement is&lt;br /&gt;
    the GeometryBuffer::draw function, the rest is stubbed out.  Note also that&lt;br /&gt;
    we don't actually 'buffer' anything here, but do direct drawing within the&lt;br /&gt;
    draw function.&lt;br /&gt;
*/&lt;br /&gt;
class LinkGeometryBuffer : public CEGUI::GeometryBuffer&lt;br /&gt;
{&lt;br /&gt;
public:&lt;br /&gt;
    LinkGeometryBuffer(LinkedWindow* owner);&lt;br /&gt;
&lt;br /&gt;
    // required interface functions for base class.&lt;br /&gt;
    void draw() const;&lt;br /&gt;
    void setTranslation(const CEGUI::Vector3&amp;amp; v) {}&lt;br /&gt;
    void setRotation(const CEGUI::Vector3&amp;amp; r) {}&lt;br /&gt;
    void setPivot(const CEGUI::Vector3&amp;amp; p) {}&lt;br /&gt;
    void setClippingRegion(const CEGUI::Rect&amp;amp; region) {}&lt;br /&gt;
    void appendVertex(const CEGUI::Vertex&amp;amp; vertex) {}&lt;br /&gt;
    void appendGeometry(const CEGUI::Vertex* const vbuff, CEGUI::uint vertex_count) {}&lt;br /&gt;
    void setActiveTexture(CEGUI::Texture* texture) {}&lt;br /&gt;
    void reset() {}&lt;br /&gt;
    CEGUI::Texture* getActiveTexture() const {return 0;}&lt;br /&gt;
    CEGUI::uint getVertexCount() const {return 0;}&lt;br /&gt;
    CEGUI::uint getBatchCount() const {return 0;}&lt;br /&gt;
    void setRenderEffect(CEGUI::RenderEffect* effect) {}&lt;br /&gt;
    CEGUI::RenderEffect* getRenderEffect() {return 0;}&lt;br /&gt;
&lt;br /&gt;
protected:&lt;br /&gt;
    //! helper that uses GL calls to render the link line&lt;br /&gt;
    static void drawLink(const CEGUI::Vector2&amp;amp; source, const CEGUI::Vector2&amp;amp; dest,&lt;br /&gt;
                         float source_size, float dest_size);&lt;br /&gt;
    //! helper that uses GL calls to render an arrow.&lt;br /&gt;
    static void drawArrowRight(float x, float y, float sz);&lt;br /&gt;
&lt;br /&gt;
    //! LinkedWindow that created and owns the GeometryBuffer.&lt;br /&gt;
    LinkedWindow* d_owner;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
#endif&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===LinkGeometryBuffer Class Implementation (LinkGeometryBuffer.cpp)===&lt;br /&gt;
&amp;lt;code&amp;gt;#include &amp;quot;LinkGeometryBuffer.h&amp;quot;&lt;br /&gt;
#include &amp;quot;LinkedWindow.h&amp;quot;&lt;br /&gt;
#include &amp;lt;GL/gl.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
using namespace CEGUI;&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
LinkGeometryBuffer::LinkGeometryBuffer(LinkedWindow* owner) :&lt;br /&gt;
    d_owner(owner)&lt;br /&gt;
{&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
void LinkGeometryBuffer::draw() const&lt;br /&gt;
{&lt;br /&gt;
    if (!d_owner-&amp;gt;getTarget())&lt;br /&gt;
        return;&lt;br /&gt;
&lt;br /&gt;
    const Rect src_area(d_owner-&amp;gt;getUnclippedOuterRect());&lt;br /&gt;
    const Rect dst_area(d_owner-&amp;gt;getTarget()-&amp;gt;getUnclippedOuterRect());&lt;br /&gt;
&lt;br /&gt;
    const Vector2 source(&lt;br /&gt;
        src_area.d_right,&lt;br /&gt;
        src_area.d_top + ((src_area.d_bottom - src_area.d_top) / 2));&lt;br /&gt;
&lt;br /&gt;
    const Vector2 dest(&lt;br /&gt;
        dst_area.d_left,&lt;br /&gt;
        dst_area.d_top + ((dst_area.d_bottom - dst_area.d_top) / 2));&lt;br /&gt;
&lt;br /&gt;
    glPushClientAttrib(GL_CLIENT_ALL_ATTRIB_BITS);&lt;br /&gt;
    glPushAttrib(GL_ALL_ATTRIB_BITS);&lt;br /&gt;
&lt;br /&gt;
    glMatrixMode(GL_MODELVIEW);&lt;br /&gt;
    glLoadIdentity();&lt;br /&gt;
&lt;br /&gt;
    glBindTexture(GL_TEXTURE_2D, 0);&lt;br /&gt;
    glDisable(GL_SCISSOR_TEST);&lt;br /&gt;
&lt;br /&gt;
    glColor3f(0.1, 1, 0.2);&lt;br /&gt;
    drawLink(source, dest, 15, 9);&lt;br /&gt;
&lt;br /&gt;
    glPopAttrib();&lt;br /&gt;
    glPopClientAttrib();&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
void LinkGeometryBuffer::drawLink(const Vector2&amp;amp; source, const Vector2&amp;amp; dest,&lt;br /&gt;
                                  float source_size, float dest_size)&lt;br /&gt;
{&lt;br /&gt;
    drawArrowRight(source.d_x, source.d_y, source_size);&lt;br /&gt;
&lt;br /&gt;
    glBegin(GL_LINES);&lt;br /&gt;
        glVertex2f(source.d_x + (source_size - 1), source.d_y);&lt;br /&gt;
        glVertex2f(dest.d_x - (dest_size - 1), dest.d_y);&lt;br /&gt;
    glEnd();&lt;br /&gt;
&lt;br /&gt;
    drawArrowRight(dest.d_x - dest_size, dest.d_y, dest_size);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
void LinkGeometryBuffer::drawArrowRight(float x, float y, float sz)&lt;br /&gt;
{&lt;br /&gt;
    glBegin(GL_TRIANGLES);&lt;br /&gt;
        glVertex2f(x, y - sz / 2);&lt;br /&gt;
        glVertex2f(x, y + sz / 2);&lt;br /&gt;
        glVertex2f(x + sz, y);&lt;br /&gt;
    glEnd();&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Demo App code using GLUT (main.cpp)===&lt;br /&gt;
&amp;lt;code&amp;gt;#include &amp;lt;GL/glut.h&amp;gt;&lt;br /&gt;
#include &amp;lt;CEGUI.h&amp;gt;&lt;br /&gt;
#include &amp;lt;RendererModules/OpenGL/CEGUIOpenGLRenderer.h&amp;gt;&lt;br /&gt;
#include &amp;quot;LinkedWindow.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
using namespace CEGUI;&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
void drawFunc()&lt;br /&gt;
{&lt;br /&gt;
    glClearColor(0, 0, 0, 1);&lt;br /&gt;
    glClear(GL_COLOR_BUFFER_BIT);&lt;br /&gt;
&lt;br /&gt;
    System::getSingleton().renderGUI();&lt;br /&gt;
&lt;br /&gt;
    glutSwapBuffers();&lt;br /&gt;
    glutPostRedisplay();&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
void moveFunc(int x, int y)&lt;br /&gt;
{&lt;br /&gt;
    System::getSingleton().injectMousePosition(x, y);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
void mouseButtonFunc(int button, int state, int, int)&lt;br /&gt;
{&lt;br /&gt;
    MouseButton cegui_btn;&lt;br /&gt;
&lt;br /&gt;
    switch (button)&lt;br /&gt;
    {&lt;br /&gt;
    case GLUT_MIDDLE_BUTTON:&lt;br /&gt;
        cegui_btn = MiddleButton;&lt;br /&gt;
        break;&lt;br /&gt;
&lt;br /&gt;
    case GLUT_RIGHT_BUTTON:&lt;br /&gt;
        cegui_btn = RightButton;&lt;br /&gt;
        break;&lt;br /&gt;
&lt;br /&gt;
    default:&lt;br /&gt;
        cegui_btn = LeftButton;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    if (state == GLUT_UP)&lt;br /&gt;
        System::getSingleton().injectMouseButtonUp(cegui_btn);&lt;br /&gt;
    else&lt;br /&gt;
        System::getSingleton().injectMouseButtonDown(cegui_btn);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
void initialiseGLUT(int argc, char* argv[])&lt;br /&gt;
{&lt;br /&gt;
    glutInit(&amp;amp;argc, argv);&lt;br /&gt;
    glutInitWindowSize(800, 600);&lt;br /&gt;
    glutInitDisplayMode(GLUT_DOUBLE );&lt;br /&gt;
    glutCreateWindow(&amp;quot;CEGUI Demo App&amp;quot;);&lt;br /&gt;
    glutDisplayFunc(drawFunc);&lt;br /&gt;
    glutMotionFunc(moveFunc);&lt;br /&gt;
    glutPassiveMotionFunc(moveFunc);&lt;br /&gt;
    glutMouseFunc(mouseButtonFunc);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
void initialiseCEGUIResources()&lt;br /&gt;
{&lt;br /&gt;
    DefaultResourceProvider* rp = static_cast&amp;lt;DefaultResourceProvider*&amp;gt;(&lt;br /&gt;
        System::getSingleton().getResourceProvider());&lt;br /&gt;
    rp-&amp;gt;setResourceGroupDirectory(&amp;quot;schemes&amp;quot;, &amp;quot;/usr/local/share/CEGUI/schemes&amp;quot;);&lt;br /&gt;
    rp-&amp;gt;setResourceGroupDirectory(&amp;quot;imagesets&amp;quot;, &amp;quot;/usr/local/share/CEGUI/imagesets&amp;quot;);&lt;br /&gt;
    rp-&amp;gt;setResourceGroupDirectory(&amp;quot;fonts&amp;quot;, &amp;quot;/usr/local/share/CEGUI/fonts&amp;quot;);&lt;br /&gt;
    rp-&amp;gt;setResourceGroupDirectory(&amp;quot;looknfeel&amp;quot;, &amp;quot;/usr/local/share/CEGUI/looknfeel&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    Scheme::setDefaultResourceGroup(&amp;quot;schemes&amp;quot;);&lt;br /&gt;
    Imageset::setDefaultResourceGroup(&amp;quot;imagesets&amp;quot;);&lt;br /&gt;
    Font::setDefaultResourceGroup(&amp;quot;fonts&amp;quot;);&lt;br /&gt;
    WidgetLookManager::setDefaultResourceGroup(&amp;quot;looknfeel&amp;quot;);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
void registerCustomWindow()&lt;br /&gt;
{&lt;br /&gt;
    // register the new window type&lt;br /&gt;
    WindowFactoryManager::getSingleton().&lt;br /&gt;
        addFactory&amp;lt;TplWindowFactory&amp;lt;LinkedWindow&amp;gt; &amp;gt;();&lt;br /&gt;
&lt;br /&gt;
    // make a mapping that uses the existing TL/FrameWindow renderer.&lt;br /&gt;
    WindowFactoryManager::getSingleton().&lt;br /&gt;
        addFalagardWindowMapping(&amp;quot;TaharezLook/LinkedWindow&amp;quot;,&lt;br /&gt;
                                 &amp;quot;LinkedWindow&amp;quot;,&lt;br /&gt;
                                 &amp;quot;TaharezLook/FrameWindow&amp;quot;,&lt;br /&gt;
                                 &amp;quot;Falagard/FrameWindow&amp;quot;);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
bool checkBoxHandler(const EventArgs&amp;amp; a)&lt;br /&gt;
{&lt;br /&gt;
    const WindowEventArgs&amp;amp; wa = static_cast&amp;lt;const WindowEventArgs&amp;amp;&amp;gt;(a);&lt;br /&gt;
    Checkbox* cb = static_cast&amp;lt;Checkbox*&amp;gt;(wa.window);&lt;br /&gt;
&lt;br /&gt;
    const String lnkWindowName(cb-&amp;gt;getUserString(&amp;quot;LinkedWindow&amp;quot;));&lt;br /&gt;
&lt;br /&gt;
    if (!lnkWindowName.empty())&lt;br /&gt;
    {&lt;br /&gt;
        Window* lw = WindowManager::getSingleton().getWindow(lnkWindowName);&lt;br /&gt;
        lw-&amp;gt;setVisible(cb-&amp;gt;isSelected());&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
LinkedWindow* createLinkedWindow(const String&amp;amp; name,&lt;br /&gt;
                                 float x, float y, float w, float h,&lt;br /&gt;
                                 const String&amp;amp; title,&lt;br /&gt;
                                 bool initially_hidden)&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    LinkedWindow* wnd = static_cast&amp;lt;LinkedWindow*&amp;gt;(&lt;br /&gt;
        WindowManager::getSingleton().&lt;br /&gt;
            createWindow(&amp;quot;TaharezLook/LinkedWindow&amp;quot;, name));&lt;br /&gt;
&lt;br /&gt;
    wnd-&amp;gt;setPosition(UVector2(UDim(x, 0), UDim(y, 0)));&lt;br /&gt;
    wnd-&amp;gt;setSize(UVector2(UDim(w, 0), UDim(h, 0)));&lt;br /&gt;
    wnd-&amp;gt;setUsingAutoRenderingSurface(false);&lt;br /&gt;
    wnd-&amp;gt;setText(title);&lt;br /&gt;
    wnd-&amp;gt;setVisible(!initially_hidden);&lt;br /&gt;
&lt;br /&gt;
    return wnd;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
Checkbox* createCheckbox(float x, float y, const String&amp;amp; label)&lt;br /&gt;
{&lt;br /&gt;
    Checkbox* wnd = static_cast&amp;lt;Checkbox*&amp;gt;(WindowManager::getSingleton().&lt;br /&gt;
        createWindow(&amp;quot;TaharezLook/Checkbox&amp;quot;));&lt;br /&gt;
    wnd-&amp;gt;setPosition(UVector2(UDim(x, 0), UDim(y, 0)));&lt;br /&gt;
    wnd-&amp;gt;setSize(UVector2(UDim(1.0, 0), UDim(0.2, 0)));&lt;br /&gt;
    wnd-&amp;gt;setText(label);&lt;br /&gt;
    wnd-&amp;gt;subscribeEvent(Checkbox::EventCheckStateChanged, checkBoxHandler);&lt;br /&gt;
&lt;br /&gt;
    return wnd;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&lt;br /&gt;
int main(int argc, char* argv[])&lt;br /&gt;
{&lt;br /&gt;
    initialiseGLUT(argc, argv);&lt;br /&gt;
&lt;br /&gt;
    System::setDefaultXMLParserName(&amp;quot;ExpatParser&amp;quot;);&lt;br /&gt;
    OpenGLRenderer::bootstrapSystem();&lt;br /&gt;
    initialiseCEGUIResources();&lt;br /&gt;
&lt;br /&gt;
    SchemeManager::getSingleton().create(&amp;quot;TaharezLook.scheme&amp;quot;);&lt;br /&gt;
    System::getSingleton().setDefaultMouseCursor(&amp;quot;TaharezLook&amp;quot;, &amp;quot;MouseArrow&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    registerCustomWindow();&lt;br /&gt;
&lt;br /&gt;
    WindowManager&amp;amp; winMgr(WindowManager::getSingleton());&lt;br /&gt;
    Window* root = winMgr.createWindow(&amp;quot;DefaultWindow&amp;quot;);&lt;br /&gt;
    System::getSingleton().setGUISheet(root);&lt;br /&gt;
&lt;br /&gt;
    LinkedWindow* main = createLinkedWindow(&amp;quot;main&amp;quot;, 0.4, 0.2, 0.25, 0.25, &amp;quot;Main Window&amp;quot;, false);&lt;br /&gt;
    root-&amp;gt;addChildWindow(main);&lt;br /&gt;
&lt;br /&gt;
    LinkedWindow* src1 = createLinkedWindow(&amp;quot;src1&amp;quot;, 0.1, 0.1, 0.2, 0.15, &amp;quot;Src Wnd 1&amp;quot;, true);&lt;br /&gt;
    root-&amp;gt;addChildWindow(src1);&lt;br /&gt;
&lt;br /&gt;
    LinkedWindow* src2 = createLinkedWindow(&amp;quot;src2&amp;quot;, 0.1, 0.3, 0.2, 0.15, &amp;quot;Src Wnd 2&amp;quot;, true);&lt;br /&gt;
    root-&amp;gt;addChildWindow(src2);&lt;br /&gt;
&lt;br /&gt;
    LinkedWindow* dst1 = createLinkedWindow(&amp;quot;dst1&amp;quot;, 0.7, 0.1, 0.25, 0.25, &amp;quot;Dst Wnd 1&amp;quot;, false);&lt;br /&gt;
    root-&amp;gt;addChildWindow(dst1);&lt;br /&gt;
&lt;br /&gt;
    Window* tg1 = createCheckbox(0, 0, &amp;quot;Link Target 1&amp;quot;);&lt;br /&gt;
    main-&amp;gt;addChildWindow(tg1);&lt;br /&gt;
    src1-&amp;gt;setTarget(tg1);&lt;br /&gt;
    tg1-&amp;gt;setUserString(&amp;quot;LinkedWindow&amp;quot;, &amp;quot;src1&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    Window* tg2 = createCheckbox(0, 0.2, &amp;quot;Link Target 2&amp;quot;);&lt;br /&gt;
    main-&amp;gt;addChildWindow(tg2);&lt;br /&gt;
    tg2-&amp;gt;setUserString(&amp;quot;LinkedWindow&amp;quot;, &amp;quot;&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    Window* tg3 = createCheckbox(0, 0.4, &amp;quot;Link Target 3&amp;quot;);&lt;br /&gt;
    main-&amp;gt;addChildWindow(tg3);&lt;br /&gt;
    src2-&amp;gt;setTarget(tg3);&lt;br /&gt;
    tg3-&amp;gt;setUserString(&amp;quot;LinkedWindow&amp;quot;, &amp;quot;src2&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    Window* button = winMgr.createWindow(&amp;quot;TaharezLook/Button&amp;quot;);&lt;br /&gt;
    button-&amp;gt;setPosition(UVector2(UDim(0.0, 0), UDim(0.3, 0)));&lt;br /&gt;
    button-&amp;gt;setSize(UVector2(UDim(1.0, 0), UDim(0.2, 0)));&lt;br /&gt;
    button-&amp;gt;setText(&amp;quot;Engage!&amp;quot;);&lt;br /&gt;
    button-&amp;gt;setUserString(&amp;quot;LinkedWindow&amp;quot;, &amp;quot;main&amp;quot;);&lt;br /&gt;
    dst1-&amp;gt;addChildWindow(button);&lt;br /&gt;
    main-&amp;gt;setTarget(button);&lt;br /&gt;
&lt;br /&gt;
    glutMainLoop();&lt;br /&gt;
&lt;br /&gt;
    OpenGLRenderer::destroySystem();&lt;br /&gt;
&lt;br /&gt;
    return 0;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//----------------------------------------------------------------------------//&amp;lt;/code&amp;gt;&lt;/div&gt;</summary>
		<author><name>Crazyeddie</name></author>	</entry>

	</feed>