Titan Network

Archive => Multimedia => Community => Demo Recording => Topic started by: Sin Stalker on March 10, 2013, 08:30:42 AM

Title: How do you manipulate FXTINT?
Post by: Sin Stalker on March 10, 2013, 08:30:42 AM
I'm trying to make electric armor blue. The type of blue as the default electric blaster. Can anyone give me a short instruction on how the FXTINT works and maybe a starting point to help me narrow down how to get it?
Title: Re: How do you manipulate FXTINT?
Post by: Samuraiko on March 11, 2013, 02:57:12 AM
0   1910 FXTINT -16777037 -16777216

This is a color sample from my pain/energy corruptor. Her primary color was red, backset was black, IIRC. I'm trying to figure out the conversion from whatever this is to RGB, because when I just check the numbers, it doesn't come out right.

Michelle
aka
Samuraiko/Dark_Respite
Title: Re: How do you manipulate FXTINT?
Post by: Sin Stalker on March 11, 2013, 04:16:32 AM
Yeah, seems that no matter what I change the numbers to, the electricity comes out white.

Its too bad no one has been able to figure out and make a fx tint converter.
Title: Re: How do you manipulate FXTINT?
Post by: The Fifth Horseman on March 11, 2013, 04:52:09 PM
Quote from: Sin_Stalker on March 11, 2013, 04:16:32 AMIts too bad no one has been able to figure out and make a fx tint converter.
More likely because it's so elementary to us computer geeks that we fail to realise anyone might have a problem with it. Here's the C code - after compiling the program and running it, just type in the RGB value to convert.
Code (C) Select
#include <stdio.h>
int main()
{
int i;
scanf("%X", &i);
i=((i&0x000000FF)<<16)+((i&0x00FF0000)>>16)+(i&0x0000FF00)|0xFF000000;
printf("%d\n", i);
return 0;
}

Quote from: Samuraiko on March 11, 2013, 02:57:12 AM
0   1910 FXTINT -16777037 -16777216

This is a color sample from my pain/energy corruptor. Her primary color was red, backset was black, IIRC. I'm trying to figure out the conversion from whatever this is to RGB, because when I just check the numbers, it doesn't come out right.
The values are stored in the lower three bytes of 32-bit signed integers. The demo commands store them as integers rather than hex strings.
-16777037 = 0xFF0000B3
-16777216 = 0xFF000000
Note that this appears to be in BGR order rather than RGB.
To convert from these values to RGB, you can either use a very simple program in C or use a calculator.
Code (C) Select

#include <stdio.h>
int main()
{
int i;
scanf("%d", &i);
i=((i&0x000000FF)<<16)|((i&0x00FF0000)>>16)|(i&0x0000FF00);
printf("%06X\n", i);
return 0;
}


There are some roundabout ways of doing it with a calculator app (or an actual calculator). The simplest one is to use Windows' calculator app with its' scientific view:
1. Input the number (with sign) when the calculator is in decimal mode.
2. Switch to hexadecimal mode.
3. Done.

A more roundabout way:

Title: Re: How do you manipulate FXTINT?
Post by: Codewalker on March 11, 2013, 07:24:57 PM
Quote from: The Fifth Horseman on March 11, 2013, 04:52:09 PM
Note that this appears to be in BGR order rather than RGB.

Taking a guess, it's likely parsed as an integer and then fed to something like glColor4ubv or glColorPointer as-is. Since x86 is a little-endian architecture, the 32-bit integer -16777037 (0xFF0000B3) will be stored in memory with the low byte first as:

B3 00 00 FF

If re-cast as an array of unsigned char[4] and passed to an OpenGL function, then it would be in the customary RGBA order.
Title: Re: How do you manipulate FXTINT?
Post by: Sin Stalker on March 15, 2013, 06:24:59 AM
Quote from: The Fifth Horseman on March 11, 2013, 04:52:09 PM
More likely because it's so elementary to us computer geeks that we fail to realise anyone might have a problem with it. Here's the C code - after compiling the program and running it, just type in the RGB value to convert.
Code (C) Select
#include <stdio.h>
int main()
{
int i;
scanf("%X", &i);
i=((i&0x000000FF)<<16)+((i&0x00FF0000)>>16)+(i&0x0000FF00)|0xFF000000;
printf("%d\n", i);
return 0;
}
The values are stored in the lower three bytes of 32-bit signed integers. The demo commands store them as integers rather than hex strings.
-16777037 = 0xFF0000B3
-16777216 = 0xFF000000
Note that this appears to be in BGR order rather than RGB.
To convert from these values to RGB, you can either use a very simple program in C or use a calculator.
Code (C) Select

#include <stdio.h>
int main()
{
int i;
scanf("%d", &i);
i=((i&0x000000FF)<<16)|((i&0x00FF0000)>>16)|(i&0x0000FF00);
printf("%06X\n", i);
return 0;
}



Run code? Sorry, I'm not that computer skilled. How do I do this?
Title: Re: How do you manipulate FXTINT?
Post by: The Fifth Horseman on March 17, 2013, 09:31:01 AM
Quote from: Sin_Stalker on March 15, 2013, 06:24:59 AMRun code? Sorry, I'm not that computer skilled. How do I do this?
*sigh*
This should be more up to your speed.
https://www.dropbox.com/s/dtaltzdq6prd4ad/FiXTINT.zip
Title: Re: How do you manipulate FXTINT?
Post by: Sin Stalker on March 17, 2013, 06:42:59 PM
Thank you. I downloaded it and extracted the files. However now I have a folder (and 3 sub folders) with files I have no idea how to run. lol

Not sure what to google or if there is some readme file I am missing?
Title: Re: How do you manipulate FXTINT?
Post by: Arachnion on March 17, 2013, 09:41:05 PM
Quote from: Sin_Stalker on March 17, 2013, 06:42:59 PM
Thank you. I downloaded it and extracted the files. However now I have a folder (and 3 sub folders) with files I have no idea how to run. lol

Not sure what to google or if there is some readme file I am missing?

I just downloaded it and there's an exe file in there.

Run that.

;D
Title: Re: How do you manipulate FXTINT?
Post by: Sin Stalker on March 18, 2013, 06:35:44 AM
Quote from: Arachnion on March 17, 2013, 09:41:05 PM
I just downloaded it and there's an exe file in there.

Run that.

;D

Weird. I don't have an exe file. I'll try downloading it again.
Title: Re: How do you manipulate FXTINT?
Post by: Sin Stalker on March 18, 2013, 07:02:22 AM
Sweet. Got it. Thank you!
Title: Re: How do you manipulate FXTINT?
Post by: therain93 on March 18, 2013, 12:39:28 PM
So, could you theoretically select any hue beyond the ones we had available to choose from in the GUI, assuming you input it in the correct format, or is there a limitation in the renderer as well?
Title: Re: How do you manipulate FXTINT?
Post by: Sin Stalker on March 18, 2013, 08:44:09 PM
I used this to find the RGB number.

http://www.rapidtables.com/web/color/RGB_Color.htm


So I think you can pick colors or shades that weren't accessible before but I don't know for sure.
Title: Re: How do you manipulate FXTINT?
Post by: TimtheEnchanter on March 18, 2013, 11:59:13 PM
Never could understand why FXTINT uses this bizarre system of numbers while the costume colors use normal hexidecimal.
Title: Re: How do you manipulate FXTINT?
Post by: The Fifth Horseman on March 19, 2013, 08:19:23 AM
Most likely someone messed up a numeric format specifier on release and it was retained for backwards compatibility.

Quote from: Sin_Stalker on March 17, 2013, 06:42:59 PMThank you. I downloaded it and extracted the files. However now I have a folder (and 3 sub folders) with files I have no idea how to run. lol
You only need the .exe file directly in the archive itself. The subdirectories contain the application source.

Quote from: therain93 on March 18, 2013, 12:39:28 PMSo, could you theoretically select any hue beyond the ones we had available to choose from in the GUI, assuming you input it in the correct format, or is there a limitation in the renderer as well?
Uncertain. Try and see what you get?