Computer Science Canada

Bitmaps with negative height values

Author:  Insectoid [ Sat Feb 15, 2014 3:46 pm ]
Post subject:  Bitmaps with negative height values

Does Turing properly display bitmaps with negative height values? OSX saves all bitmaps with negative heights and it's the only reason I can think of that would cause the issue I'm having. I've tried drawing this particular image as JPG and GIF, but the BMP format won't work. Can someone drawing it in Turing to see if it's an issue on my end or with Turing itself?

Author:  Zren [ Sat Feb 15, 2014 3:59 pm ]
Post subject:  RE:Bitmaps with negative height values

Nope. Draws nothing. Scaling it to the same size show that only one row of pixels is even loaded it looks like.

Turing:

var picId := Pic.FileNew ("C:\\Users\\Admin\\Downloads\\dirt_158.bmp")
put Pic.Width (picId)
put Pic.Height (picId)
var scaledPicId := Pic.Scale (picId, abs (Pic.Width (picId)), abs (Pic.Height (picId)))
Pic.Draw (scaledPicId, maxx div 2, maxy div 2, picCopy)


Posted Image, might have been reduced in size. Click Image to view fullscreen.

Author:  Insectoid [ Sat Feb 15, 2014 4:09 pm ]
Post subject:  RE:Bitmaps with negative height values

Damn. Oh well, thanks anyway.

Author:  Raknarg [ Sun Feb 16, 2014 10:08 pm ]
Post subject:  RE:Bitmaps with negative height values

What are negative values supposed to do?

Author:  Insectoid [ Sun Feb 16, 2014 11:00 pm ]
Post subject:  RE:Bitmaps with negative height values

Bitmaps with positive height values are stored upside-down in ram. Bitmaps with negative values are stored right-side-up.


: