Hi Charlie,

2011/6/20 Charlie Reiman <rei...@manic.org>

> Hi Harry.
>
> Judging from the error logs, it looks like you're trying to pass
> command line arguments to PTBatcherGUI. If this is correct, there's
> several problems with this.
>
> 1) Tiger can't, at least via "open". open appears to use the Launch
> Services and one of the key data structures in there is the
> LSApplicationParamerters, used by most of the LSOpen functions. In
> there is the argv list, which the docs say:
>
No, I'm not sending args to Tiger. Only to Leopard and Snow Leopard by using
Snow Leopards open binary inside the bundle. The bundle checks for the
version it runs on. On Leopards and Snow Leopard it uses the bundled open
binary with parameters. On Tiger it uses Tigers own system open binary
without parameters.


> argv
> An array of values of type CFStringRef that specify the arguments that
> are to be passed to main() in the launched process. The value of this
> field can be NULL. This field is ignored in Mac OS X v10.4.
>
> I don't think you can ever get argv set via the old Mac's Launch Services.
>
>
Correct. Last week I found that as well from the docs, numerous Google
results and specifically from tests by the users on 10.4. That's also what
we discussed in the thread following upon the previous build and it's
issues.




> 2) I don't think command line args will do anything once the
> application is already running. main() only gets called at start up.
> This is the behavior I'm seeing on Snow Leopard. PTBatcherGUI only
> stitches the first (launching) request.
>
>
Well. It does do this also when the application is already running, as OSX
can make a difference there (from what I found in the docs), but the results
are a bit "wobly". It behaves differently, using Snow Leopards open, on
Leopard and on Snow Leopard, most probably due to the appkit framework. I
have not figured out yet what the differences are.
Snow Leopards open binary works on Leopard including the arguments, but I
assume that linked libraries/frameworks have a reduced instruction/function
set when compared to 10.6.



> There are plenty of options available though. Hugin can easily find
> the stitcher via LSFindApplicationForInfo. I've tested that and it
> works (10.6.7, but it should work all the way back to 10.0).


 I investigated this as well but not being a programmer I was quickly lost.
Do you have a patch or an example of this?


> After
> that, there's a lot of options to start the stitching but I haven't
> tested them: Shared memory, named pipes, AppleEvents, or
> LSOpenItemsWithRole.

AppleEvents is probably the right thing but every time I look at the
> AppleEvents docs my brain seizes up. LSOpenItemsWithRole looks like it
> will do what you need though.
>
>
I had a look at AppleEvents as well. Again: as I'm not a programmer I was
lost within minutes.
Any help with this is appreciated.

Harry

-- 
You received this message because you are subscribed to the Google Groups 
"Hugin and other free panoramic software" group.
A list of frequently asked questions is available at: 
http://wiki.panotools.org/Hugin_FAQ
To post to this group, send email to hugin-ptx@googlegroups.com
To unsubscribe from this group, send email to 
hugin-ptx+unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/hugin-ptx

Reply via email to