Developing a Java API for Digital Video control using the Firewire SDK - PowerPoint PPT Presentation

1 / 20
About This Presentation
Title:

Developing a Java API for Digital Video control using the Firewire SDK

Description:

Developing a Java API for Digital Video control using the Firewire SDK ... DVDevice control/Isochronous Data Handler. C Library. DV controller library. Java JNI ... – PowerPoint PPT presentation

Number of Views:92
Avg rating:3.0/5.0
Slides: 21
Provided by: aucUo
Category:

less

Transcript and Presenter's Notes

Title: Developing a Java API for Digital Video control using the Firewire SDK


1
Developing a Java API for Digital Video control
using the Firewire SDK
Academic Developers Conference 2001
  • Damon Woolley
  • Bing-Chang Lai
  • Phillip John McKerrow
  • University of Wollongong

2
Introduction
  • What is Firewire?
  • The API
  • Version in Paper
  • Current Version
  • Using the API
  • To do list
  • Where to get the API
  • QA

3
What is Firewire?
  • Firewire is Apples name for IEEE 1394 Standard
  • High-speed bus (Up to 400 Mbits per second)
  • Hot-swappable
  • Easy cabling

4
What is Firewire?
  • Different data can be sent across Firewire of
    which Digital Video (DV) is one.
  • Digital Video (DV)
  • Uses compression similar to motion-JPEG
  • Compression rate of around 51
  • Constant data rate of 36 Mbits per second

5
What is Firewire?
  • Firewire provides a standard for interacting with
    DV devices
  • Called Audio Video/Control (AV/C)
  • The Java API being developed by UOW is for
    providing an easy-to-use interface to AV/C

6
The API
  • Easy-to-use Java interface to AV/C
  • Original Firewire AV/C commands are all in
    low-level C

7
The API
  • The API has the following structure
  • Java Application
  • JNI Layer
  • C/C Layer
  • Firewire
  • Version in Paper
  • Used a C Layer, adapted from IsochComponent from
    the Firewire SDK
  • Current Version
  • Uses a C layer, and mirrors the C API to Java
  • Only supports MacOS X

8
Version in Paper
  • Adapted from IsochTest Example provided with
    Firewire SDK
  • A prototype for learning
  • Extract the appropriate functions
  • Expose these C functions to Java
  • Therefore it does not have a very correct
    structure or design

9
Version in Paper
  • Software Architecture (From Paper)

10
Version in Paper
  • JNIOut
  • void InitDV(String msg)
  • Print Information about available components
  • void OpenDV(String msg)
  • Gets the default dv component
  • Print information about the component
  • Sets the video configuration of the component
  • void OpenControlDV(String msg)
  • Open device for reading
  • void CloseControlDV()
  • Close device

11
Version in Paper
  • JNIOut
  • void ControlDV(int op1, int op2)
  • Uses op1 and op2 to create an AV/C command, and
    sends it to the DV device
  • Some opcodes are listed in the paper
  • Complete opcodes are available from
    http//www.1394ta.org/Technology/Specifications/
    Descriptions/1394_AVC.htm
  • eg. Play (0xc3, 0x75), Stop (0xc4, 0x60), Fast
    Forward (0xc4, 0x75), Rewind (0xc4, 0x65)

12
Current Version
  • DVController
  • Uses JNIOut. Calls ControlDV and passes AV/C
    operand codes

13
Current Version
  • In avc namespace, avc package
  • AVDeviceFactory
  • AVDevice getDefaultDevice()
  • Creates an AVDevice from the default dv component
  • The device is initialised when AVDevice is
    constructed
  • Corresponds to OpenDV
  • AVDevice
  • boolean open()
  • opens the device
  • Corresponds to OpenControlDV

14
Current Version
  • AVDevice
  • boolean close()
  • closes the device
  • Corresponds to CloseControlDV
  • boolean play()
  • boolean stop()
  • boolean fastforward()
  • boolean rewind()
  • boolean nextframe()
  • boolean prevframe()

15
Current Version
  • AVDevice
  • boolean slowplay()
  • boolean fastplay()
  • boolean rplay()

16
Using the API
Version in Paper System.loadLibrary("JNIOut") ...
JNIOut interface new JNIOut() interface.InitDV
() interface.OpenDV() interface.OpenControlDV()
... // Play Command interface.ControlDV(0xc3,
0x75) ... // Stop Command interface.ControlDV(0xc
4, 0x60) ... interface.CloseControlDV()
Current Version System.loadLibrary("AVC") ... AVD
eviceFactory f new AVDeviceFactory() AVDevice
d f.getDefaultDevice() d.open() // Will
return false if failed ... d.play() // Will
return false if failed ... d.stop() // Will
return false if failed ... d.close()
17
To-Do List
  • Provide ControlDV equivalent
  • Provide more functions
  • Time Code Functions
  • Get Time Code
  • Go to a specific Time Code
  • Instead of returning True/False, functions will
    throw Exceptions

18
Where to get the API
  • Planning on putting the current version onto
    www.kagi.com for about AU10 a copy, probably
    with source
  • Not done yet
  • If you want to know when it will be up, you can
    email me on bl12_at_uow.edu.au

19
References
  • D. Woolley, B. Lai, P.J. McKerrow, Developing a
    Java API for Digital Video Control using the
    Firewire SDK, AUC 2001
  • 1394 Trade Association, AV/C Digital Interface
    Command Set, Version 1, Sept 1996, see
    http//www.1394ta.org/Technology/Specifications/
    Descriptions/1394_AVC.htm
  • Apple Inc., Firewire SDK 9 for MacOS X, see
    http//developer.apple.com/hardware/FireWire/

20
QA
Write a Comment
User Comments (0)
About PowerShow.com