• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: FxTexture Motion 2 & 3
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: FxTexture Motion 2 & 3


  • Subject: Re: FxTexture Motion 2 & 3
  • From: Dave Howell <email@hidden>
  • Date: Sun, 1 Jul 2007 23:30:02 -0700

Hi Christoph,

I've never actually tried retrieving more than one image well in the same render, from the same image well, so I've never run into this. But it sounds like you've discovered a Motion 2 bug that was fixed in Motion 3.

Your workaround is on the right track, but I believe you'll actually have to copy the GL texture, not just the FxTexture object. In the code you tried (to get texture2[j]), you're not actually making a new GL texture, just a new FxTexture that has the same GL texture (with ID 2). You'll need to create a new PBuffer, draw the texture into that, and then use that as your texture[j]. Since PBuffer creation is expensive, you should keep the PBuffer around between renders.

I'm sure one of the Motion engineers will correct me if any of this is way off base.

Cheers!
Dave

On Jul 1, 2007, at 10:09 PM, Christoph Vonrhein wrote:

Hello,

here is my current problem. I have a FxTexture I get from an image well:

for ( int j=1; j<=10; j++ ) {
[getAPI   getTexture: &texture[j]
layerOffsetX: &imageOffset.x
layerOffsetY: &imageOffset.y
requestInfo: iInfo
fromParm: clip_ParamID
  atTime: renderInfo.frame + j];
}

The texture is a short clip with, lets lay, 10 frames. So I want to put all the frames into an array: texture[j]
This works perfectly with Motion 3 and I can access and see the 10 frames and they all have a different textureID.

When the same plugin runs with Motion 2, the array ends up with the same texture for all array entries (the textureID is always "2"). So when I read the 10 frames, all entries in the array will be exactly the same and I wont be able to access the first 9 frames, because each call of the -getTexture method overwrites the last read frame. I will always see the last read frame, no matter in which order I read the 10 frames.

Is this normal for Motion 2 ? What can I do to to avoid this?

------

So I thought to copy the frames one by one to another array while I read them from the image well with something like this:

Header:

FxTexture *texture2[10];

Code:

texture2[j] = [[FxTexture alloc] autorelease];
[texture2[j] initWithInfo: [texture[j] imageInfo] andTextureId: [texture[j] textureId]];

But... somehow this does not work... Any clues ?

best regards
Christoph Vonrhein

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Pro-apps-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: FxTexture Motion 2 & 3
      • From: Christoph Vonrhein <email@hidden>
References: 
 >FxTexture Motion 2 & 3 (From: Christoph Vonrhein <email@hidden>)

  • Prev by Date: FxTexture Motion 2 & 3
  • Next by Date: Re: FxTexture Motion 2 & 3
  • Previous by thread: FxTexture Motion 2 & 3
  • Next by thread: Re: FxTexture Motion 2 & 3
  • Index(es):
    • Date
    • Thread