Retrieving low/high order words (uFMOD related)
BlitzMax Forums/BlitzMax Beginners Area/Retrieving low/high order words (uFMOD related)
| ||
I notice that uFMOD_GetStats() returns a single var from which you are supposed to extract right and left channel volume information in the form of the low-order word and high-order word respectively. I understand about using upper and lower bits to hold separate numbers (having mistakenly thought ASM might be 'fun') but I must confess to having no idea what the related syntax in BlitzMax would be to process the GetStats() return value. What's the proper way to go about this chaps? |
| ||
Oh no I've stumped the forum! Do I get a prize?! :D |
| ||
shr and shl? |
| ||
Yeah something like,int loword=int(longval & $FFFF) int hiword=int((longval shr 16) & $FFFF)(untested) |
| ||
Ah, so it *is* a shifting thing -- I thought there might be a built-in func to return the low/hi word. That's a lot of help chaps, much appreciated! |