realbasic-nug
[Top] [All Lists]

Re: C conversion to RealBasic

To: "REALbasic NUG" <realbasic-nug at lists dot realsoftware dot com>
Subject: Re: C conversion to RealBasic
From: "Keith Hutchison" <keith dot hutchison at balance-infosystems dot com>
Date: Wed, 31 Aug 2005 19:43:56 +1000
Delivered-to: realbasic-nug at lists dot realsoftware dot com
References: <00c701c5ae08$e6a2fda0$0100000a at KEITHXP> <e22e3169897ce6d3453012ee7e5f89f0 at implements dot be>
Because you do a binary and on a mask, only a couple of bits are left,
so it's no use doing the substraction

Eg.
11010110 is in controltype (214)
00001100 is in the mask (12)
the binary add gives you 00000100 (4)
that is checked against the _LIST, which should be 4 also (in integer
value)

Binary and's and or's are in RB, just use them

controlType =
BitwiseAnd(MIXERCONTROL_CT_CLASS_MASK,mixerControl(0).dwControlType)

Many thanks

Keith

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

<Prev in Thread] Current Thread [Next in Thread>