Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Topics - Crivens

#21
Ok so lets say you want to make a Universal app (I'm thinking iDevice but it can apply to all supported devices). You code it for retina but allow scaling so it will work on any resolution (ie. set project resolution to 9998x9999 or the other way around). Excellent, so essentially it will run at 320x480 on a pre-retina, 640x960 on a retina, and 768x1024 on an iPad. No worries there.

Your game runs smoothly on the pre-retina device and well on the iPad, but the retina device (I'm thinking specifically of the lower powered iPhone4 (not S) and iPod 4th gen) just doesn't quite cut it. It looks better sure, it is 4x the pixels, but the power of the device just isn't enough to make it as smooth as the non-retina device.

Ideally you would want the retina device to then run at the non-retina resolution so it can be smooth. But you still want the iPad to be full res.

So how do you go about making it a universal app but actually for an iPhone4 and iPod 4th gen it should be retina resolution? Infact more complicated is the idea that the iPhone4S and iPod 5th gen should have enough juice to smoothly run retina for your game. So how would you make sure the iPhone4 runs non-retina and the 4S runs retina, all off the same universal app?

Just to make it more complicated, lets say your game looks good but seriously there is no amazingly obvious difference between the retina and non-retina version. ie. it's not such a big impact and is hard to notice the difference. Fair enough you could then make sure that non-iPad devices all run at non-retina but the iPad itself runs at full-HD (for a universal app). However there is no reason why your menu or help screens (especially for small harder to read text) cannot be full retina. What I am saying is it possible to change the resolution on the fly for iDevices (or any device really) and if not then why not? Is it not possible once the app has run or can GLB be updated to allow it?

Cheers
#22
Considering a large percentage of GLB is geared towards mobile devices then it would be great if someone made a mobile portal for this forum.

Seriously it is hard to navigate from a mobile device and worse entering a new post is as slow as balls! Honestly I don't know what's going on with the entry sustenance but even on a pc it's sluggish. On an iPhone (right now) its like typing in treacle. Honestly is a right old type and pray it gets it right. You should see my keyboard going mental showing loads of enlarged letters on the iPhone keyboard because it's sooo slow to respond.

Just my 2p as I do most of my comments here from mobile devices and I'm betting a lot of people here do too.

Cheers
#23
Ok so I'm doing a quick side project for my wife on my iPod 4th gen retina device.

Part of it involves having a nice non moving backdrop so I used loadbmp with a full 640x960 jpg. The fps went from 60 to 47. I have a load of other sprites onscreen but this one thing takes up 13fps cos when I take it out it's back to 60 again. Using it as a sprite keeps it about the same so I assume loadbmp is doing the same thing in the background. Using png has no impact so assume they are the same thing in memory.

But really 13fps (at least as its limited to 60 on the device) to just show the background?

My next game keeps 60fps on full retina but it uses 3d. Should I use 3D as the background for a pseudo 2d wallpaper? Or perhaps a smaller sprite zoomed? Will test more tomorrow.

Cheers
#24
Is it possible to alter a 3D object's core values? Say to alter the coords of a single 3D vertex? More importantly, for me, I would like to change the colour of a vertex of a 3D object (or at least to change the complete object to be a certain colour).

Main reason for me is I have some primitive 3D objects that are simply coloured with the X_OBJADDVERTEX command. At a later point I want to change that colour without using a different object or a different coloured texture. Another routine I have uses changing lighting to give a pulse effect on 3D objects, but because of problems with iOS it would be better if I could just change the core colour on the fly giving a similar effect.

Cheers
#25
Alphamode seems to get reset to 0 after drawing a sprite (or perhaps zoomsprite it's difficult to tell, but it does reset at some point when drawing sprites). Is there a way to set the default value of alphamode? Basically I pretty much use -1 for everything to get all the correct alpha values, and rarely want to use anything else. Just a bit annoying to have to put ALPHAMODE -1 all the time. To be able to say DEFAULTALPHAMODE -1 would be great.

Cheers
#26
I'm just checking some smoothness issues with my game and I noticed something interesting on my iPod touch (latest gen not counting what's been announced a couple of days ago). Basically I'm limiting the FPS to 60 and with my game there should be no issue in this. It's not exactly Quake 4 or anything.

Anyway I realised my score would not work between games that have different frame rates as I'm not increasing it to do with timings (like movement which I do use). Because of the simplicity of my game then so far all devices are the same score if you let the player die (score keeps going up at a set rate and if you don't touch anything you will die at the same time every time). Obviously this means everything is maxing out at 60FPS (didn't originally set it to 60 but it obviously internally does this as setting to 60 keeps the same score when you die) with no slowdown (seriously is hardly anything to actually slow it down). This is all my devices. A PC running the retina resolution, iPod Touch 2nd Gen and a Pre2 and 3GS (all running quarter overall retina), and a TP running iPad resolution (forget Android tablet as haven't had time to update it).

While I was looking for methods to make sure the score always increases according to the time I noticed something strange. My iPod touch (Retina model) has always looked a little jittery running the game (It works fine if I force non-retina mode though), which I put down to the increased resolution (even though the CPU and GPU are far superior). But the score is exactly half of the other devices. Every time. Hmm. This suggests it is being forced to 30FPS maximum. It cannot be overworked as this score would surely be quite random. So I set all my other devices to" LIMITFPS 30". And they got the same results as the retina iPod. And of course were jittery in exactly the same way.

So that leads me to the conclusion that retina mode for the latest iPod Touch (and I assume iPhone 4) is hardcoded to a maximum of 30 frames per second. Is this correct or am I missing something? Surely this would be obvious in the smoothness of other HD games so I can only assume GLB is limiting it for some reason (hopefully mistakenly rather than intentionally). I seriously want to get my retina devices as smooth as the non-retina ones and I can't see how to do it without reducing the resolution for retina (defeats the point of coding it for retina really).

Gernot? Can you shed some light or at least point out where I'm being a bit of an idiot?

Cheers
#27
Off Topic / iPhone 4GS
2011-Oct-04
Anyone else deeply unimpressed?

Cheers
#28
I don't know what it is but something has gone wrong in the last release or two from GLB.

Basically a friend of mine was playing my latest in development game and reported that he died for no reason whatsoever. Strange. And it always happened around a certain score. Stranger I thought. So I put in a bit of debugging and the like but couldn't really track it down easily. It was something to do with the ES and EntitySingleCollision using an array that I keep adding to using DIMPUSH. But it makes no sense.

Then I tried to replicate on my various devices. It went wrong on every one of them. Fair enough. But then it worked on one. My Palm Pre2 which I hadn't updated with the latest version of my program (every other device worked on the new version). Obviously something to do with my latest version! So I load the old version and it too errors in the same place (ie. in the past I've got much higher scores). Erm. Ok maybe the pre2 version was an older build of the same version I hadn't updated?... So I try a really old version (about 2-3 weeks old), knowing that that version definitely didn't error for no reason and I had got much higher scores in testing (and the main game hasn't really changed it all in that time). And that has the error now too.

So it must be the latest version (or possibly the one before that) of GLB at fault. I read elsewhere that Gernot has changed array handling in the last version so I'm guessing it's that.

Please Obi Wan Gernot, help me in my time of need!

Oh, and while we are at it, the accelerometer doesn't seem to work correctly. Is nothing like the same values as the Pre/iOS/Android.

Ta!

Cheers 
#29
GLBasic - en / iOS media
2011-Sep-09
Ok so I have update one of my png files for my iOS project in XCode (3 not 4 yet). But the graphics aren't being updated on the device (two different devices so far). In XCode it is showing the new graphic for the png file, but a quick check in iPhone explorer and it's using the old graphics. I remove the graphic using iPhone explorer and rebuild and now it just shows without the graphic. Hmm. Manually replace the file using iPhone explorer and all is well it uses the new graphics. I've tried removing the apps from the devices, restarting XCode fully, all to no avail. It still uses the old graphics. Bit weird. At times like these does the Mac need a reboot or something? Or is there an option to refresh the graphics or something? Can't believe I released a few games on iOS already and never changed an existing graphic... Am sure I did... Maybe Lion being crap? (like you can't put anything in trash now without it asking for a password...)

Cheers
#30
I'm just using some audio effects and was wondering if a compressed audio format can be used with playsound. I tried an mp3 out but it doesn't play. Are there other formats apart from WAV that works?

Just wondering considering an mp3 sound is so much smaller than a wav and sounds ok.

Cheers
#31
Ok so I'm using 3D (Entity system found on forum) in my latest game and so far so good.

I then tried a bit of lightning which worked fine on the PC and on WebOS. I've included images that show no light used, standard light (255,255,255), and blue light (0,0,255). No worries really. Code was pretty much EntityCreateLight(RGB(255,255,255)) (with changes for blue light and not used at all for no light) with a move afterwards although that makes no difference to the problem it seems.

Then I tried on iOS (3GS and 4G Touch). Everything is too bright. And on the blue light is much too blue. If I reduce the brightness (say by lowering the colour from (255,255,255) then it just changes the colour but still looks too bright).

I guess I could muck around with the light settings and get it just so for iPhone (everything looks a little higher contrast even with no light on WebOS for example but it's acceptable compared to the serious brightness of the iPhone) but does anyone know if iDevices need different light settings or another command used to keep it in line?

Attached is white light (255,255,255) of PC and iOS. You can see the PC is fine, but the iPhone is much too bright. Both have used lighting as can be seen by shading on the spheres in the background.

Cheers

[attachment deleted by admin]
#32
GLBasic - en / Resolutions
2011-Aug-27
Is there a way to make a device use it's highest resolution settings?

Currently my project resizes graphics based on a comparison made between the used resolution and a target resolution. I am targeting the retina iOS devices so have the project settings of 640x960. On my iPod 4G no resizing is required but my 3GS shrinks them as the resolution is 4x the pixels less. If I set to 320x480 then the retina device does use that resolution. However I would imagine the iPad will do the same thing as this and stay at 640x960. Not what I want. Needs to use full iPad size.

Ok I could do graphics for the largest display and set to that but I would rather have an option where all devices just use their native resolutions and I can worry about the resizing myself and not worry about setting to the highest resolution setting when things may change in the future.

Cheers
#33
GLBasic - en / Free phones
2011-Aug-22
Seen this?
http://www.zdnet.com/blog/cell-phones/webos-devs-microsoft-offers-free-phones-and-training-for-windows-phone-7/6386

Hmm. Don't have time at the minute (at work) to look into more. Anyone want to have a better look and update us?

Also, Gernot, still no chance of Windows 7 phone compilation?

Might just try and get one anyway if it's free...

Cheers
#34
GLBasic - en / Retina 3D
2011-Aug-19
Ok so I'm almost done putting together a 3D game, using my trusty Pre2 as a test device all along the development cycle. No worries, runs like a charm. Anyway I get to the point where I think I'll try it on an iDevice. Both my 3GS and 2G Touch work brilliantly. This is when compiled for Retina. When it gets to the older devices it obviously isn't doing Retina, and the first time in it resizes all 2D graphics (3D can stay the same) to the correct resolution (code is posted on these forums).

It all works brilliantly. The Pre runs it the smoothest, but the 3GS and even the 2G Touch are pretty close as to not really matter. However when I thought I'd try my 4G Touch (Retina) it looks better (obviously) with the un-resized graphics, but once it gets to the 3D it stutters quite a bit. Now I'm using timer based movement so it can jutter now and again if something is running in the background (fair enough but runs at the correct speed), but it happens all the time. I tried compiling hardcoded to the non-retina resolution and it works fine on the 4G. As smooth as the 3GS.

So is it really that the 4G Touch just doesn't have the speed to run 3D (pretty simple too with not much going on) in full Retina display, or is there something wrong here? And would the iPhone4 be better? Note I am not using up stupid amounts of memory either. It's a pretty simple game. Also is it possible to compile for Retina and then switch to non-retina mid game? So menus all look good and then the main 3D bit (which doesn't benefit too much from Retina) can be in non-retina.

Cheers
#35
What commands do you use to assign a variable to the ID for LOADANIM? With LOADSPRITE you can use GENSPRITE() to assign the ID, but I couldn't find anything for LOADANIM.

Cheers
#36
IDE/Syntax / Macro buttons
2011-Aug-10
As we get more and more devices on GLB I am finding my macro bar getting a bit full. For example I use 3 just for iOS (initial full SCP copy, media and libs copy only, and just libs copy) and another for WebOS. That's me full.

I want to get into Android soon, and I assume that can be sped up by using another macro like iOS and WebOS before it. But I have no more macro buttons.

Can we get some more added to the IDE? It would be nice to be able to add new macros and assign them to the toolbar ourselves, but just an increase in the basic 4 would be nice (something like 10 with a rainbow of colours would be pretty good, or the ability to modify the icon ourselves).

Cheers
#37
Off Topic / Kitty Hello FPS
2011-Jul-29
Hey, Gernot, if you ever plan an FPS then use this gun:-


Had to laugh when I saw that :)

BTW it's a real gun. See http://blog.riflegear.com/archive/2007/12/26/hello-kitty-ar-15---evil-black-rifle-meets-cute-and.aspx

Cheers
#38
GLBasic - en / Blackberry
2011-Jul-28
I can't find any reference to it, but can you use GLB on Blackberry devices? According to a blog site I saw today they still reckon it is 20% of the US smartphone market so a pretty big deal to develop apps for (WebOS is 2% for instance, iOS 28%, and Android 39%).

Cheers
#39
Bug Reports / Screen error
2011-Jul-22
I'm getting an error where the screen isn't being cleared each loop like it used to. Identical code running on my Palm Pre from an older GLB version (not sure if was 9 or one of the 10 betas to be honest) worked fine, but now I am getting repeated graphics from previous screens staying on the screen. I can get around it by clearing that area each time, but it definitely didn't used to happen on an older GLB. See the attached pic to see what I mean. It should be just showing the foremost text (5 seconds left and no other text) and nothing else in the last 80 or so pixels (just black in the background).

Note this happens on my Palm Pre as well as my PCs (10.057 and 10.054). I would check my Mac Mini but it's going through installing Lion etc.

Cheers

[attachment deleted by admin]
#40
Ok, using the standard function to get the mouse coords (the one that's posted everywhere) on the new 10.051 release, updates the active flag, but the X and Y coords are always zero for WebOS (Windows works fine). Incase I was going crazy I tested on 10.042 and it works fine in WebOS with my same code. Not sure if it still works on iOS as I'm informed, by the wife, that my dinner is ready :-[

Oh, and how do I go back a version in GLB? ie. so I can return to 10.042?

Cheers