<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-31432920</id><updated>2011-10-24T22:09:38.411-07:00</updated><title type='text'>gp2x</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://pocketplayer.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/31432920/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://pocketplayer.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Krispy</name><uri>http://www.blogger.com/profile/12140908719342343593</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://2.bp.blogspot.com/-lvlMLPpS_ko/TqZEjvObqbI/AAAAAAAACTY/XLAaU4t5LTw/s1600/assets.github.com%25252Fimages%25252Fgravatars%25252Fgravatar-140.png'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>4</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-31432920.post-9178125446552625707</id><published>2007-12-22T20:27:00.000-08:00</published><updated>2007-12-22T20:30:16.738-08:00</updated><title type='text'></title><content type='html'>I'm back at it&lt;br /&gt;&lt;br /&gt;After a very long break I'm back at the GP2X - this time I want to hack the fuck out of the thing and make it do stuff like become a code editor for when I'm lazying on the couch and want to code (This happens often) - I'm going to try various ways of making the gp2x (F100 series - dont have a 200 series yet) do cool stuff. BTW: I'm an Ubuntu user now....&lt;br /&gt;&lt;br /&gt;Cheers&lt;br /&gt;&lt;br /&gt;I'm back&lt;br /&gt;Krispy&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/31432920-9178125446552625707?l=pocketplayer.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pocketplayer.blogspot.com/feeds/9178125446552625707/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=31432920&amp;postID=9178125446552625707' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/31432920/posts/default/9178125446552625707'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/31432920/posts/default/9178125446552625707'/><link rel='alternate' type='text/html' href='http://pocketplayer.blogspot.com/2007/12/im-back-at-it-after-very-long-break-im.html' title=''/><author><name>Krispy</name><uri>http://www.blogger.com/profile/12140908719342343593</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://2.bp.blogspot.com/-lvlMLPpS_ko/TqZEjvObqbI/AAAAAAAACTY/XLAaU4t5LTw/s1600/assets.github.com%25252Fimages%25252Fgravatars%25252Fgravatar-140.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-31432920.post-115374617653748804</id><published>2006-07-24T06:01:00.000-07:00</published><updated>2006-07-24T06:02:56.546-07:00</updated><title type='text'></title><content type='html'>Loading images in SDL could not be easier:&lt;br /&gt;&lt;br /&gt;&lt;p&gt;  &lt;code&gt;SDL_Surface *&lt;b&gt;IMG_Load&lt;/b&gt;(const char *&lt;var&gt;file&lt;/var&gt;)&lt;/code&gt; &lt;/p&gt;&lt;p&gt;  &lt;/p&gt;&lt;dl compact="compact"&gt;&lt;dt&gt;&lt;var&gt;file&lt;/var&gt; &lt;/dt&gt;&lt;dd&gt;Image file name to load a surface from. &lt;/dd&gt;&lt;/dl&gt; &lt;p&gt;  Load &lt;var&gt;file&lt;/var&gt; for use as an image in a new surface.  This actually calls &lt;code&gt;IMG_LoadTyped_RW&lt;/code&gt;, with the file extension used as the &lt;var&gt;type&lt;/var&gt; string. This can load all supported image files, including TGA as long as the filename ends with ".tga". It is best to call this outside of event loops, and rather keep the loaded images around until you are really done with them, as disk speed and image conversion to a surface is not &lt;i&gt;that&lt;/i&gt; speedy.  Don't forget to SDL_FreeSurface the returned surface pointer when you are through with it. &lt;/p&gt;&lt;p&gt;  &lt;b&gt;Returns&lt;/b&gt;: a pointer to the image as a new &lt;code&gt;SDL_Surface&lt;/code&gt;.  &lt;b&gt;NULL&lt;/b&gt; is returned on errors, such as no support built for the image, or a file reading error. &lt;/p&gt;   &lt;table&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt; &lt;/td&gt;&lt;td class="example"&gt;&lt;pre&gt;// load sample.png into image&lt;br /&gt;SDL_Surface *image;&lt;br /&gt;image=IMG_Load("sample.png");&lt;br /&gt;if(!image) {&lt;br /&gt;   printf("IMG_Load: %s\n", IMG_GetError());&lt;br /&gt;   // handle error&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; Check out&lt;a href="http://jcatki.no-ip.org/SDL_image/SDL_image_frame.html"&gt; http://jcatki.no-ip.org/SDL_image/SDL_image_frame.html&lt;/a&gt; for more great info&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/31432920-115374617653748804?l=pocketplayer.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pocketplayer.blogspot.com/feeds/115374617653748804/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=31432920&amp;postID=115374617653748804' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/31432920/posts/default/115374617653748804'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/31432920/posts/default/115374617653748804'/><link rel='alternate' type='text/html' href='http://pocketplayer.blogspot.com/2006/07/loading-images-in-sdl-could-not-be.html' title=''/><author><name>Krispy</name><uri>http://www.blogger.com/profile/12140908719342343593</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://2.bp.blogspot.com/-lvlMLPpS_ko/TqZEjvObqbI/AAAAAAAACTY/XLAaU4t5LTw/s1600/assets.github.com%25252Fimages%25252Fgravatars%25252Fgravatar-140.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-31432920.post-115371552516568230</id><published>2006-07-23T21:29:00.000-07:00</published><updated>2006-07-23T21:32:05.166-07:00</updated><title type='text'></title><content type='html'>This is a quick one:&lt;br /&gt;&lt;br /&gt;How do you add a timer delay to a game loop?&lt;br /&gt;&lt;br /&gt;Using SDL you do the following:&lt;br /&gt;   &lt;br /&gt;    #define GAME_LOOP_DELAY_MS 12&lt;br /&gt;&lt;br /&gt;    ...&lt;br /&gt;&lt;br /&gt;    while(LastTickCount + GAME_LOOP_DELAY_MS &gt; SDL_GetTicks()); &lt;br /&gt;    LastTickCount = SDL_GetTicks();&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This will work even on overclocked/underclocked hardware. Use it wisely.&lt;br /&gt;&lt;br /&gt;Cheers&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/31432920-115371552516568230?l=pocketplayer.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pocketplayer.blogspot.com/feeds/115371552516568230/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=31432920&amp;postID=115371552516568230' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/31432920/posts/default/115371552516568230'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/31432920/posts/default/115371552516568230'/><link rel='alternate' type='text/html' href='http://pocketplayer.blogspot.com/2006/07/this-is-quick-one-how-do-you-add-timer.html' title=''/><author><name>Krispy</name><uri>http://www.blogger.com/profile/12140908719342343593</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://2.bp.blogspot.com/-lvlMLPpS_ko/TqZEjvObqbI/AAAAAAAACTY/XLAaU4t5LTw/s1600/assets.github.com%25252Fimages%25252Fgravatars%25252Fgravatar-140.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-31432920.post-115344797887432675</id><published>2006-07-20T19:00:00.000-07:00</published><updated>2006-07-23T21:26:30.330-07:00</updated><title type='text'>Let the Games Begin....or at least compile....</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.blether.com/images/diary/gp2x.jpg"&gt;&lt;img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer; width: 320px;" src="http://www.blether.com/images/diary/gp2x.jpg" alt="" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;Hello All,&lt;br /&gt;&lt;br /&gt;Welcome to yet another of my word dumps. For those of you new to my writings I am a developer who likes to do different things and I tend to write about those things and see if anyone can "one up" me.&lt;br /&gt;&lt;br /&gt;This is the latest wordcast blog I have started and it will focus purly on the &lt;a href="http://www.gp2x.com"&gt;GP2X &lt;/a&gt;(really check the link if you dont know what it is). For the lazy clickers out there its a personal media system. It plays games, movies, mp3s, books etc. but its open source and very cool.&lt;br /&gt;&lt;br /&gt;Step 1 - Get the things that allow you to compile programs for the system:&lt;br /&gt;&lt;br /&gt;&lt;h2&gt; A (lazy person's guide): Prebuilt developer package  &lt;/h2&gt; &lt;p&gt;If you use Windows 2K or Windows XP and just want a quick set-up, you can use this section to get a minimum developer system: &lt;/p&gt;&lt;p&gt;Two options are available: &lt;/p&gt;&lt;p&gt;1. The Gamepark Holdings Software Developer's Kit available from Gamepark at &lt;a href="http://dev.gp2x.com/sdk/gp2xsdk_windows.zip" class="external free" title="http://dev.gp2x.com/sdk/gp2xsdk windows.zip" rel="nofollow"&gt;http://dev.gp2x.com/sdk/gp2xsdk_windows.zip&lt;/a&gt; &lt;/p&gt;&lt;p&gt;This kit includes the Bloodshed devC++ integrated development environment, GCC versions for both gp2x native and MS-Windows native executables, and copies of the Linux version 2.4.25 libraries. It will compile gp2x native code for executables using shared libraries in addition to the static library form. &lt;/p&gt;&lt;p&gt;2. The devkitGP2X described below. &lt;/p&gt; &lt;ul&gt;&lt;li&gt; Download: &lt;a href="http://archive.gp2x.de/cgi-bin/cfiles.cgi?0,0,0,0,14,1362" class="external text" title="http://archive.gp2x.de/cgi-bin/cfiles.cgi?0,0,0,0,14,1362" rel="nofollow"&gt;gp2x devpack (31.1MB)&lt;/a&gt;. Unzip the &lt;b&gt;devkitGP2X&lt;/b&gt; directory into your root directory. It contains the latest development libraries (hardware accelerated SDL, Allegro, etc). &lt;/li&gt;&lt;li&gt; If you chose a development directory other than &lt;b&gt;\devkitGP2X&lt;/b&gt;, you will need to correct the paths in &lt;b&gt;bin\arm-linux-sdl-config&lt;/b&gt; and &lt;b&gt;demo\Makefile&lt;/b&gt;. &lt;/li&gt;&lt;li&gt; Add the bin directories to your path. Click on Start-&gt;Settings-&gt;Control Panel, open System-&gt;Advanced-&gt;Environmnet Variables, select PATH and add &lt;i&gt;C:\devkitGP2X\bin;C:\devkitGP2X\minsys\bin;&lt;/i&gt; to your path. &lt;/li&gt;&lt;li&gt; This set-up includes devkitGP2X (cross compiler tools), &lt;a href="http://wiki.gp2x.org/wiki/SDL" title="SDL"&gt;SDL&lt;/a&gt; (library), MinSys (make and GNU commands).  It does not include a debugger or a Windows compiler. &lt;/li&gt;&lt;li&gt; To test your setup, run a &lt;a href="http://wiki.gp2x.org/wiki/Demo_Program" title="Demo Program"&gt;Demo Program&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;Krispy Note: DONT FUCK WITH THE SUGESTED PATH!!! If you do then you will have problems. Trust me I spent 3 days trying to get stuff to compile and it turned out to be the dam directories. Also make sure you dont have devkitXXX installed where XXX is any other gba or arm dev kit. Unistall that devkit if you have it on your system.&lt;br /&gt;&lt;br /&gt;Step 2 - Use good tools&lt;br /&gt;&lt;br /&gt;Now, there is a tool that comes with the sdk (C:\GP2XSDK\devcpp.exe :: on windows [if you put it somewhere else then your on your own]) this is actually a decent IDE and its already set up for development of GP2X games. Its great to play with when you are waiting for your GP2X to arrive in the mail. But its editor is too frustrating for me so I setup Eclipse 3.2 (Callisto)  to be my ide of choice for GP2X development.&lt;br /&gt;&lt;br /&gt;Krispy Note: If you can't get the DevC++ ide to compile your code or even the code that it auto generates then you did something wrong when you unzipped the sdk and gpx files. DO IT AGAIN and put them in the correct directories ( mine are: C:\GP2XSDK and C:\devkitGP2X ) also make sure your path has the correct info: ( C:\GP2XSDK\bin;C:\devkitGP2X\bin;C:\cygwin\bin; ) I have cygwin installed so that my compiled programs actually run in windows. If you dont have the cygwin dlls in your runtime dirs then you should install cygwin.&lt;br /&gt;&lt;br /&gt;3. Setting up eclipse:&lt;br /&gt;&lt;br /&gt;Here is the correct output from DevC++ when compiling and running:&lt;br /&gt;&lt;br /&gt;Compiler: win&lt;br /&gt;Building Makefile: "C:\GP2XSDK\Projects\TicTakToe\Makefile.win"&lt;br /&gt;Executing  make...&lt;br /&gt;make.exe -f "C:\GP2XSDK\Projects\TicTakToe\Makefile.win" all&lt;br /&gt;cygwin-mkdir -p "win"&lt;br /&gt;&lt;br /&gt;g++.exe -c main.c -o win/main.o &lt;span style="color: rgb(51, 51, 255); font-weight: bold;"&gt;-I"C:/GP2XSDK/include/GP2X"  -I"C:/GP2XSDK/include/SDL"  -I"C:/GP2XSDK/lib/gcc/mingw32/3.4.2/include"  -I"C:/GP2XSDK/include/c++/3.4.2/backward"  -I"C:/GP2XSDK/include/c++/3.4.2/mingw32"  -I"C:/GP2XSDK/include/c++/3.4.2"  -I"C:/GP2XSDK/include"&lt;/span&gt;&lt;span style="font-weight: bold;"&gt; &lt;/span&gt;   -DWIN32&lt;br /&gt;&lt;br /&gt;g++.exe win/main.o  -o TicTacToe.exe &lt;span style="color: rgb(51, 204, 0); font-weight: bold;"&gt;-L"C:/GP2XSDK/lib"&lt;/span&gt; &lt;span style="color: rgb(204, 51, 204); font-weight: bold;"&gt;-lmingw32 -liconv -lgp2x -lSDL_image -lSDL_mixer -lSDL_ttf -lSDL_inifile -lSDLmain -lSDL -lpng -ljpeg -lvorbisidec -lmad -lfreetype -lz -lunicodefont &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Execution terminated&lt;br /&gt;Compilation successful&lt;br /&gt;&lt;br /&gt;Ok so I added some color to help explain what you need to do:&lt;br /&gt;&lt;br /&gt;Open Eclipse and set your perspective to the CDT perspective (if you dont have CDT installed as a plugin then get the update from eclipse using the update procedure:: if you dont know how to do that then look it up using google or read the eclipse tutorials on installing a plugin)&lt;br /&gt;&lt;br /&gt;Now create a new "Managed Make C++ Project" (again read up on eclipse CDT to find out more). So you have a project yay! Now left click the project so its selected. Now right click the project and open its properties dialog. Now on the left there is a list of things...click on "C/C++ Build". There are two configuration types "Release" and "Debug" you should set this up for both or it will compile for one and not the other. So I'll assume you have Debug selected as that seems to be the default:&lt;br /&gt;&lt;br /&gt;Under the GCC C++ compiler we need to add some info to "directories" so go ahead and select that one. Add all the include paths that are in blue as shown above: NOTE::click the add button and enter them like the following (no quotes) "&lt;span style="color: rgb(51, 51, 255); font-weight: bold;"&gt;C:/GP2XSDK/include/GP2X&lt;/span&gt;" do that for all of the blue entries above.&lt;br /&gt;&lt;br /&gt;After you have all of those done, select "GCC C++ Linker" and for "Libraries" add all the purple ones (no quotes) "&lt;span style="color: rgb(204, 51, 204); font-weight: bold;"&gt;mingw32&lt;/span&gt;" etc.&lt;br /&gt;&lt;br /&gt;Under the Library search path add "&lt;span style="color: rgb(51, 204, 0); font-weight: bold;"&gt;C:/GP2XSDK/lib&lt;/span&gt;"&lt;br /&gt;&lt;br /&gt;Remember to set this up for both Release and Debug&lt;br /&gt;&lt;br /&gt;Also you could add (under preprocessor of the compiler) "Defined Symbols" add "WIN32"&lt;br /&gt;&lt;br /&gt;Then you should be able to compile any GP2X example code (Try coping over the generated one from DevC++ and compile that).&lt;br /&gt;&lt;br /&gt;Leave a comment if was helpful at all to you.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/31432920-115344797887432675?l=pocketplayer.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pocketplayer.blogspot.com/feeds/115344797887432675/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=31432920&amp;postID=115344797887432675' title='7 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/31432920/posts/default/115344797887432675'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/31432920/posts/default/115344797887432675'/><link rel='alternate' type='text/html' href='http://pocketplayer.blogspot.com/2006/07/let-games-beginor-at-least-compile.html' title='Let the Games Begin....or at least compile....'/><author><name>Krispy</name><uri>http://www.blogger.com/profile/12140908719342343593</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://2.bp.blogspot.com/-lvlMLPpS_ko/TqZEjvObqbI/AAAAAAAACTY/XLAaU4t5LTw/s1600/assets.github.com%25252Fimages%25252Fgravatars%25252Fgravatar-140.png'/></author><thr:total>7</thr:total></entry></feed>
