Corrupt .bmp fix?
Re: Corrupt .bmp fix?
Hi Lux,
Actually knowing what lessons people have watched won't be able to tell you the level of competance though.
I have watched all 21 lessons and even though they are the best C++ tutorials I have ever seen, there is still lots I am vague on. Mainly the maths.
Even though I don't understand 90% of the maths I like the that that Chilli does explain. I will re-watch tutorials later.
I really want to be better at maths, but I had a rubbish maths teacher at school.
I did go on to do level N1 electronics, and there was pretty intensive maths in that, but not like geometry maths heh heh.
Asimov
Actually knowing what lessons people have watched won't be able to tell you the level of competance though.
I have watched all 21 lessons and even though they are the best C++ tutorials I have ever seen, there is still lots I am vague on. Mainly the maths.
Even though I don't understand 90% of the maths I like the that that Chilli does explain. I will re-watch tutorials later.
I really want to be better at maths, but I had a rubbish maths teacher at school.
I did go on to do level N1 electronics, and there was pretty intensive maths in that, but not like geometry maths heh heh.
Asimov
----> Asimov
"You know no matter how much I think I have learnt. I always end up hitting brick walls"
http://www.asimoventerprises.co.uk
"You know no matter how much I think I have learnt. I always end up hitting brick walls"
http://www.asimoventerprises.co.uk
Re: Corrupt .bmp fix?
Possibly, but it still gives a better picture of the persons nollage, and underline the word "roughly".
For mathematics I recommend buying a book with the basic mathematics in it. I always have some here near this book I use which has the most used math formulas and stuff like that. Pretty useful, and of course a good symbolic and geometic calculator.
For mathematics I recommend buying a book with the basic mathematics in it. I always have some here near this book I use which has the most used math formulas and stuff like that. Pretty useful, and of course a good symbolic and geometic calculator.
ʕ •ᴥ•ʔ
Re: Corrupt .bmp fix?
Hmm... I got to the part where you wrote the text string, but something really funky happens.
I write "gfx.DrawString("Works!", f, 20, &fixedSys, D3DCOLOR_XRGB(255, 255, 255));"
And it outputs on the screen "Works! c:\users\...path...\Chili Directx Framework BMP\assets\Bitmap.cpp Fixedsys16x28.bmp rb ! FAILED ( result) pDirect3D != NULL c:\users\...\Chili Directx Framework BMP\assets\d3dgraphics.cpp"
As if I wrote that as a string... No errors, nothing that just gets printed on the screen... hmm.
Then I changed the "for (int n = 0; string[n] != "\n"; n += 1)" to "for (int n = 0; string[n] != 0; n += 1)" and works like a charm! Weird...
I write "gfx.DrawString("Works!", f, 20, &fixedSys, D3DCOLOR_XRGB(255, 255, 255));"
And it outputs on the screen "Works! c:\users\...path...\Chili Directx Framework BMP\assets\Bitmap.cpp Fixedsys16x28.bmp rb ! FAILED ( result) pDirect3D != NULL c:\users\...\Chili Directx Framework BMP\assets\d3dgraphics.cpp"
As if I wrote that as a string... No errors, nothing that just gets printed on the screen... hmm.
Then I changed the "for (int n = 0; string[n] != "\n"; n += 1)" to "for (int n = 0; string[n] != 0; n += 1)" and works like a charm! Weird...
ʕ •ᴥ•ʔ
Re: Corrupt .bmp fix?
Not weird at all. If you think about it, that is the logical result of the code you wrote.
Can you figure out why?
Can you figure out why?
Chili
Re: Corrupt .bmp fix?
I tried, but I'm allergic to figuring stuff out : -(
Maybe the '\n' somehow didn't detect the ending of the string.
Doubt you do, but if you think the "f" is causing it, its a variable declared to scroll the text around to see what the full string is saying.
Other than that, I have no idea why its "\n" when it should be '\n'? I copy pasted that part from the code, but now as I try to recreate the "\n" situation I can't even debug it unless I put '\n' Which strangely now works?!
Or does the variable "n" and string '\n' somehow collide as both have n?
Maybe the '\n' somehow didn't detect the ending of the string.
Doubt you do, but if you think the "f" is causing it, its a variable declared to scroll the text around to see what the full string is saying.
Other than that, I have no idea why its "\n" when it should be '\n'? I copy pasted that part from the code, but now as I try to recreate the "\n" situation I can't even debug it unless I put '\n' Which strangely now works?!
Or does the variable "n" and string '\n' somehow collide as both have n?
ʕ •ᴥ•ʔ
Re: Corrupt .bmp fix?
'\n' is the escape code for a newline character (ASCII code 10). '\0' is the escape code for a null character (ASCII code 0). Got it now LuX?
Chili
Re: Corrupt .bmp fix?
: -O I mustn't have payed enough attention. Strangely the \n seems to work now anyways, but I sticked to the plain 0.
ʕ •ᴥ•ʔ