Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Javascript declaration

15 views
Skip to first unread message

Les Player

unread,
May 30, 2001, 7:54:06 PM5/30/01
to
Can anyone please advise me of the equivalent Javascript declaration for to
call a function GetViewing3D.

Basic:
Function GetViewing3D(ByRef VRPx As Single, ByRef VRPy As Single, ByRef VRPz
As Single, ByRef EyeX As Single, ByRef EyeY As Single, ByRef EyeZ As Single,
ByRef tanViewAngleHalf As Single) As Boolean

C++:
HRESULT GetViewing3D(float *VRPx, float *VRPy, float *VRPz, float *EyeX,
float *EyeY, float *EyeZ, float *tanViewAngleHalf, VARIANT_BOOL *pResult);


Jim Ley

unread,
May 31, 2001, 3:53:35 AM5/31/01
to

javascript as of current released implementations, doesn't accept
function parameters passed by reference, ECMAScript Ed. 4 almost
certainly will and JScript.NET suggests that

function GetViewing3D(ref double VRPx, ... )

will be the relevant code.

Jim.

--
FAQ: http://jibbering.com/faq/
Old FAQs: http://jibbering.com/faq/old/

Federico Sasso

unread,
May 31, 2001, 4:00:19 AM5/31/01
to
> Can anyone please advise me of the equivalent Javascript declaration for
to
> call a function GetViewing3D.

function GetViewing3D(VRPx, VRPy, VRPz, EyeX, EyeY, EyeZ, tanViewAngleHalf)

keep in mind that JavaScript is a loosely typed language, there's not type
declaration.
Plus, function parameters are all passed by value, eccept complex type
parameters which are passed by reference

hope this could help you.

--

Federico Sasso &8v>
http://www.crt.unige.it/jsSQL
The jsSQL Project - JavaScript Database and SQL Engine

ma...@datacad.com

unread,
Dec 14, 2012, 2:37:12 PM12/14/12
to
I don't believe that either GetViewing3D or GetViewing3DEx are accessible from a JavaScript. Instead you would use GetViewing3DExAsSring().

Something like this:

function ShowView()
{
var CurrView = 'string';
CurrView = document.thePlayer.GetViewing3DExAsString();
alert( CurrView );
}

However, SetViewing3DEx can be used like this:

function SetView();
{
var VRPx = 0.0;
var VRPy = 0.0;
var VRPz = 0.0;
var EyeX = 0.150053799152374;
var EyeY = 0.24226513504982;
var EyeZ = 0.155817657709122;
var tanViewAngleHalf = 0.463434785604477;
var parallel = 0;
var sView = 'string';

document.thePlayer.SetViewing3DEx(VRPx, VRPy, VRPz, EyeX, EyeY, EyeZ, tanViewAngleHalf, parallel);

alert( sView );
}

Nice to find you here in the archives of cyberspace!

MFM

Mark F. Madura
President/CEO
DATACAD LLC
ma...@datacad.com

Scott Sauyet

unread,
Dec 14, 2012, 3:14:44 PM12/14/12
to
Mark wrote:

> I don't believe that either GetViewing3D or GetViewing3DEx are
> accessible from a JavaScript. Instead you would use
> GetViewing3DExAsSring(). [ ... ]

You do realize that you're responding to a post more than 11 years
old, right?

Just checking,

-- Scott
0 new messages