realbasic-nug
[Top] [All Lists]

Re: Component returned from declare

To: REALbasic Network Users Group <realbasic-nug at lists dot realsoftware dot com>
Subject: Re: Component returned from declare
From: "Joseph J. Strout" <joe at realsoftware dot com>
Date: Wed, 27 Feb 2002 21:15:57 -0800
At 11:34 PM -0500 2/27/02, Mike Woodworth wrote:

I'm trying to play video out the firewire QtOutputComponent.  I've built a
componentDescription and filled it with the proper values for the output
component I want, but the call FindNextComponent () takes and returns a
Component.  This seems to be a class, not a variable - so I'm assuming I
can't build a memoryblock to contain it.

If it's an opaque data type that's created and destroyed by QT, then just declare it in RB as an integer. See the QD3D demos on <http://www.strout.net/info/coding/rb> for many examples. If it's not opaque, but is something you're expected to create and destroy yourself, then a MemoryBlock is the right thing to use.

Can I instantiate the component somehow and retain as a property of my
class?  I need to pass it to the OpenComponent() call later.

Sure -- my guess is you'll want to just use an integer.

Cheers,
- Joe


--
,------------------------------------------------------------------.
|    Joseph J. Strout           REAL Software, Inc.                |
|    joe at realsoftware dot com       http://www.realsoftware.com        |
`------------------------------------------------------------------'


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