Wii Memory December 19, 2010 02:20PM | Registered: 13 years ago Posts: 29 |
MyClass { u8 id; bool side[6]; u4 light; u8 data; };//total = 26bits MyClass classarray[4][256][256][128];
Re: Wii Memory December 20, 2010 09:13AM | Registered: 13 years ago Posts: 28 |
typedef struct _mystruc { int var1 :4; int var2 :4; } mystruc;
Re: Wii Memory December 20, 2010 01:37PM | Registered: 13 years ago Posts: 29 |
MyClass { u8 id; bool side[6]; int light :4; u8 moredata :6; u8 data; };//total = 32bits = 4bytes MyClass classarray[4][256][256][128];
Re: Wii Memory December 20, 2010 01:50PM | Registered: 15 years ago Posts: 43 |
Re: Wii Memory December 20, 2010 08:15PM | Registered: 14 years ago Posts: 379 |
Re: Wii Memory December 21, 2010 01:00AM | Registered: 13 years ago Posts: 29 |
MyClass { u8 id; int light :4; int side :6; int data :14; };//total = 32bits = 4bytes MyClass classarray[4][256][256][128];
That should be better.Quote
chris
Bear in mind that the bool type actually takes up a whole byte so you will want to use bitfields again here. But yes you are going to run out of memory. You'll have to come up with a different approach.
The 4 dimensional super array would be more like an array of 4 player classes containing the 3dimensional [256][256][128] of my class.Quote
Daid
Uhm, why do you need your 4 dimensional super array? It won't fit in the wii's memory. You might need to rethink your architecture for this one.
Re: Wii Memory December 21, 2010 11:22AM | Registered: 14 years ago Posts: 379 |
So, why do you need the 3 dimensional super array? My first guess would have been something like minecraft, but the 4 was odd in that.Quote
Chicken_BonesThe 4 dimensional super array would be more like an array of 4 player classes containing the 3dimensional [256][256][128] of my class.Quote
Daid
Uhm, why do you need your 4 dimensional super array? It won't fit in the wii's memory. You might need to rethink your architecture for this one.
Re: Wii Memory December 21, 2010 01:30PM | Registered: 13 years ago Posts: 29 |
Re: Wii Memory December 21, 2010 02:14PM | Registered: 14 years ago Posts: 379 |
Re: Wii Memory December 21, 2010 04:00PM | Registered: 13 years ago Posts: 29 |