<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: obj2opengl: convert obj 3D models to arrays compatible with iPhone OpenGL ES</title>
	<atom:link href="http://www.heikobehrens.net/2009/08/27/obj2opengl/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/</link>
	<description>11:60 p.m. - my plain thoughts</description>
	<lastBuildDate>Fri, 30 Jul 2010 18:50:09 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Chris</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-9057</link>
		<dc:creator>Chris</dc:creator>
		<pubDate>Fri, 30 Jul 2010 18:50:09 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-9057</guid>
		<description>Quick question.

What software do you all use to render the 3D images?

Thanks</description>
		<content:encoded><![CDATA[<p>Quick question.</p>
<p>What software do you all use to render the 3D images?</p>
<p>Thanks</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Shashank</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-8180</link>
		<dc:creator>Shashank</dc:creator>
		<pubDate>Tue, 18 May 2010 06:53:53 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-8180</guid>
		<description>Works like a charm..Thank you so much Heiko !!!</description>
		<content:encoded><![CDATA[<p>Works like a charm..Thank you so much Heiko !!!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Esther</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-7849</link>
		<dc:creator>Esther</dc:creator>
		<pubDate>Wed, 28 Apr 2010 18:36:45 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-7849</guid>
		<description>Hi everyone!

First of all I want to apologize because of my bad English. Thank you so much for this amazing tool, it is being very useful for me.
I have the same problem than Robert. It works but wthout texture, and I am working with the banana example and GLGravity project to be sure that I am not making mistakes, and nothing. Could you help me to solve that please? Thank you Heiko.</description>
		<content:encoded><![CDATA[<p>Hi everyone!</p>
<p>First of all I want to apologize because of my bad English. Thank you so much for this amazing tool, it is being very useful for me.<br />
I have the same problem than Robert. It works but wthout texture, and I am working with the banana example and GLGravity project to be sure that I am not making mistakes, and nothing. Could you help me to solve that please? Thank you Heiko.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-7506</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Wed, 07 Apr 2010 16:08:18 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-7506</guid>
		<description>Hey Carlos,

unfortunately, the script currently neither supports materials nor separate groups of faces. Both would be required to colorize your models. Sorry for that.

If you come up with a workaround or a patched version of the script, feel free to post it here!</description>
		<content:encoded><![CDATA[<p>Hey Carlos,</p>
<p>unfortunately, the script currently neither supports materials nor separate groups of faces. Both would be required to colorize your models. Sorry for that.</p>
<p>If you come up with a workaround or a patched version of the script, feel free to post it here!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Carlos Pinto</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-7441</link>
		<dc:creator>Carlos Pinto</dc:creator>
		<pubDate>Fri, 02 Apr 2010 15:05:33 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-7441</guid>
		<description>Hello Heiko,

I was just writing back again in regards to my last post, to give you more specifics as to what would be useful to include in the script.

The .obj file that was produced for my 3D model contains color shading information such as the one below since I did not use an actual texture:

g pSphere1
usemtl initialShadingGroup
f 1//1 2//2 12//3 11//4
f 2//5 3//6 13//7 12//8
f 3//9 4//10 14//11 13//12
f 4//13 5//14 15//15 14//16
f 5//17 6//18 16//19 15//20
......

So I was wondering if there would be any way to parse these values into the equivalent in OpenGL ES that the function glColorPointer(..) would be able to take. 

Thanks,

Carlos.</description>
		<content:encoded><![CDATA[<p>Hello Heiko,</p>
<p>I was just writing back again in regards to my last post, to give you more specifics as to what would be useful to include in the script.</p>
<p>The .obj file that was produced for my 3D model contains color shading information such as the one below since I did not use an actual texture:</p>
<p>g pSphere1<br />
usemtl initialShadingGroup<br />
f 1//1 2//2 12//3 11//4<br />
f 2//5 3//6 13//7 12//8<br />
f 3//9 4//10 14//11 13//12<br />
f 4//13 5//14 15//15 14//16<br />
f 5//17 6//18 16//19 15//20<br />
&#8230;&#8230;</p>
<p>So I was wondering if there would be any way to parse these values into the equivalent in OpenGL ES that the function glColorPointer(..) would be able to take. </p>
<p>Thanks,</p>
<p>Carlos.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Carlos Pinto</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-7420</link>
		<dc:creator>Carlos Pinto</dc:creator>
		<pubDate>Thu, 01 Apr 2010 03:40:06 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-7420</guid>
		<description>Hey Heiko, I just wanted to say thanks for the very useful script, makes porting 3D models for iPhone development a breeze. Good Job. 

I do have one question though. If an object (3D object that is) was painted with some colors instead of using textures, is there any way to obtain the color data in the obj file and then be parsed to the C style arrays like your script does it? 
The color array that I am talking about would be used in the function: glColorPointer(...) of the OpenGL ES API&#039;s.

Please let me know either by email or directly in this blog.

Thanks in advance.</description>
		<content:encoded><![CDATA[<p>Hey Heiko, I just wanted to say thanks for the very useful script, makes porting 3D models for iPhone development a breeze. Good Job. </p>
<p>I do have one question though. If an object (3D object that is) was painted with some colors instead of using textures, is there any way to obtain the color data in the obj file and then be parsed to the C style arrays like your script does it?<br />
The color array that I am talking about would be used in the function: glColorPointer(&#8230;) of the OpenGL ES API&#8217;s.</p>
<p>Please let me know either by email or directly in this blog.</p>
<p>Thanks in advance.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: robert</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-7273</link>
		<dc:creator>robert</dc:creator>
		<pubDate>Sun, 21 Mar 2010 06:41:38 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-7273</guid>
		<description>hi again. thanks fot quick respond
It works! but without texture. I am using the banana example. I resolved the problem by enabling following:
       //enable vertex coordinate array when glDrawArrays is called
        glEnableClientState(GL_VERTEX_ARRAY);
	//enable normal array when glDrawArrays is called
	glEnableClientState(GL_NORMAL_ARRAY);
	//enable texture coordinate array when glDrawArrays is called
	glEnableClientState(GL_TEXTURE_COORD_ARRAY);
Do Yoy have any ide how to fix the texture?
Cheers!</description>
		<content:encoded><![CDATA[<p>hi again. thanks fot quick respond<br />
It works! but without texture. I am using the banana example. I resolved the problem by enabling following:<br />
       //enable vertex coordinate array when glDrawArrays is called<br />
        glEnableClientState(GL_VERTEX_ARRAY);<br />
	//enable normal array when glDrawArrays is called<br />
	glEnableClientState(GL_NORMAL_ARRAY);<br />
	//enable texture coordinate array when glDrawArrays is called<br />
	glEnableClientState(GL_TEXTURE_COORD_ARRAY);<br />
Do Yoy have any ide how to fix the texture?<br />
Cheers!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-7272</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Sun, 21 Mar 2010 04:19:09 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-7272</guid>
		<description>Hey Robert,

great to see that someone even tries to use this for VS! Unfortunately, I cannot assist you without further information. Did you try to narrow this down already? How does a simple header file (e.g. the examples) behave? Are you able to visualize anything loaded via glVertexPointer? How do these arrays differ from those generated by obj2opengl?</description>
		<content:encoded><![CDATA[<p>Hey Robert,</p>
<p>great to see that someone even tries to use this for VS! Unfortunately, I cannot assist you without further information. Did you try to narrow this down already? How does a simple header file (e.g. the examples) behave? Are you able to visualize anything loaded via glVertexPointer? How do these arrays differ from those generated by obj2opengl?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: robert</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-7270</link>
		<dc:creator>robert</dc:creator>
		<pubDate>Sun, 21 Mar 2010 01:06:10 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-7270</guid>
		<description>hi there.
I am trying to implement your project into opengl under windows xp using visual studio 2008. I convert the .obj file, paste the code to draw the model and I include the .h file to my project. Project compiles but the model does not come up on-screen. Is there any way to make it working? Cheers!</description>
		<content:encoded><![CDATA[<p>hi there.<br />
I am trying to implement your project into opengl under windows xp using visual studio 2008. I convert the .obj file, paste the code to draw the model and I include the .h file to my project. Project compiles but the model does not come up on-screen. Is there any way to make it working? Cheers!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ty</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-7199</link>
		<dc:creator>Ty</dc:creator>
		<pubDate>Tue, 16 Mar 2010 19:10:07 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-7199</guid>
		<description>Heiko et all,

Last night at about 4AM, I think I figured this &#039;bug&#039; out. Turns out it is not a &#039;bug&#039; at all, and has nothing to do with the obj2opengl script.  

If you manipulate a mesh in Silo and try to export it as a .obj, Silo will export it as Quads, not Triangles.  Before you export your model from Silo, you must select it and choose &quot;Modify&quot; -&gt; &quot;Triangulate&quot; or [Control + Shift + T].  Once you do this, you can export your model from Silo, run obj2opengl and the iphone will render the .h properly.

Thanks to Jeff LaMarche for confirming the solution. Hope this post saves someone a couple days.

Thanks again Heiko, for such a great little script.

best wishes to all,
ty</description>
		<content:encoded><![CDATA[<p>Heiko et all,</p>
<p>Last night at about 4AM, I think I figured this &#8216;bug&#8217; out. Turns out it is not a &#8216;bug&#8217; at all, and has nothing to do with the obj2opengl script.  </p>
<p>If you manipulate a mesh in Silo and try to export it as a .obj, Silo will export it as Quads, not Triangles.  Before you export your model from Silo, you must select it and choose &#8220;Modify&#8221; -&gt; &#8220;Triangulate&#8221; or [Control + Shift + T].  Once you do this, you can export your model from Silo, run obj2opengl and the iphone will render the .h properly.</p>
<p>Thanks to Jeff LaMarche for confirming the solution. Hope this post saves someone a couple days.</p>
<p>Thanks again Heiko, for such a great little script.</p>
<p>best wishes to all,<br />
ty</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ty</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-7176</link>
		<dc:creator>Ty</dc:creator>
		<pubDate>Mon, 15 Mar 2010 17:44:09 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-7176</guid>
		<description>Heiko,

Thanks for getting back to me. Great little utility!  I am really interested in figuring this out and appreciate you taking the time to look at it. I posted both a cube and sphere here:   http://gist.github.com/333101

Both models have the same visual artifact.  

cube.obj:  http://gist.github.com/raw/333101/b24c888179d871c4355cbd54a21ad616b4afa3d1/cube.obj

sphere.obj:  http://gist.github.com/raw/333101/e2b4dc69df4f25bd0196817fc3f5d7ee5aec2b9a/sphere.obj

I have tried dozens of models, all have the same issue.  For what it is worth, Blender can&#039;t open Silo .obj files, so perhaps Silo went off standard.

Anyway, thanks again....  Wow, &quot;Blender makes my head heart.&quot; Apparently Blender makes me funny too.</description>
		<content:encoded><![CDATA[<p>Heiko,</p>
<p>Thanks for getting back to me. Great little utility!  I am really interested in figuring this out and appreciate you taking the time to look at it. I posted both a cube and sphere here:   <a href="http://gist.github.com/333101" rel="nofollow">http://gist.github.com/333101</a></p>
<p>Both models have the same visual artifact.  </p>
<p>cube.obj:  <a href="http://gist.github.com/raw/333101/b24c888179d871c4355cbd54a21ad616b4afa3d1/cube.obj" rel="nofollow">http://gist.github.com/raw/333101/b24c888179d871c4355cbd54a21ad616b4afa3d1/cube.obj</a></p>
<p>sphere.obj:  <a href="http://gist.github.com/raw/333101/e2b4dc69df4f25bd0196817fc3f5d7ee5aec2b9a/sphere.obj" rel="nofollow">http://gist.github.com/raw/333101/e2b4dc69df4f25bd0196817fc3f5d7ee5aec2b9a/sphere.obj</a></p>
<p>I have tried dozens of models, all have the same issue.  For what it is worth, Blender can&#8217;t open Silo .obj files, so perhaps Silo went off standard.</p>
<p>Anyway, thanks again&#8230;.  Wow, &#8220;Blender makes my head heart.&#8221; Apparently Blender makes me funny too.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-7171</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Mon, 15 Mar 2010 10:31:08 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-7171</guid>
		<description>Hey Lisa, Hey Ty,

please provide the .obj file of the most simple version with errors you are converting from (e.g. a cube). I think, the format of the .obj file is slighty different from what the script expects.</description>
		<content:encoded><![CDATA[<p>Hey Lisa, Hey Ty,</p>
<p>please provide the .obj file of the most simple version with errors you are converting from (e.g. a cube). I think, the format of the .obj file is slighty different from what the script expects.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ty</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-7165</link>
		<dc:creator>Ty</dc:creator>
		<pubDate>Mon, 15 Mar 2010 08:56:47 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-7165</guid>
		<description>Heiko,

I seem to be experiencing some problems converting Silo 2 .obj files to .h files with obj2opengl. The conversion appears to work and I am able to load the .h file on an iphone using GLGravity. But the iphone only seems to render the model partially, in a triangle pattern as indicated here: http://imgur.com/fGN8f.jpg

I found another script, for blender, which enabled me to export solid models:
http://iphonedevelopment.blogspot.com/2009/07/improved-blender-export.html

But I would prefer to model in Silo. Blender makes my head heart. Any idea what&#039;s going on here?</description>
		<content:encoded><![CDATA[<p>Heiko,</p>
<p>I seem to be experiencing some problems converting Silo 2 .obj files to .h files with obj2opengl. The conversion appears to work and I am able to load the .h file on an iphone using GLGravity. But the iphone only seems to render the model partially, in a triangle pattern as indicated here: <a href="http://imgur.com/fGN8f.jpg" rel="nofollow">http://imgur.com/fGN8f.jpg</a></p>
<p>I found another script, for blender, which enabled me to export solid models:<br />
<a href="http://iphonedevelopment.blogspot.com/2009/07/improved-blender-export.html" rel="nofollow">http://iphonedevelopment.blogspot.com/2009/07/improved-blender-export.html</a></p>
<p>But I would prefer to model in Silo. Blender makes my head heart. Any idea what&#8217;s going on here?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sergey Kopanev</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-6748</link>
		<dc:creator>Sergey Kopanev</dc:creator>
		<pubDate>Sat, 27 Feb 2010 17:33:20 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-6748</guid>
		<description>Heiko,

What is &quot;Center&quot; that script saying ?
Center: 

I have two models and i have no success draw it correctly in space.
I&#039;ve tried glTranslatef to &quot;Center&quot; and glScalef  by &quot;Scale by&quot; before rendering - but my models located in space at the wrong coordinates.

How can I draw 2 models on their coordinates same as in 3dMax?

thanks,</description>
		<content:encoded><![CDATA[<p>Heiko,</p>
<p>What is &#8220;Center&#8221; that script saying ?<br />
Center: </p>
<p>I have two models and i have no success draw it correctly in space.<br />
I&#8217;ve tried glTranslatef to &#8220;Center&#8221; and glScalef  by &#8220;Scale by&#8221; before rendering &#8211; but my models located in space at the wrong coordinates.</p>
<p>How can I draw 2 models on their coordinates same as in 3dMax?</p>
<p>thanks,</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sergey Kopanev</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-6747</link>
		<dc:creator>Sergey Kopanev</dc:creator>
		<pubDate>Sat, 27 Feb 2010 16:42:58 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-6747</guid>
		<description>Heiko,

Thanks for answer. Do you have a plan make script working with some textures ?</description>
		<content:encoded><![CDATA[<p>Heiko,</p>
<p>Thanks for answer. Do you have a plan make script working with some textures ?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Lisa Wilkinson</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-6665</link>
		<dc:creator>Lisa Wilkinson</dc:creator>
		<pubDate>Tue, 23 Feb 2010 21:19:24 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-6665</guid>
		<description>Here&#039;s another example.
Maya: http://imgur.com/PVYqa.png
iPhone: http://imgur.com/FGcGs.png
Texture: http://imgur.com/ivt5J.png

and my code to draw it:

	glPushMatrix();
	glBindTexture(GL_TEXTURE_2D, textures[13]);
	glVertexPointer(3, GL_FLOAT, 0, cubeVerts);
	glTexCoordPointer(2, GL_FLOAT, 0, cubeTexCoords);
	glDrawArrays(GL_TRIANGLES, 0, cubeNumVerts);
	glPopMatrix();</description>
		<content:encoded><![CDATA[<p>Here&#8217;s another example.<br />
Maya: <a href="http://imgur.com/PVYqa.png" rel="nofollow">http://imgur.com/PVYqa.png</a><br />
iPhone: <a href="http://imgur.com/FGcGs.png" rel="nofollow">http://imgur.com/FGcGs.png</a><br />
Texture: <a href="http://imgur.com/ivt5J.png" rel="nofollow">http://imgur.com/ivt5J.png</a></p>
<p>and my code to draw it:</p>
<p>	glPushMatrix();<br />
	glBindTexture(GL_TEXTURE_2D, textures[13]);<br />
	glVertexPointer(3, GL_FLOAT, 0, cubeVerts);<br />
	glTexCoordPointer(2, GL_FLOAT, 0, cubeTexCoords);<br />
	glDrawArrays(GL_TRIANGLES, 0, cubeNumVerts);<br />
	glPopMatrix();</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-6652</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Tue, 23 Feb 2010 08:31:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-6652</guid>
		<description>Hey Lisa, can you reproduce this error with a simpler example (e.g. a cube)? I am afraid the .obj file itself has some unexpected mappings.</description>
		<content:encoded><![CDATA[<p>Hey Lisa, can you reproduce this error with a simpler example (e.g. a cube)? I am afraid the .obj file itself has some unexpected mappings.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-6651</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Tue, 23 Feb 2010 08:31:12 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-6651</guid>
		<description>Sergey, currently the script merges all groups into a single object and can handle only one texture.</description>
		<content:encoded><![CDATA[<p>Sergey, currently the script merges all groups into a single object and can handle only one texture.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Lisa Wilkinson</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-6647</link>
		<dc:creator>Lisa Wilkinson</dc:creator>
		<pubDate>Tue, 23 Feb 2010 03:11:53 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-6647</guid>
		<description>Hi, 

I have been having problems getting the UV texture coordinates to work.
Here is a screen shot of what it looks like in Maya: http://imgur.com/z2Ica.png
and what it looks like on the iPhone: http://imgur.com/A1alQ.png

Does anyone know how this could be fixed?
Thanks in advance for any help</description>
		<content:encoded><![CDATA[<p>Hi, </p>
<p>I have been having problems getting the UV texture coordinates to work.<br />
Here is a screen shot of what it looks like in Maya: <a href="http://imgur.com/z2Ica.png" rel="nofollow">http://imgur.com/z2Ica.png</a><br />
and what it looks like on the iPhone: <a href="http://imgur.com/A1alQ.png" rel="nofollow">http://imgur.com/A1alQ.png</a></p>
<p>Does anyone know how this could be fixed?<br />
Thanks in advance for any help</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sergey Kopanev</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-6232</link>
		<dc:creator>Sergey Kopanev</dc:creator>
		<pubDate>Thu, 04 Feb 2010 18:00:32 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-6232</guid>
		<description>Hello, all

But what if the object 2 or more textures?
thanks.</description>
		<content:encoded><![CDATA[<p>Hello, all</p>
<p>But what if the object 2 or more textures?<br />
thanks.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mirza Garibovic</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-6226</link>
		<dc:creator>Mirza Garibovic</dc:creator>
		<pubDate>Thu, 04 Feb 2010 14:29:16 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-6226</guid>
		<description>Hi Heiko,

I made a small change to this so that it interleaves the vertex data in one contiguous array, according to http://developer.apple.com/iphone/library/documentation/3DDrawing/Conceptual/OpenGLES_ProgrammingGuide/Performance/Performance.html

obj2opengl.pl:
http://docs.google.com/leaf?id=0B3MMs33O0RexZDUzZDU1ZjItMjRlZi00OGQwLThkOTktN2RkYWM4MzNiMDM3&amp;hl=en

Example output (cube.h):
http://docs.google.com/leaf?id=0B3MMs33O0RexMGY0YTI0NjAtY2E1MC00MGYwLWIxM2EtMGRmYzExMzE0ODUz&amp;hl=en

Example draw (note the required stride constant):

  glVertexPointer(3, GL_FLOAT, cubeStride, cubeVerts);

  glNormalPointer(GL_FLOAT, cubeStride, cubeNormals);

  glDrawArrays(GL_TRIANGLES, 0, cubeNumVerts);</description>
		<content:encoded><![CDATA[<p>Hi Heiko,</p>
<p>I made a small change to this so that it interleaves the vertex data in one contiguous array, according to <a href="http://developer.apple.com/iphone/library/documentation/3DDrawing/Conceptual/OpenGLES_ProgrammingGuide/Performance/Performance.html" rel="nofollow">http://developer.apple.com/iphone/library/documentation/3DDrawing/Conceptual/OpenGLES_ProgrammingGuide/Performance/Performance.html</a></p>
<p>obj2opengl.pl:<br />
<a href="http://docs.google.com/leaf?id=0B3MMs33O0RexZDUzZDU1ZjItMjRlZi00OGQwLThkOTktN2RkYWM4MzNiMDM3&amp;hl=en" rel="nofollow">http://docs.google.com/leaf?id=0B3MMs33O0RexZDUzZDU1ZjItMjRlZi00OGQwLThkOTktN2RkYWM4MzNiMDM3&amp;hl=en</a></p>
<p>Example output (cube.h):<br />
<a href="http://docs.google.com/leaf?id=0B3MMs33O0RexMGY0YTI0NjAtY2E1MC00MGYwLWIxM2EtMGRmYzExMzE0ODUz&amp;hl=en" rel="nofollow">http://docs.google.com/leaf?id=0B3MMs33O0RexMGY0YTI0NjAtY2E1MC00MGYwLWIxM2EtMGRmYzExMzE0ODUz&amp;hl=en</a></p>
<p>Example draw (note the required stride constant):</p>
<p>  glVertexPointer(3, GL_FLOAT, cubeStride, cubeVerts);</p>
<p>  glNormalPointer(GL_FLOAT, cubeStride, cubeNormals);</p>
<p>  glDrawArrays(GL_TRIANGLES, 0, cubeNumVerts);</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sergey Kopanev</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-6202</link>
		<dc:creator>Sergey Kopanev</dc:creator>
		<pubDate>Wed, 03 Feb 2010 13:31:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-6202</guid>
		<description>Thanks! Very nice script.</description>
		<content:encoded><![CDATA[<p>Thanks! Very nice script.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kjaerjakcajk</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-5832</link>
		<dc:creator>Kjaerjakcajk</dc:creator>
		<pubDate>Mon, 18 Jan 2010 01:07:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-5832</guid>
		<description>Thanks for this, very helpful.</description>
		<content:encoded><![CDATA[<p>Thanks for this, very helpful.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: iphone4</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-5441</link>
		<dc:creator>iphone4</dc:creator>
		<pubDate>Mon, 04 Jan 2010 18:17:39 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-5441</guid>
		<description>There is a typo:
	print OUTFILE &quot;glTexCoordPointer(2, GL_FLOAT, 0, &quot;.$object.&quot;TexCoords);\n&quot;
		if $numTextrue &gt; 0;

should be:
	print OUTFILE &quot;glTexCoordPointer(2, GL_FLOAT, 0, &quot;.$object.&quot;TexCoords);\n&quot;
		if $numTexture &gt; 0;

It stops glTexCoordPointer appearing in comment.

Nice script though!</description>
		<content:encoded><![CDATA[<p>There is a typo:<br />
	print OUTFILE &#8220;glTexCoordPointer(2, GL_FLOAT, 0, &#8220;.$object.&#8221;TexCoords);\n&#8221;<br />
		if $numTextrue &gt; 0;</p>
<p>should be:<br />
	print OUTFILE &#8220;glTexCoordPointer(2, GL_FLOAT, 0, &#8220;.$object.&#8221;TexCoords);\n&#8221;<br />
		if $numTexture &gt; 0;</p>
<p>It stops glTexCoordPointer appearing in comment.</p>
<p>Nice script though!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Blender &#62;&#62; OpenGL ES &#8211; Any Hope? - OOgtech.org</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-5009</link>
		<dc:creator>Blender &#62;&#62; OpenGL ES &#8211; Any Hope? - OOgtech.org</dc:creator>
		<pubDate>Sat, 19 Dec 2009 14:04:41 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-5009</guid>
		<description>[...] obj2OpenGL &#8211; Heiko Behrens&#8217; PERL script to convert *.obj (Alias Wavefront) to opengl. This is attractive because it loads data that OpenGL can render directly. Also it&#8217;s been designed with the iPhone/iTouch in mind. If I use this I still would like to write an automation to export my models from the blender file format to obj. It would be really nice if I could &#8216;press a button&#8217; and get all my 3D files updated at once. I guess I should try this first&#8230; [...]</description>
		<content:encoded><![CDATA[<p>[...] obj2OpenGL &#8211; Heiko Behrens&#8217; PERL script to convert *.obj (Alias Wavefront) to opengl. This is attractive because it loads data that OpenGL can render directly. Also it&#8217;s been designed with the iPhone/iTouch in mind. If I use this I still would like to write an automation to export my models from the blender file format to obj. It would be really nice if I could &#8216;press a button&#8217; and get all my 3D files updated at once. I guess I should try this first&#8230; [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Niklas</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4712</link>
		<dc:creator>Niklas</dc:creator>
		<pubDate>Mon, 07 Dec 2009 14:22:44 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4712</guid>
		<description>Hm, seem that I had forgotten to put in glMatrixMode(GL_MODELVIEW) after I set up the projection view port... So the light now seems to work...</description>
		<content:encoded><![CDATA[<p>Hm, seem that I had forgotten to put in glMatrixMode(GL_MODELVIEW) after I set up the projection view port&#8230; So the light now seems to work&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4710</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Mon, 07 Dec 2009 13:06:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4710</guid>
		<description>Hey Niklas,

your are absolutely right. The normals will be transformed (even scaled) according to your matrix. If you are an iPhone developer have a look at the GLGravity example to learn about lights and OpenGL. Also, this tutorial seems to introduce lights and normals quite extensively: http://www.falloutsoftware.com/tutorials/gl/gl8.htm</description>
		<content:encoded><![CDATA[<p>Hey Niklas,</p>
<p>your are absolutely right. The normals will be transformed (even scaled) according to your matrix. If you are an iPhone developer have a look at the GLGravity example to learn about lights and OpenGL. Also, this tutorial seems to introduce lights and normals quite extensively: <a href="http://www.falloutsoftware.com/tutorials/gl/gl8.htm" rel="nofollow">http://www.falloutsoftware.com/tutorials/gl/gl8.htm</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Niklas</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4709</link>
		<dc:creator>Niklas</dc:creator>
		<pubDate>Mon, 07 Dec 2009 12:29:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4709</guid>
		<description>Hey, great script.

I&#039;m a complete newbie when it comes to open gl, so pardon my ignorance.

But when I create a simple object with normals, and render it all, as per your examples. If I then place a light above the object, and then rotate say a cube. It seems to me that as the cube rotates around the axis, the backside of it becomes dark when facing the light, rather then the side facing away form the light becomes dark.

Do I need to recalculate or transform the normals for the light to be correct?

I&#039;m doing a push and pop call, then translate the cube I&#039;m drawing. I would have thought that the face facing the light would become lighter. Isn&#039;t that what the normals are for?</description>
		<content:encoded><![CDATA[<p>Hey, great script.</p>
<p>I&#8217;m a complete newbie when it comes to open gl, so pardon my ignorance.</p>
<p>But when I create a simple object with normals, and render it all, as per your examples. If I then place a light above the object, and then rotate say a cube. It seems to me that as the cube rotates around the axis, the backside of it becomes dark when facing the light, rather then the side facing away form the light becomes dark.</p>
<p>Do I need to recalculate or transform the normals for the light to be correct?</p>
<p>I&#8217;m doing a push and pop call, then translate the cube I&#8217;m drawing. I would have thought that the face facing the light would become lighter. Isn&#8217;t that what the normals are for?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4383</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Mon, 23 Nov 2009 11:24:47 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4383</guid>
		<description>Hey Jace,

could you please provide your obj file so I can try to reproduce your error?</description>
		<content:encoded><![CDATA[<p>Hey Jace,</p>
<p>could you please provide your obj file so I can try to reproduce your error?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jace</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4370</link>
		<dc:creator>Jace</dc:creator>
		<pubDate>Sun, 22 Nov 2009 18:57:03 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4370</guid>
		<description>Hi,

I wondered if you could help me. I created an object in Carrara 6 pro and exported to wavefont obj file. I ran your script and I got &quot;Illegal division by zero at ./obj2opengl.pl line 294&quot; I checked this and it seemed to be related to scale, so i specified -noScale and it appeared to work. However upon further inspection the header file was in fact invalid and contained nothing like the expected format, instead just a copy of the original obj file. I&#039;m new to all of this, so forgive my ignorance but do you have any idea what I&#039;m doing wrong?

Thanks in advance for any help

Regards</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p>I wondered if you could help me. I created an object in Carrara 6 pro and exported to wavefont obj file. I ran your script and I got &#8220;Illegal division by zero at ./obj2opengl.pl line 294&#8243; I checked this and it seemed to be related to scale, so i specified -noScale and it appeared to work. However upon further inspection the header file was in fact invalid and contained nothing like the expected format, instead just a copy of the original obj file. I&#8217;m new to all of this, so forgive my ignorance but do you have any idea what I&#8217;m doing wrong?</p>
<p>Thanks in advance for any help</p>
<p>Regards</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4274</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Tue, 17 Nov 2009 15:33:09 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4274</guid>
		<description>Ryan, you can easily iterate over the verts array and collect for each dimension the min and max values. But, adding this to the output of the script would be helpful, too. Thanks for your suggestion.</description>
		<content:encoded><![CDATA[<p>Ryan, you can easily iterate over the verts array and collect for each dimension the min and max values. But, adding this to the output of the script would be helpful, too. Thanks for your suggestion.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ryan</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4273</link>
		<dc:creator>Ryan</dc:creator>
		<pubDate>Tue, 17 Nov 2009 15:11:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4273</guid>
		<description>Does anyone know of a good way to create simple bounding boxes using these .h files? Something as simple as creating a bounding rectangle using max and min z, x, and y values would do.

Thanks!</description>
		<content:encoded><![CDATA[<p>Does anyone know of a good way to create simple bounding boxes using these .h files? Something as simple as creating a bounding rectangle using max and min z, x, and y values would do.</p>
<p>Thanks!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4201</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Fri, 13 Nov 2009 11:36:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4201</guid>
		<description>Hey Ivan,
did you apply execution rights to the script? http://osxfaq.com/tutorials/learningcenter/UnixTutorials/ShellScripting1/index.ws#asss</description>
		<content:encoded><![CDATA[<p>Hey Ivan,<br />
did you apply execution rights to the script? <a href="http://osxfaq.com/tutorials/learningcenter/UnixTutorials/ShellScripting1/index.ws#asss" rel="nofollow">http://osxfaq.com/tutorials/learningcenter/UnixTutorials/ShellScripting1/index.ws#asss</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ivan</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4200</link>
		<dc:creator>Ivan</dc:creator>
		<pubDate>Fri, 13 Nov 2009 11:32:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4200</guid>
		<description>Sorry, I&#039;m noob in mac, i have the next error:

-bash: ./obj2opengl.pl: Permission denied</description>
		<content:encoded><![CDATA[<p>Sorry, I&#8217;m noob in mac, i have the next error:</p>
<p>-bash: ./obj2opengl.pl: Permission denied</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tgr</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4178</link>
		<dc:creator>tgr</dc:creator>
		<pubDate>Thu, 12 Nov 2009 09:35:46 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4178</guid>
		<description>textrue should be texture in http://www.heikobehrens.net/wp-content/uploads/2009/08/obj2opengl.txt line 451.</description>
		<content:encoded><![CDATA[<p>textrue should be texture in <a href="http://www.heikobehrens.net/wp-content/uploads/2009/08/obj2opengl.txt" rel="nofollow">http://www.heikobehrens.net/wp-content/uploads/2009/08/obj2opengl.txt</a> line 451.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4033</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Wed, 04 Nov 2009 07:51:38 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4033</guid>
		<description>&lt;code&gt;./obj2opengl.pl cube.txt -s 4&lt;/code&gt;
does the trick. try
&lt;code&gt;./obj2opengl.pl --help&lt;/code&gt;
to learn more about the options.</description>
		<content:encoded><![CDATA[<p><code>./obj2opengl.pl cube.txt -s 4</code><br />
does the trick. try<br />
<code>./obj2opengl.pl --help</code><br />
to learn more about the options.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ryan</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-4030</link>
		<dc:creator>Ryan</dc:creator>
		<pubDate>Tue, 03 Nov 2009 16:55:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-4030</guid>
		<description>Great script! I&#039;m just wondering how to use scaling options from the command line?

Keep up the great work!

Ryan</description>
		<content:encoded><![CDATA[<p>Great script! I&#8217;m just wondering how to use scaling options from the command line?</p>
<p>Keep up the great work!</p>
<p>Ryan</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: fx61803</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3929</link>
		<dc:creator>fx61803</dc:creator>
		<pubDate>Fri, 23 Oct 2009 21:50:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3929</guid>
		<description>Hello!
thanks for the links, they&#039;ve been helpful
now, I couldn&#039;t make the texturing of your banana to work, but it seems it required a call to
glEnableClientState(GL_TEXTURE_COORD_ARRAY) after glTexCoordPointer(2, GL_FLOAT, 0, bananaTexCoords) to make it finally accept the texture
I do not know how generic this might be and if it&#039;s worth mentioning in generated header for example
thanks!
r.</description>
		<content:encoded><![CDATA[<p>Hello!<br />
thanks for the links, they&#8217;ve been helpful<br />
now, I couldn&#8217;t make the texturing of your banana to work, but it seems it required a call to<br />
glEnableClientState(GL_TEXTURE_COORD_ARRAY) after glTexCoordPointer(2, GL_FLOAT, 0, bananaTexCoords) to make it finally accept the texture<br />
I do not know how generic this might be and if it&#8217;s worth mentioning in generated header for example<br />
thanks!<br />
r.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3910</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Thu, 22 Oct 2009 08:07:12 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3910</guid>
		<description>Hey R,
I am not completely sure what you are asking for. If your obj contains texture coordinates you can bin them using glTexCoordPointer as you can see in the generated comment of your .h file.

Loading the corresponding image file is another story, though. If you are not familiar with OpenGL ES and texture mapping these links might be helpful:
http://iphonedevelopment.blogspot.com/2009/05/opengl-es-from-ground-up-part-6_25.html
http://web.me.com/smaurice/AppleCoder/iPhone_OpenGL/Entries/2009/4/1_OpenGL_ES_05_-_Texture_Mapping_Our_Square.html</description>
		<content:encoded><![CDATA[<p>Hey R,<br />
I am not completely sure what you are asking for. If your obj contains texture coordinates you can bin them using glTexCoordPointer as you can see in the generated comment of your .h file.</p>
<p>Loading the corresponding image file is another story, though. If you are not familiar with OpenGL ES and texture mapping these links might be helpful:<br />
<a href="http://iphonedevelopment.blogspot.com/2009/05/opengl-es-from-ground-up-part-6_25.html" rel="nofollow">http://iphonedevelopment.blogspot.com/2009/05/opengl-es-from-ground-up-part-6_25.html</a><br />
<a href="http://web.me.com/smaurice/AppleCoder/iPhone_OpenGL/Entries/2009/4/1_OpenGL_ES_05_-_Texture_Mapping_Our_Square.html" rel="nofollow">http://web.me.com/smaurice/AppleCoder/iPhone_OpenGL/Entries/2009/4/1_OpenGL_ES_05_-_Texture_Mapping_Our_Square.html</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: fx61803</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3908</link>
		<dc:creator>fx61803</dc:creator>
		<pubDate>Thu, 22 Oct 2009 02:46:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3908</guid>
		<description>mr. behrens,
thanks for the converter, works like a charm!
after initial obstacles where it was not able to generate correct header file caused by not having only triangles in the model I am now able to compile the model with xcode; brilliant!

/ the converter produces a weird bug when skipping number values and leaving only commas in the array definition when the model is not in expected format, I guess; however when I exported the same model with triangles only, it works perfectly / 

however, since I am a complete noob in this field I even don&#039;t know if something like this makes sense, but is it possible to automatically apply a corresponding texture to a model defined like this in xcode? if so - how ? - does there exist a corresponding apple tutorial/concept which can be easily adopted for this ?
thank you very much!
r.</description>
		<content:encoded><![CDATA[<p>mr. behrens,<br />
thanks for the converter, works like a charm!<br />
after initial obstacles where it was not able to generate correct header file caused by not having only triangles in the model I am now able to compile the model with xcode; brilliant!</p>
<p>/ the converter produces a weird bug when skipping number values and leaving only commas in the array definition when the model is not in expected format, I guess; however when I exported the same model with triangles only, it works perfectly / </p>
<p>however, since I am a complete noob in this field I even don&#8217;t know if something like this makes sense, but is it possible to automatically apply a corresponding texture to a model defined like this in xcode? if so &#8211; how ? &#8211; does there exist a corresponding apple tutorial/concept which can be easily adopted for this ?<br />
thank you very much!<br />
r.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3869</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Mon, 19 Oct 2009 15:09:38 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3869</guid>
		<description>Hey Alex, as stated in my comment http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3460 above I used the GLGravity sample from Apple to produce the screenshot. Unfortunately, I cannot repost this code since it is protected by law. Feel free to ask any questions that arise following the steps I described on that comment, though.</description>
		<content:encoded><![CDATA[<p>Hey Alex, as stated in my comment <a href="http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3460" rel="nofollow">http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3460</a> above I used the GLGravity sample from Apple to produce the screenshot. Unfortunately, I cannot repost this code since it is protected by law. Feel free to ask any questions that arise following the steps I described on that comment, though.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Alex</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3868</link>
		<dc:creator>Alex</dc:creator>
		<pubDate>Mon, 19 Oct 2009 14:27:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3868</guid>
		<description>Please, include full xcode project
i try create test app - but it not work</description>
		<content:encoded><![CDATA[<p>Please, include full xcode project<br />
i try create test app &#8211; but it not work</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3595</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Thu, 01 Oct 2009 14:06:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3595</guid>
		<description>Thank you for your suggestion, jason. I will implement this with the next iteration.</description>
		<content:encoded><![CDATA[<p>Thank you for your suggestion, jason. I will implement this with the next iteration.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: jason colburne</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3594</link>
		<dc:creator>jason colburne</dc:creator>
		<pubDate>Thu, 01 Oct 2009 14:04:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3594</guid>
		<description>this script should generate ansi c style comments (/* */) rather than c++ style to be more portable. just a suggestion =) trivial change</description>
		<content:encoded><![CDATA[<p>this script should generate ansi c style comments (/* */) rather than c++ style to be more portable. just a suggestion =) trivial change</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3460</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Thu, 24 Sep 2009 09:06:08 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3460</guid>
		<description>Hey okfp,

as a starting point, use the GLGravity sample from the dev center and add the banana.h to the project. Now, replace the #import &quot;teapot.h&quot; in AppController.m with the banana.h and build the project. You will find to areas with errors, replace these lines with the ones given on top of the banana.h. First, replace the whole loop after &quot;// Draw teapot&quot; with the single glDrawArrays statement. Second, set the vertex and normal pointer as stated in the comments of banana.h. That&#039;s it.

I am sure you will find some sample code to learn the handling of textures, too.</description>
		<content:encoded><![CDATA[<p>Hey okfp,</p>
<p>as a starting point, use the GLGravity sample from the dev center and add the banana.h to the project. Now, replace the #import &#8220;teapot.h&#8221; in AppController.m with the banana.h and build the project. You will find to areas with errors, replace these lines with the ones given on top of the banana.h. First, replace the whole loop after &#8220;// Draw teapot&#8221; with the single glDrawArrays statement. Second, set the vertex and normal pointer as stated in the comments of banana.h. That&#8217;s it.</p>
<p>I am sure you will find some sample code to learn the handling of textures, too.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: okfp</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3455</link>
		<dc:creator>okfp</dc:creator>
		<pubDate>Thu, 24 Sep 2009 00:07:26 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3455</guid>
		<description>Heiko,

really amazing script. But I was trying to use to render your example in iphone simulator Xcode project. I don&#039;t know where I failed but I didn&#039;t see the bananas on the screen. I was trying to adjust glOrthof thinking should be big enough to see it, but doesn&#039;t work. Could you please provide your sample Xcode project or how do you implent that?

Thanks</description>
		<content:encoded><![CDATA[<p>Heiko,</p>
<p>really amazing script. But I was trying to use to render your example in iphone simulator Xcode project. I don&#8217;t know where I failed but I didn&#8217;t see the bananas on the screen. I was trying to adjust glOrthof thinking should be big enough to see it, but doesn&#8217;t work. Could you please provide your sample Xcode project or how do you implent that?</p>
<p>Thanks</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3284</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Mon, 14 Sep 2009 09:16:24 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3284</guid>
		<description>Hey Dawit,

thank you for your comment. Your exported obj file partly contains faces with 4 vertices each. Currently, this script has these known limitations, though: &quot;This script expects and OBJ file consisting of vertices, texture coords and normals. Each face must contain exactly 3 vertices. The texture coords are two dimonsional.&quot;

Is it possible for you to export your model with triangles only?</description>
		<content:encoded><![CDATA[<p>Hey Dawit,</p>
<p>thank you for your comment. Your exported obj file partly contains faces with 4 vertices each. Currently, this script has these known limitations, though: &#8220;This script expects and OBJ file consisting of vertices, texture coords and normals. Each face must contain exactly 3 vertices. The texture coords are two dimonsional.&#8221;</p>
<p>Is it possible for you to export your model with triangles only?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dawit Thepchatree</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3280</link>
		<dc:creator>Dawit Thepchatree</dc:creator>
		<pubDate>Mon, 14 Sep 2009 04:59:59 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3280</guid>
		<description>Hey there Heiko,

I just came across this Perl script of yours (from dev forums), and it works great! I really like how you simplified things (very easy to use!) and made it cross-operational for many systems and platforms. :D

One gripe though: my Silo 2 exported OBJ file isn&#039;t showing up correctly for the iPhone OS. Some faces are gone. I think it has something to do with Silo 2&#039;s Triangulate function. Otherwise, when I deal with simpler models, it works fine. :)

Anyway, here&#039;s the OBJ file:
http://www.mediafire.com/?ykzyiwd2nde

Thanks.</description>
		<content:encoded><![CDATA[<p>Hey there Heiko,</p>
<p>I just came across this Perl script of yours (from dev forums), and it works great! I really like how you simplified things (very easy to use!) and made it cross-operational for many systems and platforms. <img src='http://www.heikobehrens.net/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<p>One gripe though: my Silo 2 exported OBJ file isn&#8217;t showing up correctly for the iPhone OS. Some faces are gone. I think it has something to do with Silo 2&#8217;s Triangulate function. Otherwise, when I deal with simpler models, it works fine. <img src='http://www.heikobehrens.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Anyway, here&#8217;s the OBJ file:<br />
<a href="http://www.mediafire.com/?ykzyiwd2nde" rel="nofollow">http://www.mediafire.com/?ykzyiwd2nde</a></p>
<p>Thanks.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dan Bliss</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3081</link>
		<dc:creator>Dan Bliss</dc:creator>
		<pubDate>Wed, 02 Sep 2009 15:34:44 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3081</guid>
		<description>I found out the UV coords are not assigned automatically in Blender. In editmode press the U key and select &quot;Sphere from View&quot;. The Perl script works great.</description>
		<content:encoded><![CDATA[<p>I found out the UV coords are not assigned automatically in Blender. In editmode press the U key and select &#8220;Sphere from View&#8221;. The Perl script works great.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Heiko Behrens</title>
		<link>http://www.heikobehrens.net/2009/08/27/obj2opengl/#comment-3074</link>
		<dc:creator>Heiko Behrens</dc:creator>
		<pubDate>Wed, 02 Sep 2009 04:46:53 +0000</pubDate>
		<guid isPermaLink="false">http://www.heikobehrens.net/?p=695#comment-3074</guid>
		<description>Hey Dan, could you please provide the OBJ file? I am going to look into this.</description>
		<content:encoded><![CDATA[<p>Hey Dan, could you please provide the OBJ file? I am going to look into this.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
