Server Help

Non-Subspace Related Coding - do YOU have an idea?

tcsoccerman - Wed Sep 05, 2007 9:39 pm
Post subject: do YOU have an idea?
Anyone have an ideas of programs that i could make. I can't think of anything.
CypherJF - Wed Sep 05, 2007 10:15 pm
Post subject:
there are plenty of things to make... what type of technologies would you like to dive into? networking, concurrency, webapp, db, graphical, ...
Smong - Thu Sep 06, 2007 1:48 pm
Post subject:
Can you make a bmp -> raw convertor? It would have to accept 24bit bmp's minimum and output to either 32bit 8888 (just write it as if alpha was off), 16bit 4444, 5551 and 565. I don't know all the details but it should just involve deleting the bmp headers and some scaling to convert 8 bits per pixel to 4-5 bits per pixel. Also you aren't allowed to use .NET. There seems to be a lack of 16bit support in image editors.
tcsoccerman - Thu Sep 06, 2007 3:51 pm
Post subject:
Thank you smong and CypherJF.

Smong:this one i may be interested in. First i need to know what exactly raw is...Second, if i can't use.NET(c#), can i use C? But now that i think of it, i don't have a Visual C Editer, and Microsofts is stupid(some free trial crap). Other than that i'm interested, so if you can find a way for me to use .NET, and describe raw it could work out.

CypherJF:I'm interested in programs that make you're life easier by taking data and making the most out of it, such as my Team Tracker/Sport Tracker program. I could be interested in networking, but not webapps, not databases, nor graphical(yet, may look into that).
Smong - Thu Sep 06, 2007 6:47 pm
Post subject:
I don't know much about the .raw format myself. I assume it's just raw pixel data, no headers like a bmp, so you must store the width/height/depth separate in your head or a separate file (you could even put it in the filename).

For example a 32bit image, you would write out 4 bytes for each pixel (1 byte each for r,g,b and alpha parts), just keep doing fwrite()'s starting from the top left pixel, go to the end of the column, then start on the next row down. When you write it out I think it might be ABGR too: 0xaabbggrr, since it's little endian red still ends up being the first byte in the file.

For 8888 -> 5551 conversion I think you do something like r5 = r8 * 32 / 256 to scale 256 down to 32 (5bits, 2^^5 = 32). For alpha set it to 0 I think.

Code: Show/Hide
struct
{
   unsigned short r : 5;
   unsigned short g : 5;
   unsigned short b : 5;
   unsigned short a : 1;
} rgba5551;
rgba5551.r = some_pixels_r_component * 32 / 256;
rgba5551.g = some_pixels_g_component * 32 / 256;
rgba5551.b = some_pixels_b_component * 32 / 256;
rgba5551.a = 0;
fwrite(&rgba5551, sizeof(rgba5551), 1, f);
nextpixel();

The reason I requested no .net was because I don't want to install the runtime. Don't you have devcpp for making asss modules? Hmm, I wonder if this is possible in PHP.
tcsoccerman - Thu Sep 06, 2007 7:00 pm
Post subject:
Yes i have devcpp, but it doesn't have the visual part. i don't plan on doing a windows app without visual aide. Unless it is just a commandprompt app.
tcsoccerman - Thu Sep 06, 2007 7:06 pm
Post subject:
http://www.ssforum.net/index.php?showtopic=17110&hl= for my newest project info.
Cyan~Fire - Fri Sep 07, 2007 12:43 am
Post subject:
Why not just make a console app?
All times are -5 GMT
View topic
Powered by phpBB 2.0 .0.11 © 2001 phpBB Group