Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: .tsnavi files: hack or useful tool?



Paolo,

I guess I'd categorize the .tsnavi file as BOTH a hack, and a useful tool.

AVCVideoServices is provided in the FireWire SDK as example code, useful for developers interested in creating software to interface with FireWire-AV/C devices supporting DV or MPEG2-TS streaming. Unlike the user-lib APIs provided by IOFireWireFamily, and IOFireWireAVC, the C++ objects, and APIs provided by AVCVideoServices are not official, standard APIs provided by OS-X. 

The .tsnavi file format, and supporting code in MPEGTrickModes .h/.cpp are provided in AVCVideoServices to support VirtualDVHS's basic skip-forward/skip-back algorithms for MPEG2-TS files during playback, and for the reporting of accurate time-code. The .tsnavi file format is not a standard, nor was it our intention for it to become one. It's just one way of creating a sample-table, for quickly locating the start of frames in a MPEG2-TS file. Do not view the implementation of the .tsnavi file support-functions in AVCVideoServices as an endorsement of this method (or file-format) by Apple.

I don't know of any present or future standard for the indexing of MPEG transport-stream files. Note that FinalCutPro (which uses AVCVideoServices) demultiplexes MPEG transport-streams received from HDV camcorders on-the-fly, and stores the native elementary streams in a QuickTime file, therefore taking advantage of the sample-table architecture provided by the QT file-format (among other advantages), rather than using the .tsnavi method provided by AVCVideoServices.

While the .tsnavi file does simplify VirtualDVHS's random-access of transport-stream files, the extra burden of generating these navigation files (in real-time during recording, or after the fact for pre-existing .m2t files), and keeping them together with their corresponding TS files, definitely has its drawbacks as well. There are certainly opportunities for improvement in the future. Maybe, at the least, VirtualDVHS should support a "bundled" data-file (a folder that looks like a file to the user), which encapsulates both the .m2t file and the corresponding .tsnavi file, to ensure that they stay together, and to simplify the user-experience. 

Regarding your question about intel-based Macs, my goal, if and when a universal-binary version of AVCVideoServices is provided in a future FireWire SDK, is to keep the .tsnavi file a big-endian file-format. The code in MPEGTrickModes would therefore need to include endian-swapping macros to ensure that .tsnavi files created on a ppc Mac would be compatible with intel-based Macs, and visa-versa.


Thanks for your interest in AVCVideoServices. I hope you find that the APIs we've provided greatly simplify your efforts of creating new software that interfaces with these FireWire-AV/C DV and MPEG devices. 


Your questions or comments about AVCVideoServices are always welcome.


Andy Yanowitz

FireWire Software Engineer

Apple Computer, Inc.

email@hidden



On Oct 6, 2005, at 7:28 AM, Paolo Manna wrote:

Hi all,
    I've noticed in the recent FireWire SDK 2.0 the presence of the transport stream navigation files (a.k.a. .tsnavi): as they seem a good idea when manipulating the otherwise convoluted (to say the least) HD streams, I wanted to ask a couple of questions about.

- Are they a temporary/experimental hack for the AVCServices framework, with no utility in the real world, or a foundation for something that can be used, now or in the near future, as a standard reference for programs (FCP or iMovie come to mind, of course) that wants to manipulate HD streams?
- If the latter is true, I've noticed that they're based on a straightforward binary format: what will happen when, with the new Intel-based Macs, the endianity will change?
- If they're a clever hack instead, is anyone aware of a (present or future) standard for the indexing function they provide, considering that they're extremely cheap to create and handle?

I'm sorry if the question has already been posted, but I wasn't able to find any references in the list's archives...

Regards
Paolo



______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Firewire mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Firewire mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/firewire/email@hidden

This email sent to email@hidden

References: 
 >.tsnavi files: hack or useful tool? (From: Paolo Manna <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.