Chameleon

Chameleon Commit Details

Date:2015-07-30 03:49:23 (3 years 11 months ago)
Author:ErmaC
Commit:2739
Parents: 2738
Message:Typo
Changes:
M/trunk/i386/boot2/graphics.c
M/trunk/i386/libsaio/gma.c
M/trunk/i386/boot2/boot.c
M/trunk/i386/boot2/gui.c
M/trunk/i386/boot2/boot.h
M/trunk/i386/boot2/lzvn.c
M/trunk/i386/boot2/options.c

File differences

trunk/i386/libsaio/gma.c
4848
4949
5050
51
52
53
54
5551
5652
5753
......
6965
7066
7167
72
7368
7469
75
7670
7771
7872
......
135129
136130
137131
138
139132
140133
141134
......
157150
158151
159152
160
161153
162154
163155
......
869861
870862
871863
872
873864
874865
875866
......
939930
940931
941932
942
933
943934
944935
945936
#define DEBUG_GMA 0
#endif
#ifndef DEBUG_BDW
#define DEBUG_BDW 1
#endif
#if DEBUG_GMA
#define DBG(x...)printf(x)
#else
static uint8_t default_aapl_haswell[]={ 0x00,0x00,0x26,0x0c }; // haswell_ig_vals[7]
#define AAPL_LEN_HSW ( sizeof(default_aapl_haswell) / sizeof(uint8_t) )
#if DEBUG_BDW
static uint8_t default_aapl_broadwell[]={ 0x00,0x00,0x1e,0x16 }; // broadwell_ig_vals[2]
#define AAPL_LEN_BDW ( sizeof(default_aapl_broadwell) / sizeof(uint8_t) )
#endif
uint8_t GMAX3100_vals[23][4] = {
{ 0x01,0x00,0x00,0x00 },//0 "AAPL,HasPanel"
{ 0x04,0x00,0x12,0x04 }// 16 "AAPL,ig-platform-id" //FB: 32MB, Pipes: 3, Ports: 3, FBMem: 3 - ULT mobile GT3
};
#if DEBUG_BDW
uint8_t broadwell_ig_vals[19][4] = {
{ 0x00,0x00,0x06,0x16 },// 0 - 16060000 Broadwell GT1 (Intel HD Graphics)
{ 0x00,0x00,0x0e,0x16 },// 1 - 160e0000 Broadwell GT1 (Intel HD Graphics)
{ 0x05,0x00,0x26,0x16 },// 17 - 16260005 Broadwell GT3 (MacBook Air) (Intel HD Graphics 6000)
{ 0x06,0x00,0x26,0x16 }// 18 - 16260006 Broadwell GT3 (MacBook Air) (Intel HD Graphics 6000)
};
#endif
uint8_t HD2000_vals[16][4] = {
{ 0x00,0x00,0x00,0x00 }, //0 "AAPL00,PixelFormat"
break;
#if DEBUG_BDW
/* Broadwell */
/* HD Graphics 5300 Mobile, HD Graphics 6000 Mobile, HD Graphics 6100 Mobile */
case GMA_BROADWELL_BDW_0bd0: // 0bd0
devprop_add_value(device, "class-code", ClassFix, 4);
break;
#endif // DEBUG_BDW
default:
break;
}
trunk/i386/boot2/graphics.c
780780
781781
782782
783
783
784784
785
786
787
788
785
786
787
788
789789
790
791
792
793
794
795
796
790
791
792
793
794
795
796
797
797798
798
799
800
799
800
801
801802
802
803
804
805
806
803
804
805
806
807
807808
808
809
809810
810811
811812
......
859860
860861
861862
862
863
863864
864865
865866
......
930931
931932
932933
933
934
934935
935936
936937
937938
938
939
939
940
940941
941942
942943
......
961962
962963
963964
965
964966
965967
966968
......
10241026
10251027
10261028
1027
1028
1029
1030
1031
1032
1029
1030
1031
1032
1033
1034
10331035
10341036
10351037
unsigned long lookUpCLUTIndex( unsigned char index, unsigned char depth )
{
long result;
long result;
long colorIndex = (index * 3);
long red = appleClut8[ colorIndex ];
long green = appleClut8[ colorIndex++ ];
long blue = appleClut8[ colorIndex++ ];
long colorIndex = (index * 3);
long red = appleClut8[ colorIndex ];
long green = appleClut8[ colorIndex++ ];
long blue = appleClut8[ colorIndex++ ];
switch (depth) {
case 16 :
result = ((red & 0xF8) << 7) |
((green & 0xF8) << 2) |
((blue & 0xF8) >> 3);
result |= (result << 16);
break;
switch (depth)
{
case 16 :
result = ((red & 0xF8) << 7) |
((green & 0xF8) << 2) |
((blue & 0xF8) >> 3);
result |= (result << 16);
break;
case 32 :
result = (red << 16) | (green << 8) | blue;
break;
case 32 :
result = (red << 16) | (green << 8) | blue;
break;
default :
result = index | (index << 8);
result |= (result << 16);
break;
}
default :
result = index | (index << 8);
result |= (result << 16);
break;
}
return result;
return result;
}
//==========================================================================
unsigned short y,
unsigned short width,
unsigned short height,
unsigned char *data )
unsigned char *data )
{
unsigned short drawWidth;
void drawPreview(void *src, uint8_t * saveunder)
{
uint8_t *screen;
uint8_t *screen;
uint32_t rowBytes, pixelShift;
uint32_t x, y;
int32_t blob;
uint32_t alpha, in, color, result;
uint8_t *out;
void *uncomp;
uint8_t *out;
void *uncomp;
int origwidth, origheight, origbpx;
uint32_t saveindex[kIOHibernateProgressCount] = { 0 };
screen = (uint8_t *) VIDEO (baseAddr);
rowBytes = VIDEO (rowBytes);
// Set the screen to 75% grey.
drawColorRectangle(0, 0, VIDEO(width), VIDEO(height), 0x01 /* color index */);
}
void updateProgressBar(uint8_t * saveunder, int32_t firstBlob, int32_t select)
{
uint8_t * screen;
uint32_t rowBytes, pixelShift;
uint32_t x, y;
int32_t blob, lastBlob;
uint32_t alpha, in, color, result;
uint8_t * out;
uint8_t*screen;
uint32_trowBytes, pixelShift;
uint32_tx, y;
int32_tblob, lastBlob;
uint32_talpha, in, color, result;
uint8_t*out;
uint32_t saveindex[kIOHibernateProgressCount] = { 0 };
pixelShift = VIDEO(depth) >> 4;
trunk/i386/boot2/lzvn.c
6262
6363
6464
65
66
6567
6668
67
6869
6970
7071
const void *src,
size_t src_size)
{
const uint64_t rdi = (const uint64_t)dst;
size_t rax = 0;
const uint64_t rdi = (const uint64_t)dst;
uint64_t rsi = dst_size;
uint64_t rcx = src_size;
uint64_t rdx = (uint64_t)src;
trunk/i386/boot2/boot.c
105105
106106
107107
108
108
109109
110110
111111
//static voidselectBiosDevice(void);
/** options.c **/
extern char* msgbuf;
extern char *msgbuf;
void showTextBuffer(char *buf, int size);
//==========================================================================
trunk/i386/boot2/boot.h
270270
271271
272272
273
273
274274
275275
276276
unsigned short height,
const unsigned char *imageData,
unsigned char **newImageData );
extern char * decodeRLE( const void * rleData, int rleBlocks, int outBytes );
extern char *decodeRLE( const void *rleData, int rleBlocks, int outBytes );
extern void drawBootGraphics(void);
extern void drawPreview(void *src, uint8_t *saveunder);
extern int getVideoMode(void);
trunk/i386/boot2/gui.c
23302330
23312331
23322332
2333
23332334
23342335
23352336
......
23842385
23852386
23862387
2387
2388
2388
2389
23892390
23902391
23912392
const char *dummyVal;
int oldScreenWidth, oldScreenHeight;
bool legacy_logo = true; // ErmaC: Legacy Logo is enabled by default
uint16_t x, y;
getBoolForKey("Legacy Logo", &legacy_logo, &bootInfo->chameleonConfig);
}
else
{
// Fill the background to 75% grey (same as BootX).
drawColorRectangle(0, 0, screen_params[0], screen_params[1], 0x01);
// Fill the background to 75% grey (same as BootX).
drawColorRectangle(0, 0, screen_params[0], screen_params[1], 0x01);
}
if ((bootImageData) && (usePngImage))
trunk/i386/boot2/options.c
13821382
13831383
13841384
1385
1385
13861386
13871387
13881388
}
// Ermac : Inject "kext-dev-mode=1" if OS X 10.10 is detected
if ( YOSEMITE ) // OS X is 10.10
if ( MacOSVerCurrent == MacOSVer2Int("10.10") ) // OS X is 10.10
{
addBootArg("kext-dev-mode=1");
}

Archive Download the corresponding diff file

Revision: 2739