Csound Csound-dev Csound-tekno Search About

[Csnd] HRTF questions and possible bugs

Date2014-07-02 05:26
FromMichael Saunders
Subject[Csnd] HRTF questions and possible bugs
I have been experimenting with the opcodes hrtfmove, hrtfmove2, and hrtfearly.  There are several confusing points in the docs.  The orientation and units aren't always explained, but I think they are as follows: 
hrtfearly:
ksrcx, ksrcy, ksrcz, klstnrx, klstnry, klstnrz:
both source and listener positions as Cartesian coordinates in meters with the origin at the center of the room.  I think the orientation of the listener is in the +ve y direction (so:

+ve x=right,
+ve y=forward,
+ve z=up).
kheadrot:  in degrees, 0=forward, increasing turns the head clockwise, so, e.g., 90 turns the head right.

1. Is this correct?

2. hrtfearly: Head rotation has no effect if y<~-5% room length.
If I place the listener anywhere with y>=0 and move 
kheadrot from 0 to 360, I get the expected result---the head seems to turn clockwise, but if y is, say, -3, the right reflections are weaker than the left and the ITD=0 for all angles.

3. hrtfearly: I place the listener in the center of the room, and move the source in a circle 1 meter from the listener, from 0 to 360 (starting forward of the listener and moving clockwise).  The right reflection is earlier (with roughly constant ITD) for all angles except 0 and 360, where right and left arrive simultaneously.  The reflections are loudest when behind and to the left of the listener, from about 175--270 degrees clockwise from forward.  The impression I get is not of a sound circling my head, as I get with the hrtfmove opcodes.

I expected the ITDs to increase with |x|, left earlier when x<0, right earlier when x>0, and both weaker when y<0.  Am I wrong or is there something wrong with 
hrtfearly?