<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/atom10full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><feed xmlns="http://www.w3.org/2005/Atom" xmlns:thr="http://purl.org/syndication/thread/1.0" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" xml:lang="en" xml:base="http://www.jaygeiger.com/wp-atom.php">
	<title type="text">Geiger</title>
	<subtitle type="text">Geiger, you don't know me! (Yet)</subtitle>

	<updated>2010-07-20T13:57:50Z</updated>
	<generator uri="http://wordpress.org/" version="2.9.2">WordPress</generator>

	<link rel="alternate" type="text/html" href="http://www.jaygeiger.com" />
	<id>http://www.jaygeiger.com/index.php/feed/atom/</id>
	

			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/atom+xml" href="http://feeds.feedburner.com/jaygeiger" /><feedburner:info uri="jaygeiger" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><feedburner:emailServiceId>jaygeiger</feedburner:emailServiceId><feedburner:feedburnerHostname>http://feedburner.google.com</feedburner:feedburnerHostname><entry>
		<author>
			<name>Jason Geiger</name>
						<uri>http://www.jaygeiger.com</uri>
					</author>
		<title type="html"><![CDATA[Save All IIS Settings to a File]]></title>
		<link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/jaygeiger/~3/GqrzLgZVoqg/" />
		<id>http://www.jaygeiger.com/index.php/2010/07/20/save-all-iis-settings-to-a-file/</id>
		<updated>2010-07-20T13:57:50Z</updated>
		<published>2010-07-20T13:57:50Z</published>
		<category scheme="http://www.jaygeiger.com" term="Uncategorized" />		<summary type="html"><![CDATA[Most of my readers won’t care to know this.&#160; However, the IIS dorks out there will find it nifty to know how to save all IIS settings to a file.
C:\Inetpub\AdminScripts&#62;Cscript.exe adsutil.vbs ENUMALL &#62; a.txt

That’s it.
It’s a nice way to find the full virtual path of an app.&#160; Just save the settings to a text file [...]]]></summary>
		<content type="html" xml:base="http://www.jaygeiger.com/index.php/2010/07/20/save-all-iis-settings-to-a-file/">&lt;p&gt;Most of my readers won’t care to know this.&amp;#160; However, the IIS dorks out there will find it nifty to know how to save all IIS settings to a file.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;C:\Inetpub\AdminScripts&amp;gt;Cscript.exe adsutil.vbs ENUMALL &amp;gt; a.txt&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;That’s it.&lt;/p&gt;
&lt;p&gt;It’s a nice way to find the full virtual path of an app.&amp;#160; Just save the settings to a text file and search it for the app name.&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/jaygeiger/~4/GqrzLgZVoqg" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://www.jaygeiger.com/index.php/2010/07/20/save-all-iis-settings-to-a-file/#comments" thr:count="0" />
		<link rel="replies" type="application/atom+xml" href="http://www.jaygeiger.com/index.php/2010/07/20/save-all-iis-settings-to-a-file/feed/atom/" thr:count="0" />
		<thr:total>0</thr:total>
	<feedburner:origLink>http://www.jaygeiger.com/index.php/2010/07/20/save-all-iis-settings-to-a-file/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>Jason Geiger</name>
						<uri>http://www.jaygeiger.com</uri>
					</author>
		<title type="html"><![CDATA[Earthquake &#8211; Find Out More Here]]></title>
		<link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/jaygeiger/~3/BwOflK8aXfU/" />
		<id>http://www.jaygeiger.com/index.php/2010/06/23/earthquake-find-out-more-here/</id>
		<updated>2010-06-23T18:09:59Z</updated>
		<published>2010-06-23T18:09:59Z</published>
		<category scheme="http://www.jaygeiger.com" term="Uncategorized" />		<summary type="html"><![CDATA[More info about the earthquake here.
http://www.hotbuffalo.com
]]></summary>
		<content type="html" xml:base="http://www.jaygeiger.com/index.php/2010/06/23/earthquake-find-out-more-here/">&lt;p&gt;More info about the earthquake here.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://www.hotbuffalo.com"&gt;http://www.hotbuffalo.com&lt;/a&gt;&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/jaygeiger/~4/BwOflK8aXfU" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://www.jaygeiger.com/index.php/2010/06/23/earthquake-find-out-more-here/#comments" thr:count="1" />
		<link rel="replies" type="application/atom+xml" href="http://www.jaygeiger.com/index.php/2010/06/23/earthquake-find-out-more-here/feed/atom/" thr:count="1" />
		<thr:total>1</thr:total>
	<feedburner:origLink>http://www.jaygeiger.com/index.php/2010/06/23/earthquake-find-out-more-here/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>Jason Geiger</name>
						<uri>http://www.jaygeiger.com</uri>
					</author>
		<title type="html"><![CDATA[Earthquake Felt in Buffalo]]></title>
		<link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/jaygeiger/~3/vR3L4zN-bww/" />
		<id>http://www.jaygeiger.com/index.php/2010/06/23/earthquake-felt-in-buffalo/</id>
		<updated>2010-06-23T17:46:48Z</updated>
		<published>2010-06-23T17:46:48Z</published>
		<category scheme="http://www.jaygeiger.com" term="Uncategorized" />		<summary type="html"><![CDATA[An earthquake was felt in Buffalo at 1:45pm today June 23rd.
More to follow!
]]></summary>
		<content type="html" xml:base="http://www.jaygeiger.com/index.php/2010/06/23/earthquake-felt-in-buffalo/">&lt;p&gt;An earthquake was felt in Buffalo at 1:45pm today June 23rd.&lt;/p&gt;
&lt;p&gt;More to follow!&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/jaygeiger/~4/vR3L4zN-bww" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://www.jaygeiger.com/index.php/2010/06/23/earthquake-felt-in-buffalo/#comments" thr:count="0" />
		<link rel="replies" type="application/atom+xml" href="http://www.jaygeiger.com/index.php/2010/06/23/earthquake-felt-in-buffalo/feed/atom/" thr:count="0" />
		<thr:total>0</thr:total>
	<feedburner:origLink>http://www.jaygeiger.com/index.php/2010/06/23/earthquake-felt-in-buffalo/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>Jason Geiger</name>
						<uri>http://www.jaygeiger.com</uri>
					</author>
		<title type="html"><![CDATA[Palm&#8217;s WebOS PDK]]></title>
		<link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/jaygeiger/~3/FfH1-dGacmk/" />
		<id>http://www.jaygeiger.com/index.php/2010/06/16/palms-webos-pdk/</id>
		<updated>2010-06-16T19:18:29Z</updated>
		<published>2010-06-16T19:15:09Z</published>
		<category scheme="http://www.jaygeiger.com" term="Uncategorized" />		<summary type="html"><![CDATA[The objective of this post is to simplify the “Simple” 3D program from Palm for WebOS’s PDK.
Back in 1998 or so I took a Graphics Programming class at SUNY Fredonia. It had way too much linear algebra in it. I had no idea how to do math with matrices. Matrix Math may sound like a [...]]]></summary>
		<content type="html" xml:base="http://www.jaygeiger.com/index.php/2010/06/16/palms-webos-pdk/">&lt;p&gt;The objective of this post is to simplify the “Simple” 3D program from Palm for WebOS’s PDK.&lt;/p&gt;
&lt;p&gt;Back in 1998 or so I took a Graphics Programming class at SUNY Fredonia. It had way too much linear algebra in it. I had no idea how to do math with matrices. Matrix Math may sound like a boring sequel to a Keanu Reaves movie but is the underlying engine to convert 3D objects to a 2D picture i.e. Your computer screen.&lt;/p&gt;
&lt;p&gt;Thankfully, when it came to programming you didn’t need to worry about that kind of thing usually.&lt;/p&gt;
&lt;p&gt;With the full version of OpenGL and the Glut library it was &lt;b&gt;easy &lt;/b&gt;to create 3D objects add lighting and move the objects around.&lt;/p&gt;
&lt;p&gt;When the PDK came out for WebOS I was excited. Maybe I should recreate my final project from Graphics Programming class (Boxing Bunnies, 3D cartoon bunnies that punched each other).&lt;/p&gt;
&lt;p&gt;I downloaded the PDK and got the “Simple” example to run super easily in Visual Studio. “SWEET!” I thought, “Let’s look at the code and start expanding it”.&lt;/p&gt;
&lt;p&gt;BLAM! I was lost. Programs to “Shade” both “Vertices and Fragments”… Each Vertex labeled along with a tons of things called “Faces”. Where are my rectangles? Where are my complex flat shapes, easily created spheres or light sources?&lt;/p&gt;
&lt;p&gt;I came to find out that OpenGL ES doesn’t have any of those libraries to make that stuff. OpenGL ES is meant to be extremely small and take up the least amount of resources possible.&lt;/p&gt;
&lt;p&gt;The only thing that you can draw is the simplest shape possible. A Triangle! Every other shape is made from them. Furthermore, what the heck is a vertex shader or a fragment shader? Why do I need 2 different shaders? A vertex is just a point in space, so how can I shade one?&lt;/p&gt;
&lt;p&gt;So I kept walking away from the PDK and OpenGL ES then would pop my head back in. I even got the OpenGL ES 2 0 Programming Guide and was even more confused. Every example online references OpenGL ES 1 (which is very different from 2.0) or it used libraries to create shapes that aren’t included in the PDK.&lt;/p&gt;
&lt;p&gt;Well I eventually found some things out and have made a simple rotating triangle program based on Simple from Palm. I’ve added some comments so the code makes more sense. Each comment begins with “// Geiger &amp;#8211; …” so you can spot my comments.&lt;/p&gt;
&lt;p&gt;I haven’t gotten into describing shaders so much yet but plan to figure out the rest of their details and explain them in PLAIN English.&lt;/p&gt;
&lt;p&gt;If you replace the Simple.cpp code from Palm with the code below, you can play with the spinning Triangle. I will have more to say, especially about Shaders, soon.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://www.jaygeiger.com/downloads/simple.txt" target="_blank"&gt;&lt;u&gt;Download the Text File Here&lt;/u&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;/**   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; JayGeiger.com &amp;#8211; I&amp;#8217;ve added more comments so the program makes more sense.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; I will get into more details, especially Shaders in future blog posts.    &lt;br /&gt;**/    &lt;br /&gt;#include &amp;lt;stdio.h&amp;gt;    &lt;br /&gt;#include &amp;lt;math.h&amp;gt; &lt;/p&gt;
&lt;p&gt;#include &amp;lt;GLES2/gl2.h&amp;gt;   &lt;br /&gt;#include &amp;quot;SDL.h&amp;quot; &lt;/p&gt;
&lt;p&gt;SDL_Surface *Surface;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Screen surface to retrieve width/height information &lt;/p&gt;
&lt;p&gt;int&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Shader[2];&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // We have a vertex &amp;amp; a fragment shader   &lt;br /&gt;int&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Program;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Totalling one program    &lt;br /&gt;float&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Angle = 0.0;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Rotation angle of our object    &lt;br /&gt;float&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Proj[4][4];&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Projection matrix    &lt;br /&gt;int&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; iProj, iModel;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Our 2 uniforms &lt;/p&gt;
&lt;p&gt;#ifdef WIN32   &lt;br /&gt;extern &amp;quot;C&amp;quot;     &lt;br /&gt;#endif    &lt;br /&gt;GL_API int GL_APIENTRY _dgles_load_library(void *, void *(*)(void *, const char *)); &lt;/p&gt;
&lt;p&gt;static void *proc_loader(void *h, const char *name)   &lt;br /&gt;{    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; (void) h;    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; return SDL_GL_GetProcAddress(name);    &lt;br /&gt;} &lt;/p&gt;
&lt;p&gt;// Standard GL perspective matrix creation   &lt;br /&gt;void Persp(float Proj[4][4], const float FOV, const float ZNear, const float ZFar)    &lt;br /&gt;{    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; const float Delta&amp;#160;&amp;#160; = ZFar &amp;#8211; ZNear; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; memset(Proj, 0, sizeof(Proj)); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; Proj[0][0] = 1.0f / tanf(FOV * 3.1415926535f / 360.0f);   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Proj[1][1] = Proj[0][0] / ((float)Surface-&amp;gt;h / Surface-&amp;gt;w); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; Proj[2][2] = -(ZFar + ZNear) / Delta;   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Proj[2][3] = -1.0f;    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Proj[3][2] = -2.0f * ZFar * ZNear / Delta;    &lt;br /&gt;} &lt;/p&gt;
&lt;p&gt;// Simple function to create a shader   &lt;br /&gt;void LoadShader(char *Code, int ID)    &lt;br /&gt;{    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Compile the shader code    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glShaderSource&amp;#160; (ID, 1, (const char **)&amp;amp;Code, NULL);     &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glCompileShader (ID); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Verify that it worked   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; int ShaderStatus;    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glGetShaderiv(ID, GL_COMPILE_STATUS, &amp;amp;ShaderStatus); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Check the compile status   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; if (ShaderStatus != GL_TRUE) {    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; printf(&amp;quot;Error: Failed to compile GLSL program\n&amp;quot;);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; int Len = 1024;    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; char Error[1024];    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; glGetShaderInfoLog(ID, 1024, &amp;amp;Len, Error);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; printf(Error);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; exit (-1);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; }    &lt;br /&gt;} &lt;/p&gt;
&lt;p&gt;// Initializes the application data   &lt;br /&gt;int Init(void)     &lt;br /&gt;{    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Very basic ambient+diffusion model    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; A vertex shader doesn&amp;#8217;t really shade shapes.&amp;#160; It&amp;#8217;s more like a transformation of the points that make up the shape.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; //&amp;#160;&amp;#160; I WILL HAVE MORE TO SAY ABOUT THIS AT JAYGEIGER.COM LATER    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; const char VertexShader[] = &amp;quot;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; attribute vec3 Position;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; attribute vec3 Normal;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; uniform mat4 Proj;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; uniform mat4 Model;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; varying vec3 NormVec;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; varying vec3 LighVec;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; void main(void)&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; {&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; vec4 Pos = Model * vec4(Position, 1.0); \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; gl_Position = Proj * Pos;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; NormVec&amp;#160;&amp;#160;&amp;#160;&amp;#160; = (Model * vec4(Normal,0.0)).xyz;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; LighVec&amp;#160;&amp;#160;&amp;#160;&amp;#160; = -Pos.xyz;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; }&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; &amp;quot;; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; const char FragmentShader[] = &amp;quot;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; varying highp vec3 NormVec;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; varying highp vec3 LighVec;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; void main(void)&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; {&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; lowp vec3 Color = vec3(1.0, 0.0, 0.0);&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; mediump vec3 Norm&amp;#160; = normalize(NormVec);&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; mediump vec3 Light = normalize(LighVec);&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; mediump float Diffuse = dot(Norm, Light);&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; gl_FragColor = vec4(Color * (max(Diffuse, 0.0) * 0.6 + 0.4), 0.5);&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; }&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; \    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; &amp;quot;; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Create 2 shader programs   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Shader[0] = glCreateShader(GL_VERTEX_SHADER);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Shader[1] = glCreateShader(GL_FRAGMENT_SHADER); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; LoadShader((char *)VertexShader, Shader[0]);   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; LoadShader((char *)FragmentShader, Shader[1]); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Create the prorgam and attach the shaders &amp;amp; attributes   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Program&amp;#160;&amp;#160; = glCreateProgram(); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; glAttachShader(Program, Shader[0]);   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glAttachShader(Program, Shader[1]); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; glBindAttribLocation(Program, 0, &amp;quot;Position&amp;quot;);   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glBindAttribLocation(Program, 1, &amp;quot;Normal&amp;quot;); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Link   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glLinkProgram(Program); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Validate our work thus far   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; int ShaderStatus;    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glGetProgramiv(Program, GL_LINK_STATUS, &amp;amp;ShaderStatus); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; if (ShaderStatus != GL_TRUE) {   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; printf(&amp;quot;Error: Failed to link GLSL program\n&amp;quot;);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; int Len = 1024;    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; char Error[1024];    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; glGetProgramInfoLog(Program, 1024, &amp;amp;Len, Error);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; printf(Error);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; exit(-1);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; } &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; glValidateProgram(Program); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; glGetProgramiv(Program, GL_VALIDATE_STATUS, &amp;amp;ShaderStatus); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; if (ShaderStatus != GL_TRUE) {   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; printf(&amp;quot;Error: Failed to validate GLSL program\n&amp;quot;);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; exit(-1);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; } &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Enable the program   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glUseProgram&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; (Program);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glEnableVertexAttribArray&amp;#160;&amp;#160; (0);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glEnableVertexAttribArray&amp;#160;&amp;#160; (1); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Setup the Projection matrix   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Persp(Proj, 70.0f, 0.1f, 200.0f); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Retrieve our uniforms   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; iProj&amp;#160;&amp;#160; = glGetUniformLocation(Program, &amp;quot;Proj&amp;quot;);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; iModel&amp;#160; = glGetUniformLocation(Program, &amp;quot;Model&amp;quot;); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Basic GL setup   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glClearColor&amp;#160;&amp;#160;&amp;#160; (0.0, 0.0, 0.0, 1.0);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glEnable&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; (GL_CULL_FACE);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glCullFace&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; (GL_BACK); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; return GL_TRUE;   &lt;br /&gt;} &lt;/p&gt;
&lt;p&gt;// Main-loop workhorse function for displaying the object   &lt;br /&gt;void Display(void)    &lt;br /&gt;{    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Clear the screen    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glClear (GL_COLOR_BUFFER_BIT); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; float Model[4][4]; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; memset(Model, 0, sizeof(Model)); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Setup the Proj so that the object rotates around the Y axis   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // We&amp;#8217;ll also translate it appropriately to Display    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Model[0][0] = cosf(Angle);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Model[1][1] = 1.0f;    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Model[2][0] = sinf(Angle);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Model[0][2] = -sinf(Angle);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Model[2][2] = cos(Angle);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Model[3][2] = -1.0f;&amp;#160;&amp;#160; &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Model[3][3] = 1.0f; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Constantly rotate the object as a function of time   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; This simply creates an increasing angle of rotation.&amp;#160; SDL keeps increasing (or ticking).    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Angle = SDL_GetTicks() * 0.001f; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Vertex information   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; This is a simple triangle.&amp;#160; The coordinates are in X,Y,Z space.&amp;#160; Notice that Z is always the same.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; float PtData[][3] = {    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; {-0.5, 0.5, 0.5},    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; {0.5, 0.5, 0.5},    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; {-0.5, -0.5, 0.5},    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; }; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Face information   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; Each Shape has a face    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; unsigned int FaceData[][3] = {    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; {0,1,2}, //1 side of the Triangle    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; {2,1,0} //The other side of the triangle.&amp;#160; If you comment this line out and rerun then the triangle will invisible on one side.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; }; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Draw the icosahedron   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; This draws the triangle (not the icosahedron)    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glUseProgram&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; (Program);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glUniformMatrix4fv&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; (iProj, 1, false, (const float *)&amp;amp;Proj[0][0]);    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glUniformMatrix4fv&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; (iModel, 1, false, (const float *)&amp;amp;Model[0][0]); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; glVertexAttribPointer&amp;#160;&amp;#160; (0, 3, GL_FLOAT, 0, 0, &amp;amp;PtData[0][0]);   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; glVertexAttribPointer&amp;#160;&amp;#160; (1, 3, GL_FLOAT, GL_TRUE, 0, &amp;amp;PtData[0][0]); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; glDrawElements&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; (GL_TRIANGLES, sizeof(FaceData) / sizeof(int), GL_UNSIGNED_INT, &amp;amp;FaceData[0][0]);   &lt;br /&gt;} &lt;/p&gt;
&lt;p&gt;int main(int argc, char** argv)   &lt;br /&gt;{    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Initialize the SDL library with the Video subsystem    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; SDL stands for Simple DirectMedia Layer.&amp;#160; SDL can be thought of the programs that allow OpenGL ES to render the images to your screen.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; SDL_Init(SDL_INIT_VIDEO | SDL_INIT_NOPARACHUTE); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Tell it to use OpenGL version 2.0   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; To be more correct, this is OpenGL ES 2.0    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, 2); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Set the video mode to full screen with OpenGL-ES support   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; This is the full screen resolution of the Palm Pre.&amp;#160; I am not sure how things will be handled for multiple resolutions ie&amp;#8230; Pixi.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; Surface = SDL_SetVideoMode(320, 480, 0, SDL_OPENGL); &lt;/p&gt;
&lt;p&gt;#if WIN32   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Load the desktop OpenGL-ES emulation library    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; _dgles_load_library(NULL, proc_loader);    &lt;br /&gt;#endif &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Application specific Initialize of data structures &amp;amp; GL states   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; if (Init() == false)    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; return -1; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Event descriptor   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; The Event variable will hold and SDL Event. Some examples of these kind of events are KeyDown &amp;#8211; A specifc key press, Mouse clicks, etc&amp;#8230;    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; SDL_Event Event; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; do {   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Render our scene    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; This method will rotate the 3D Object and display it.&amp;#160; More detail in the above function.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Display(); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Make it visible on the screen   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; /* Geiger &amp;#8211; Graphics Programs always use 2 buffers.&amp;#160; The screen always shows one of these buffers.&amp;#160; The inactive one gets painted with all the pixels for the next frame.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; The Display() method always draws to the inactive buffer.&amp;#160; After Display() is done drawing all the pixels the inactive buffer becomes the active and vice versa.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Why does it do this?&amp;#160; If it drew the pixels right to the screen things would &amp;quot;Flicker&amp;quot;.&amp;#160; It would be kind of like a cartoonist drawing a picture really fast, showing it for a second    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; then turning to a blank page and drawing the next one.&amp;#160; Double Buffering hides the flicker by &amp;quot;Flipping&amp;quot; to the next page.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; */    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; SDL_GL_SwapBuffers(); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Process the events   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; SDL_PollEvent will remove the next SDL Event and save it to the &amp;quot;Event&amp;quot; variable.&amp;#160; This will keep happening, and the &amp;quot;Display&amp;quot; function will keep rotating and redisplaying the object.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; while (SDL_PollEvent(&amp;amp;Event)) {    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; switch (Event.type) {    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // List of keys that have been pressed    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; case SDL_KEYDOWN:    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Geiger &amp;#8211; If the last event was the pressing of the &amp;quot;Escape Key&amp;quot;, then break out of the &amp;quot;Do While&amp;quot; loop.    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; switch (Event.key.keysym.sym) {    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; // Escape forces us to quit the app    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; case SDLK_ESCAPE:    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Event.type = SDL_QUIT;    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; break; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; default:   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; break;    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; }    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; break; &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; default:   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; break;    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; }    &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; } &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; } while (Event.type != SDL_QUIT);   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; // We exit anytime we get a request to quit the app &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; // Cleanup   &lt;br /&gt;&amp;#160;&amp;#160;&amp;#160; SDL_Quit(); &lt;/p&gt;
&lt;p&gt;&amp;#160;&amp;#160;&amp;#160; return 0;   &lt;br /&gt;}&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/jaygeiger/~4/FfH1-dGacmk" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://www.jaygeiger.com/index.php/2010/06/16/palms-webos-pdk/#comments" thr:count="2" />
		<link rel="replies" type="application/atom+xml" href="http://www.jaygeiger.com/index.php/2010/06/16/palms-webos-pdk/feed/atom/" thr:count="2" />
		<thr:total>2</thr:total>
	<feedburner:origLink>http://www.jaygeiger.com/index.php/2010/06/16/palms-webos-pdk/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>Jason Geiger</name>
						<uri>http://www.jaygeiger.com</uri>
					</author>
		<title type="html"><![CDATA[Hydra Network Let&#8217;s Me Down]]></title>
		<link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/jaygeiger/~3/bdlGUxlLNI4/" />
		<id>http://www.jaygeiger.com/index.php/2010/05/18/hydra-network-lets-me-down/</id>
		<updated>2010-05-18T14:07:05Z</updated>
		<published>2010-05-18T14:07:05Z</published>
		<category scheme="http://www.jaygeiger.com" term="Uncategorized" />		<summary type="html"><![CDATA[Is Hydra having growing pains?&#160; As of late, I’ve been pretty dismayed to run any of their campaigns because it’s such a pain to do so.
Every time I see an offer that may appeal to me, I am greeted with
Approval Required to Run this Campaign       Please contact your affiliate [...]]]></summary>
		<content type="html" xml:base="http://www.jaygeiger.com/index.php/2010/05/18/hydra-network-lets-me-down/">&lt;p&gt;Is &lt;a href="http://www.hydranetwork.com"&gt;Hydra&lt;/a&gt; having growing pains?&amp;#160; As of late, I’ve been pretty dismayed to run any of their campaigns because it’s such a pain to do so.&lt;/p&gt;
&lt;p&gt;Every time I see an offer that may appeal to me, I am greeted with&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;&lt;strong&gt;Approval Required to Run this Campaign       &lt;br /&gt;Please contact your affiliate manager to run this campaign. Once approved, you will see creatives in this area of the page.&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Ok, that’s a big inconvenience, but I’ll need to see the landing page before I know if I want to apply for access.&lt;/p&gt;
&lt;p&gt;Wait, &lt;strong&gt;THERE IS NO LANDING PAGE LINK&lt;/strong&gt;.    &lt;/p&gt;
&lt;p&gt;So…&lt;/p&gt;
&lt;p&gt;1. Most campaigns are locked down.   &lt;br /&gt;2. There’s no “Apply for this Campaign” button.    &lt;br /&gt;3. You don’t know if you want to apply because you can’t see the landing page.&lt;/p&gt;
&lt;p&gt;Before Hydra’s “2.0 Update” I really enjoyed them.&amp;#160; They used to be my go to affiliate marketing place every time I had a marketing idea.&amp;#160; Now, I’m off to Market Leverage, PeerFly and Amped Media.&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/jaygeiger/~4/bdlGUxlLNI4" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://www.jaygeiger.com/index.php/2010/05/18/hydra-network-lets-me-down/#comments" thr:count="0" />
		<link rel="replies" type="application/atom+xml" href="http://www.jaygeiger.com/index.php/2010/05/18/hydra-network-lets-me-down/feed/atom/" thr:count="0" />
		<thr:total>0</thr:total>
	<feedburner:origLink>http://www.jaygeiger.com/index.php/2010/05/18/hydra-network-lets-me-down/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>Jason Geiger</name>
						<uri>http://www.jaygeiger.com</uri>
					</author>
		<title type="html"><![CDATA[My Simon Says App]]></title>
		<link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/jaygeiger/~3/k2xDBGepp88/" />
		<id>http://www.jaygeiger.com/index.php/2010/05/12/my-simon-says-app/</id>
		<updated>2010-05-12T17:31:44Z</updated>
		<published>2010-05-12T17:31:44Z</published>
		<category scheme="http://www.jaygeiger.com" term="Uncategorized" />		<summary type="html"><![CDATA[&#160;
Look to the right!&#160; You’ll notice that I have a Hot “Palm” app.
I created an app for the Palm Pre called “As I Say”.&#160; I was going to sell it, but thought I would stand a better chance at very minor money if I entered it into Palm’s Hot App contest.
As of writing this post, [...]]]></summary>
		<content type="html" xml:base="http://www.jaygeiger.com/index.php/2010/05/12/my-simon-says-app/">&lt;p&gt;&amp;#160;
&lt;p&gt;Look to the right!&amp;#160; You’ll notice that I have a Hot “Palm” app.&lt;/p&gt;
&lt;p&gt;I created an app for the Palm Pre called “As I Say”.&amp;#160; I was going to sell it, but thought I would stand a better chance at very minor money if I entered it into Palm’s Hot App contest.&lt;/p&gt;
&lt;p&gt;As of writing this post, I am the 240th most popular free app in Palm’s App Catalog.&amp;#160; I need to get to 221.&lt;/p&gt;
&lt;p&gt;I am a constantly&amp;#160; a mere 1,000 downloads away.&amp;#160; Right now I have 16,379 downloads but need 17,386 to get into the money.&amp;#160; So if you have a Palm Pre or Palm Pixi, click on the link to the right to download the app FOR FREE.&lt;/p&gt;
&lt;/p&gt;
&lt;p&gt; &lt;a href="http://www.jaygeiger.com/wp-content/uploads/2010/05/image.png" target="_blank"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; margin-left: 0px; border-left-width: 0px; margin-right: 0px" title="image" border="0" alt="image" align="left" src="http://www.jaygeiger.com/wp-content/uploads/2010/05/image_thumb.png" width="270" height="545" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/jaygeiger/~4/k2xDBGepp88" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://www.jaygeiger.com/index.php/2010/05/12/my-simon-says-app/#comments" thr:count="0" />
		<link rel="replies" type="application/atom+xml" href="http://www.jaygeiger.com/index.php/2010/05/12/my-simon-says-app/feed/atom/" thr:count="0" />
		<thr:total>0</thr:total>
	<feedburner:origLink>http://www.jaygeiger.com/index.php/2010/05/12/my-simon-says-app/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>Jason Geiger</name>
						<uri>http://www.jaygeiger.com</uri>
					</author>
		<title type="html"><![CDATA[Resident Evil 5 for PC &#8211; Review]]></title>
		<link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/jaygeiger/~3/7RrY70tFasQ/" />
		<id>http://www.jaygeiger.com/index.php/2010/03/23/resident-evil-5-for-pc-review/</id>
		<updated>2010-03-23T17:37:56Z</updated>
		<published>2010-03-23T17:37:56Z</published>
		<category scheme="http://www.jaygeiger.com" term="Uncategorized" /><category scheme="http://www.jaygeiger.com" term="Video Games" />		<summary type="html"><![CDATA[This past “lazy” Sunday I decided to download a game.&#160; It was raining outside, so instead of going down to the local GameSpot I signed onto Steam (www.steampowered.com) and perused the newer games available.
I ended up buying newest incarnation of Resident Evil for $49.99.&#160; Here is my “professional” opinion.
Installation
Download took about an hour (about the [...]]]></summary>
		<content type="html" xml:base="http://www.jaygeiger.com/index.php/2010/03/23/resident-evil-5-for-pc-review/">&lt;p&gt;&lt;img style="margin: 0px 10px 10px 0px; display: inline" title="Resident Evil 5" alt="Resident Evil 5" align="left" src="http://cdn.steampowered.com/v/gfx/apps/21690/header.jpg?t=1257522318" /&gt;This past “lazy” Sunday I decided to download a game.&amp;#160; It was raining outside, so instead of going down to the local GameSpot I signed onto Steam (&lt;a href="http://www.steampowered.com"&gt;www.steampowered.com&lt;/a&gt;) and perused the newer games available.&lt;/p&gt;
&lt;p&gt;I ended up buying newest incarnation of Resident Evil for $49.99.&amp;#160; Here is my “professional” opinion.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Installation&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Download took about an hour (about the same time to get to the store and back) and maybe saved me a few bucks in gas and a few bucks in sales tax.&lt;/p&gt;
&lt;p&gt;Normally installation is not a problem for Steam Games.&amp;#160; RE 5 however had some issues.&amp;#160; For some reason, on first run, every game from Steam needs to reinstall Direct X 9.&amp;#160; Ok, whatever go ahead computer.&amp;#160; Next It had to install some Games for Windows “Live” software.&amp;#160; After a few minutes I got an option to run Resident Evil in DirectX 9 mode or DirectX 10 mode.&lt;/p&gt;
&lt;p&gt;First I tried 9 and the launch just closed.&amp;#160; I double clicked the icon again and “Live” tried installing again.&amp;#160; Eventually I found that neither DX9 or DX10 would work.&amp;#160; It seems “Live” couldn’t install successfully.&amp;#160; I restarted my new Windows 7 machine and launched 1 more time.&amp;#160; SUCCESS!&lt;/p&gt;
&lt;p&gt;After loading Resident Evil told me that I needed to sign into Games for Windows Live in order to save my game.&amp;#160; For that you need to “Create a Free Profile” or login to an existing one.&amp;#160; I already had one, just had to re-guess my password.&amp;#160; “I’m IN”! …or so I thought.&lt;/p&gt;
&lt;p&gt;SETBACK!&amp;#160; Windows Live (or whatever it’s called) had to update in order to use the game.&amp;#160; BS!&lt;/p&gt;
&lt;p&gt;After finally updating and closing down the game (it didn’t auto-restart or even tell me I had to relaunch) I started the game and logged back in 1 more time.&amp;#160; Finally, It’s Play Time!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;The Game&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The graphics are great!&amp;#160; The controls are a little lacking though.&amp;#160; Your character is constantly in the bottom left of the screen unless you are targeting something.&amp;#160; This makes it more likely to that baddies will sneak up on that side.&lt;/p&gt;
&lt;p&gt;The beginning of the game should show you more of the controls, like how to move stuff in your inventory, how to change weapons quickly, how to melee (Very Important to save ammo, slice a box with your knife, don’t shoot it) and other things.&amp;#160; Even with it’s flaws, the graphics pull you right in and make game play very fun!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;The Story&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The story moved along too quickly for my liking.&amp;#160; I prefer “Realistic” horror.&amp;#160; Having everybody turn into creatures all at once ruins the suspense.&amp;#160; The suspense needs to start slow and build!&amp;#160; Crazed eyed villagers with machetes should be enough to get you going.&amp;#160; You don’t need to show all the parasites coming out of exploding heads right off the bat.&amp;#160; Phase those in.&amp;#160; You’d get a lot more shock value.&lt;/p&gt;
&lt;p&gt;I like that the story line is a tiny different, this time taking place in Africa.&amp;#160; The scenery is great, but I think it’s time to restart the original zombie faction in a Racoon City remake!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;The Grade&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;All in all I give 4 out 5 G’s.&amp;#160; (a G is the Geiger Measurement Scale, the more G’s the better)&lt;/p&gt;
&lt;p&gt;The stunning visuals addicting game play will keep you stoked.&amp;#160; Also, the supporting female character is quite… nice.&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/jaygeiger/~4/7RrY70tFasQ" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://www.jaygeiger.com/index.php/2010/03/23/resident-evil-5-for-pc-review/#comments" thr:count="0" />
		<link rel="replies" type="application/atom+xml" href="http://www.jaygeiger.com/index.php/2010/03/23/resident-evil-5-for-pc-review/feed/atom/" thr:count="0" />
		<thr:total>0</thr:total>
	<feedburner:origLink>http://www.jaygeiger.com/index.php/2010/03/23/resident-evil-5-for-pc-review/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>Jason Geiger</name>
						<uri>http://www.jaygeiger.com</uri>
					</author>
		<title type="html"><![CDATA[Apple is the Most Closed Minded Company]]></title>
		<link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/jaygeiger/~3/q2R7rhlShYk/" />
		<id>http://www.jaygeiger.com/index.php/2010/01/26/apple-is-the-most-closed-minded-company/</id>
		<updated>2010-01-26T14:33:54Z</updated>
		<published>2010-01-26T14:31:19Z</published>
		<category scheme="http://www.jaygeiger.com" term="Uncategorized" />		<summary type="html"><![CDATA[I have a great idea for a phone app.&#160; Since I’m a Palm WebOS guy I sent a message out of to the good people at Palm.
While I wait, I decided to look at Apple’s SDK.&#160; First you have to register.&#160; “No problem” I thought.&#160; Then I saw this.
 
Click to enlarge the image.&#160; Basically, [...]]]></summary>
		<content type="html" xml:base="http://www.jaygeiger.com/index.php/2010/01/26/apple-is-the-most-closed-minded-company/">&lt;p&gt;I have a great idea for a phone app.&amp;#160; Since I’m a Palm WebOS guy I sent a message out of to the good people at Palm.&lt;/p&gt;
&lt;p&gt;While I wait, I decided to look at Apple’s SDK.&amp;#160; First you have to register.&amp;#160; “No problem” I thought.&amp;#160; Then I saw this.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://www.jaygeiger.com/wp-content/uploads/2010/01/dumbapple.png" target="_blank"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="Dumb Apple" border="0" alt="Dumb Apple" src="http://www.jaygeiger.com/wp-content/uploads/2010/01/dumbapple_thumb.png" width="364" height="118" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;Click to enlarge the image.&amp;#160; Basically, to make iPhone apps you need a Mac.&amp;#160; WTF?&amp;#160; That doesn’t sound like “Cloud Computing” to me.&amp;#160; This has got to be one of the most &lt;strong&gt;closed minded&lt;/strong&gt; decisions ever.&lt;/p&gt;
&lt;p&gt;No I know some fanboys are going to say that “IT’S TOO MUCH RESOURCES TO MAKE MULTIPLE DEVELOPMENT ENVIRONMENTS”.&amp;#160; Good point FanBoys!!!!&lt;/p&gt;
&lt;p&gt;However, Palm which is much smaller (at the moment) than Apple’s iPhone division offers us this…&lt;/p&gt;
&lt;p&gt;&lt;a href="http://www.jaygeiger.com/wp-content/uploads/2010/01/image.png"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="Palm Webos SDK Environments" border="0" alt="Palm Webos SDK Environments" src="http://www.jaygeiger.com/wp-content/uploads/2010/01/image_thumb.png" width="364" height="180" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;Click to enlarge (or feel free to squint).&amp;#160; The webOS development kit runs on &lt;strong&gt;Mac&lt;/strong&gt;.&amp;#160; It also runs on &lt;strong&gt;Windows&lt;/strong&gt; and EVEN &lt;strong&gt;Linux&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Also, even thought the Palm phones are still starting out (and now available on Sprint, Verizon and soon to be AT&amp;amp;T) I am nixing my iPhone App ideas because of Apple’s closed mindedness.&lt;/p&gt;
&lt;p&gt;Apple wants us to “&lt;strong&gt;Think Different&lt;/strong&gt;”?&amp;#160;&amp;#160; &lt;br /&gt;We’d rather “&lt;strong&gt;Think Freely&lt;/strong&gt;”.&lt;/p&gt;
&lt;p&gt;&amp;#160;&lt;/p&gt;
&lt;p&gt;&amp;#160;&lt;/p&gt;
&lt;p&gt;EDIT: btw, you don’t even need a phone to develop for the webOS (Palm Pre and Palm Pixi)   &lt;br /&gt;If you care, check it out at &lt;a href="http://developer.palm.com" target="_blank"&gt;Developer.Palm.com&lt;/a&gt;&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/jaygeiger/~4/q2R7rhlShYk" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://www.jaygeiger.com/index.php/2010/01/26/apple-is-the-most-closed-minded-company/#comments" thr:count="2" />
		<link rel="replies" type="application/atom+xml" href="http://www.jaygeiger.com/index.php/2010/01/26/apple-is-the-most-closed-minded-company/feed/atom/" thr:count="2" />
		<thr:total>2</thr:total>
	<feedburner:origLink>http://www.jaygeiger.com/index.php/2010/01/26/apple-is-the-most-closed-minded-company/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>Jason Geiger</name>
						<uri>http://www.jaygeiger.com</uri>
					</author>
		<title type="html"><![CDATA[BAC Calculator &#8211; In the Palm App Catalog]]></title>
		<link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/jaygeiger/~3/JLyvQroChOA/" />
		<id>http://www.jaygeiger.com/index.php/2009/11/09/bac-calculator-in-the-palm-app-catalog/</id>
		<updated>2009-11-09T14:43:15Z</updated>
		<published>2009-11-09T14:43:15Z</published>
		<category scheme="http://www.jaygeiger.com" term="Uncategorized" />		<summary type="html"><![CDATA[We made it!&#160; The BAC Calculator for Palm WebOS (Palm Pre and Palm Pixi) is now live and available to you for only $.99!
We are not sure what we are under non-disclosure to say because the Developer Program is still in Beta.&#160; Also because it is just in Beta, it is not yet fully cooked [...]]]></summary>
		<content type="html" xml:base="http://www.jaygeiger.com/index.php/2009/11/09/bac-calculator-in-the-palm-app-catalog/">&lt;p&gt;We made it!&amp;#160; The &lt;a href="http://developer.palm.com/appredirect/?packageid=com.jaygeiger.baccalc&amp;amp;applicationid=353" target="_blank"&gt;BAC Calculator&lt;/a&gt; for Palm WebOS (Palm Pre and Palm Pixi) is now live and available to you for only $.99!&lt;/p&gt;
&lt;p&gt;We are not sure what we are under non-disclosure to say because the Developer Program is still in Beta.&amp;#160; Also because it is just in Beta, it is not yet fully cooked yet.&lt;/p&gt;
&lt;p&gt;However, our experience is VERY positive.&amp;#160; Especially since this is Beta!&lt;/p&gt;
&lt;p&gt;We have never developed apps for other phones and we are not sure we ever will.&amp;#160; However I doubt that it is as easy to talk to somebody as it is with Palm.&amp;#160; Also the review process is CONCISE!&amp;#160; The BAC Calculator, meant for fun only, got rejected once.&amp;#160; With the rejection I was supplied a bullet point list of reasons.&amp;#160; ALL that I agreed with! (and was a little shocked that I forgot them in the first place)&lt;/p&gt;
&lt;p&gt;Kudos to the Palm Development team so far!&amp;#160; Keep it up!!!&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/jaygeiger/~4/JLyvQroChOA" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://www.jaygeiger.com/index.php/2009/11/09/bac-calculator-in-the-palm-app-catalog/#comments" thr:count="1" />
		<link rel="replies" type="application/atom+xml" href="http://www.jaygeiger.com/index.php/2009/11/09/bac-calculator-in-the-palm-app-catalog/feed/atom/" thr:count="1" />
		<thr:total>1</thr:total>
	<feedburner:origLink>http://www.jaygeiger.com/index.php/2009/11/09/bac-calculator-in-the-palm-app-catalog/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>Jason Geiger</name>
						<uri>http://www.jaygeiger.com</uri>
					</author>
		<title type="html"><![CDATA[Debug WebOS Application]]></title>
		<link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/jaygeiger/~3/vjTH7m4pTdE/" />
		<id>http://www.jaygeiger.com/index.php/2009/10/07/debug-webos-application/</id>
		<updated>2009-10-29T14:10:09Z</updated>
		<published>2009-10-07T13:54:05Z</published>
		<category scheme="http://www.jaygeiger.com" term="Uncategorized" />		<summary type="html"><![CDATA[My posts have been lax.  NO APOLOGIES!  I’ve been spending my free time developing my Cell Stalker app for the Palm Pre and Palm Pixi. (Palm WebOS)
Compared to developing a .Net appliction, developing for WebOS is a real pain.  It is Javascript and HTML however, there is no “Intellisense”, “Easy Debugging”, “Syntax Checker” or “Accurate [...]]]></summary>
		<content type="html" xml:base="http://www.jaygeiger.com/index.php/2009/10/07/debug-webos-application/">&lt;p&gt;My posts have been lax.  NO APOLOGIES!  I’ve been spending my free time developing my Cell Stalker app for the Palm Pre and Palm Pixi. (Palm WebOS)&lt;/p&gt;
&lt;p&gt;Compared to developing a .Net appliction, developing for WebOS is a real pain.  It is Javascript and HTML however, there is no “Intellisense”, “Easy Debugging”, “Syntax Checker” or “Accurate Warning/Errors”.&lt;/p&gt;
&lt;p&gt;With that being said, let me show you how to debug and WebOS and how to find WebOS Javascript Errors.&lt;/p&gt;
&lt;p&gt;As always you first need…&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href="http://java.com/en/"&gt;Java 6&lt;/a&gt; (if you don’t already)&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.virtualbox.org/"&gt;Sun VirtualBox&lt;/a&gt; (This is where you run the Palm phone emulator on your PC)&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developer.palm.com/index.php?option=com_content&amp;amp;view=article&amp;amp;id=1788"&gt;WebOS SDK&lt;/a&gt; (This is basically the virtual machine, application packager and a few more tools)&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;I don’t use Eclipse to program, I’ve been using Komodo Edit.  I like Komodo Edit because it’s MUCH smaller and quicker than Eclipse.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href="http://www.activestate.com/komodo_edit/"&gt;Komodo Edit&lt;/a&gt; (The IDE, the place where you type your code)&lt;/li&gt;
&lt;li&gt;&lt;a href="http://webos.templarian.com/komodo/"&gt;Komodo Edit WebOS tools&lt;/a&gt; (This allows you to compile and run your program with the push of a button.  It also has “Some” syntax checking.)&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;After ALL of that is installed, you create a new application.  You should be able to run it in the emulator and get a test screen.  Now if you want to debug it, or catch errors you need to use a tool called Putty that got installed with the SDK.&lt;/p&gt;
&lt;p&gt;When your WebOS emulator/virtual machine is running go to a command prompt (or click Start –&amp;gt; Run) and run the following…&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;putty -ssh -P 5522 localhost -l root -pw &amp;#8221;&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;This connects you to the linux machine running on your virtual phone.  Then to debug javascript or trap javascript errors type…&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;debug&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;To add a point where you want to stop the program type…&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;break /var/usr/palm/applications/com.YourCompany.YourAppName/app/assistants/first-assistant.js:100&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;This will pause the application named “com.YourCompany.YourAppName” when it hits line 100 in the “first-assistant.js” file.&lt;/p&gt;
&lt;p&gt;When it’s paused you can type things like…&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;print Variable1&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;This will print the contents of Variable1 (Up to the first 80 characters, if somebody knows how to print more, comment here, I’d love to know).&lt;/p&gt;
&lt;p&gt;You can then type&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;c&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;To continue.&lt;/p&gt;
&lt;p&gt;or…&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;clear 1&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;To clear the first break point.&lt;/p&gt;
&lt;p&gt;Type&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;finish&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;to finish off the application.&lt;/p&gt;
&lt;p&gt;I couldn’t find an example of how to debug out there, so I hope this helps at least one person.&lt;/p&gt;
&lt;p&gt;For more debugging commands check out &lt;a href="http://developer.palm.com/index.php?option=com_content&amp;amp;view=article&amp;amp;id=1672"&gt;Palm Debugger Commands&lt;/a&gt;.&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/jaygeiger/~4/vjTH7m4pTdE" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://www.jaygeiger.com/index.php/2009/10/07/debug-webos-application/#comments" thr:count="10" />
		<link rel="replies" type="application/atom+xml" href="http://www.jaygeiger.com/index.php/2009/10/07/debug-webos-application/feed/atom/" thr:count="10" />
		<thr:total>10</thr:total>
	<feedburner:origLink>http://www.jaygeiger.com/index.php/2009/10/07/debug-webos-application/</feedburner:origLink></entry>
	</feed>
