Jump to content

  • Log In with Google      Sign In   
  • Create Account


#ActualNightCreature83

Posted 12 June 2012 - 06:35 AM

As another option you could compile them into the binary as well.

You need to make a HEX dump of the BMP file and thin in code you define this:
class image_error
{
public:
static const unsigned char m_imageData[] = {
	0x42, 0x4D, 0x38, 0x30, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x36, 0x0, 0x0, 0x0, 0x28, 0x0, 0x0, 0x0, 0x40,
	 0x0, 0x0, 0x0, 0x40, 0x0, 0x0, 0x0, 0x1, 0x0, 0x18, 0x0, 0x0, 0x0, 0x0, 0x0, 0x2, 0x30, 0x0, 0x0, 0xE6,
	 0x1C, 0x0, 0x0, 0xE6, 0x1C, 0x0, ... ,0x0
};
static const unsigned int m_dataSize = 12344;
};			

This is not ideal however as it will make the executable very big and you have to have facilities in place to be able to load image data from memory (which usually shouldn't be a problem).

#6NightCreature83

Posted 12 June 2012 - 06:34 AM

As another option you could compile them into the binary as well.

You need to make a HEX dump of the BMP file and thin in code you define this:
class image_error
{
public:
static const unsigned char m_imageData[] = {
	0x42, 0x4D, 0x38, 0x30, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x36, 0x0, 0x0, 0x0, 0x28, 0x0, 0x0, 0x0, 0x40, 0x0, 0x0, 0x0, 0x40, 0x0, 0x0, 0x0, 0x1, 0x0, 0x18, 0x0, 0x0, 0x0, 0x0, 0x0, 0x2, 0x30, 0x0, 0x0, 0xE6, 0x1C, 0x0, 0x0, 0xE6, 0x1C, 0x0, ... ,0x0
};
static const unsigned int m_dataSize = 12344;
};			

This is not ideal however as it will make the executable very big and you have to have facilities in place to be able to load image data from memory (which usually shouldn't be a problem).

#5NightCreature83

Posted 12 June 2012 - 06:34 AM

As another option you could compile them into the binary as well.

You need to make a HEX dump of the BMP file and thin in code you define this:
class image_error
{
public:
static const unsigned char m_imageData[] = {
	0x42, 0x4D, 0x38, 0x30, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x36, 0x0, 0x0, 0x0, 0x28, 0x0, 0x0, 0x0, 0x40, 0x0, 0x0, 0x0, 0x40, 0x0, 0x0																													, 0x0, 0x1, 0x0, 0x18, 0x0, 0x0, 0x0, 0x0, 0x0, 0x2, 0x30, 0x0, 0x0, 0xE6, 0x1C, 0x0, 0x0, 0xE6, 0x1C, 0x0, ... ,0x0
};
static const unsigned int m_dataSize = 12344;
};			

This is not ideal however as it will make the executable very big and you have to have facilities in place to be able to load image data from memory (which usually shouldn't be a problem).

#4NightCreature83

Posted 12 June 2012 - 06:34 AM

As another option you could compile them into the binary as well.

You need to make a HEX dump of the BMP file and thin in code you define this:
class image_error 
{
public: 
static const unsigned char m_imageData[] = {
    0x42, 0x4D, 0x38, 0x30, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x36, 0x0, 0x0, 0x0, 0x28, 0x0, 0x0, 0x0, 0x40, 0x0, 0x0, 0x0, 0x40, 0x0, 0x0                                                                                                                    , 0x0, 0x1, 0x0, 0x18, 0x0, 0x0, 0x0, 0x0, 0x0, 0x2, 0x30, 0x0, 0x0, 0xE6, 0x1C, 0x0, 0x0, 0xE6, 0x1C, 0x0, ... ,0x0
};
static const unsigned int m_dataSize = 12344;
};			

This is not ideal however as it will make the executable very big and you have to have facilities in place to be able to load image data from memory (which usually shouldn't be a problem).

#3NightCreature83

Posted 12 June 2012 - 06:31 AM

As another option you could compile them into the binary as well.

You need to make a HEX dump of the BMP file and thin in code you define this:
										[color=#000088]class[/color] image_error											[color=#666600]{[/color]											[color=#000088]public[/color][color=#666600]:[/color]											        [color=#000088]static[/color] [color=#000088]const[/color] [color=#000088]unsigned[/color] [color=#000088]char[/color] m_imageData[color=#666600][][/color]																																					        [color=#006666]0x42[/color][color=#666600],[/color] [color=#006666]0x4D[/color][color=#666600],[/color] [color=#006666]0x38[/color][color=#666600],[/color] [color=#006666]0x30[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x36[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x28[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x40[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x40[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color]																											        [color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x1[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x18[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x2[/color][color=#666600],[/color] [color=#006666]0x30[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0xE6[/color][color=#666600],[/color] [color=#006666]0x1C[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0xE6[/color][color=#666600],[/color] [color=#006666]0x1C[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color="#006666"]... , [/color]																			
																														[color=#006666]0x0[/color]																											[color=#666600]};[/color]																			
																														 																			        [color=#000088]static[/color] [color=#000088]const[/color] [color=#000088]unsigned[/color] [color=#000088]int[/color] m_dataSize [color=#666600]=[/color] [color=#006666]12344[/color][color=#666600];[/color]											[color=#666600]};[/color]			

This is not ideal however as it will make the executable very big and you have to have facilities in place to be able to load image data from memory (which usually shouldn't be a problem).

#2NightCreature83

Posted 12 June 2012 - 06:31 AM

As another option you could compile them into the binary as well.

You need to make a HEX dump of the BMP file and thin in code you define this:
										[color=#000088]class[/color] image_error											[color=#666600]{[/color]											[color=#000088]public[/color][color=#666600]:[/color]											        [color=#000088]static[/color] [color=#000088]const[/color] [color=#000088]unsigned[/color] [color=#000088]char[/color] m_imageData[color=#666600][][/color]																																					        [color=#006666]0x42[/color][color=#666600],[/color] [color=#006666]0x4D[/color][color=#666600],[/color] [color=#006666]0x38[/color][color=#666600],[/color] [color=#006666]0x30[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x36[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x28[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x40[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x40[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color]																											        [color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x1[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x18[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x2[/color][color=#666600],[/color] [color=#006666]0x30[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0xE6[/color][color=#666600],[/color] [color=#006666]0x1C[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color=#006666]0xE6[/color][color=#666600],[/color] [color=#006666]0x1C[/color][color=#666600],[/color] [color=#006666]0x0[/color][color=#666600],[/color] [color="#006666"]... , [/color]																			
																														[color=#006666]0x0[/color]																											[color=#666600]};[/color]																			
																														 																			        [color=#000088]static[/color] [color=#000088]const[/color] [color=#000088]unsigned[/color] [color=#000088]int[/color] m_dataSize [color=#666600]=[/color] [color=#006666]12344[/color][color=#666600];[/color]											[color=#666600]};[/color]			

This is not ideal however as it will make the executable very big and you have to have facilities in place to be able to load image data from memory (which usually shouldn't be a problem).

PARTNERS