question about OUT & palette loading - Printable Version +- Qbasicnews.com (http://qbasicnews.com/newforum) +-- Forum: Qbasic "like" compilers/interpreters (http://qbasicnews.com/newforum/forum-5.html) +--- Forum: FB Discussion & Programming Help (http://qbasicnews.com/newforum/forum-15.html) +--- Thread: question about OUT & palette loading (/thread-5941.html) |
question about OUT & palette loading - toad - 02-06-2005 Code: SUB ChangePalette (PaletteArray&()) something about the latest (.11b) version of FBC has caused my 256 color palette to load oddly. instead of loading the colors in the right order, it seams to load them in a different way. at a glance, it looks like all the colors are there, but not in the gradient rows i put them in; they are all scattered and mixed. is it the OUT statement? question about OUT & palette loading - Antoni Gual - 02-06-2005 In noticed it too.. I ported an old raycaster of mine that uses OUT and gradients, the colors are more saturated in FB than in QB question about OUT & palette loading - toad - 02-06-2005 yeah. this palette should be a set of visible gradients. look how it cuts them up into sections, like on the red, and the grayscale at the very bottom. miniature gradients... but not only that, there shouldn't be bits of green mixed with the purple. so it does other odd things too. question about OUT & palette loading - Sterling Christensen - 02-06-2005 I found what's causing this. The code for OUT is shifting RGB values up from 6 bit to 8 bit, which is fine, but then it's treating the values as if they're still 6 bit... I've commited a simple fix (changed a 2 to a 0 in two lines) that makes it work, I hope Angelo won't mind. For now you can just use the palette command to set the palette instead. You should anyway, because OUT is slower (it simply passes the values you give it on to the palette command). question about OUT & palette loading - toad - 02-06-2005 hey thanks man. question about OUT & palette loading - na_th_an - 02-06-2005 I think OUT shouldn't be used. Let it there just to make old code compilable, but when you code something new, do use PALETTE. Why? Just style. In Windows, that OUT stuff has no true meaning, it's just some kind of wrappin' emulation technique just for backwards compatibility. New programs coded specifically for FB should use PALETTE, so when people see source codes they don't have to wonder what the hell is doing the program with the ports from windows Toad, your SUB could have been a lot shorter: PALETTE USING Palettearray&(0) question about OUT & palette loading - toad - 02-06-2005 haha, awesome. well you learn something every day. Palette Using... lol. simple stuff. |