ebook img

Oracle InterMedia. User's Guide and Reference PDF

692 Pages·2001·4.161 MB·English
by  Ward R.
Save to my drive
Quick download
Download
Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.

Preview Oracle InterMedia. User's Guide and Reference

Oracle® interMedia User’s Guide and Reference Release 9.0.1 June 2001 Part No. A88786-01 Oracle interMedia audio, document, image, and video is designed to manage Internet media content. interMedia is a standard feature, enabling Oracle9i to manage rich content, including text, documents, images, audio, video, and location information, in an integrated fashion with traditional business data. Oracle interMedia User’s Guide and Reference, Release 9.0.1 Part No. A88786-01 Copyright © 1999, 2001, Oracle Corporation. All rights reserved. Primary Author: Rod Ward Contributors: Susan Mavris, Melli Annamalai, Todd Rowell, Raja Chatterjee, Robert Abbott, Albert Landeck, Vishal Rao, Dongbai Guo, Fengting Chen, Joseph Mauro, Rabah Mediouni, Sanjay Agarwal, Bill Voss, Susan Kotsovolos, Rosanne Toohey, Bill Beauregard, Susan Shepard, Helen Grembowicz The Programs (which include both the software and documentation) contain proprietary information of Oracle Corporation; they are provided under a license agreement containing restrictions on use and disclosure and are also protected by copyright, patent, and other intellectual and industrial property laws. Reverse engineering, disassembly, or decompilation of the Programs is prohibited. The information contained in this document is subject to change without notice. If you find any problems in the documentation, please report them to us in writing. Oracle Corporation does not warrant that this document is error free. Except as may be expressly permitted in your license agreement for these Programs, no part of these Programs may be reproduced or transmitted in any form or by any means, electronic or mechanical, for any purpose, without the express written permission of Oracle Corporation. If the Programs are delivered to the U.S. Government or anyone licensing or using the programs on behalf of the U.S. Government, the following notice is applicable: Restricted Rights Notice Programs delivered subject to the DOD FAR Supplement are "commercial computer software" and use, duplication, and disclosure of the Programs, including documentation, shall be subject to the licensing restrictions set forth in the applicable Oracle license agreement. Otherwise, Programs delivered subject to the Federal Acquisition Regulations are "restricted computer software" and use, duplication, and disclosure of the Programs shall be subject to the restrictions in FAR 52.227-19, Commercial Computer Software - Restricted Rights (June, 1987). Oracle Corporation, 500 Oracle Parkway, Redwood City, CA 94065. The Programs are not intended for use in any nuclear, aviation, mass transit, medical, or other inherently dangerous applications. It shall be the licensee's responsibility to take all appropriate fail-safe, backup, redundancy, and other measures to ensure the safe use of such applications if the Programs are used for such purposes, and Oracle Corporation disclaims liability for any damages caused by such use of the Programs. Oracle and SQL*Plus are registered trademarks, and Oracle9i and PL/SQL are trademarks of Oracle Corporation. Other names may be trademarks of their respective owners. Contents LLLiiisssttt ooofff TEFaxigbaumlerespsles Send Us Your Comments................................................................................................................ xxiii Preface......................................................................................................................................................... xxv Audience.............................................................................................................................................. xxv Organization....................................................................................................................................... xxvi Related Documents........................................................................................................................... xxvii Conventions....................................................................................................................................... xxvii Changes to This Guide..................................................................................................................... xxviii Documentation Accessibility........................................................................................................... xxix 1 Introduction 1.1 Object Relational Technology.............................................................................................. 1-1 1.2 Multimedia Content Management..................................................................................... 1-2 1.3 Audio Concepts..................................................................................................................... 1-5 1.3.1 Digitized Audio.............................................................................................................. 1-6 1.3.2 Audio Components........................................................................................................ 1-6 1.4 ORDDoc or Heterogeneous Media Data Concepts.......................................................... 1-6 1.4.1 Digitized Heterogeneous Media Data......................................................................... 1-7 1.4.2 Heterogeneous Media Data Components.................................................................. 1-7 1.5 Image Concepts..................................................................................................................... 1-7 1.5.1 Digitized Images............................................................................................................ 1-8 1.5.2 Image Components........................................................................................................ 1-8 1.6 Video Concepts...................................................................................................................... 1-9 iii 1.6.1 Digitized Video............................................................................................................... 1-9 1.6.2 Video Components......................................................................................................... 1-9 1.7 Multimedia Object Types and Methods........................................................................... 1-10 1.8 Multimedia Storage............................................................................................................. 1-10 1.8.1 Storing Multimedia Data............................................................................................. 1-11 1.8.2 Querying Multimedia Data......................................................................................... 1-12 1.8.3 Accessing Multimedia Data........................................................................................ 1-12 1.9 Extending Oracle interMedia............................................................................................. 1-12 1.9.1 Supporting Other External Sources and Other Media Data Formats................... 1-13 1.9.2 Supporting Audio Data Processing........................................................................... 1-14 1.9.3 Supporting Video Data Processing............................................................................ 1-14 1.10 Relational Interface.............................................................................................................. 1-15 1.11 Loading Multimedia Data into Oracle9i Using interMedia........................................... 1-15 1.12 Reading Data from a LOB.................................................................................................. 1-16 1.13 interMedia Architecture...................................................................................................... 1-17 1.13.1 Oracle interMedia Java Classes................................................................................... 1-21 1.13.2 Oracle interMedia Java Classes for Servlets and JSPs............................................. 1-22 1.13.3 Annotation Services for Multimedia Data................................................................ 1-23 1.13.4 Streaming Content from an Oracle Database........................................................... 1-24 1.13.5 Support for Web Technologies................................................................................... 1-25 1.13.6 Geocoding Services...................................................................................................... 1-25 2 Content-Based Retrieval Concepts 2.1 Overview and Benefits.......................................................................................................... 2-1 2.2 How Content-Based Retrieval Works................................................................................. 2-2 2.2.1 Color................................................................................................................................. 2-5 2.2.2 Texture............................................................................................................................. 2-7 2.2.3 Shape................................................................................................................................ 2-7 2.3 How Matching Works........................................................................................................... 2-8 2.3.1 Weight.............................................................................................................................. 2-8 2.3.2 Score................................................................................................................................. 2-8 2.3.3 Similarity Calculation.................................................................................................... 2-9 2.3.4 Threshold Value........................................................................................................... 2-11 2.4 Using an Index to Compare Signatures........................................................................... 2-12 2.5 Preparing or Selecting Images for Useful Matching...................................................... 2-13 iv 3 interMedia Examples 3.1 Audio Data Examples........................................................................................................... 3-1 3.1.1 Defining a Song Object.................................................................................................. 3-2 3.1.2 Creating an Object Table SongsTable.......................................................................... 3-2 3.1.3 Creating a List Object Containing a List of References to Songs............................ 3-2 3.1.4 Defining the Implementation of the songList Object................................................ 3-3 3.1.5 Creating a CD Object and a CD Table......................................................................... 3-3 3.1.6 Inserting a Song into the SongsTable Table............................................................... 3-4 3.1.7 Inserting a CD into the CdTable Table........................................................................ 3-5 3.1.8 Loading a Song into the SongsTable Table................................................................ 3-5 3.1.9 Inserting a Reference to a Song Object into the Songs List in the CdTable Table 3-6 3.1.10 Adding a CD Reference to a Song............................................................................... 3-8 3.1.11 Retrieving Audio Data from a Song in a CD.............................................................. 3-8 3.1.12 Extending interMedia to Support a New Audio Data Format................................ 3-9 3.1.13 Extending interMedia with a New Type..................................................................... 3-9 3.1.14 Using Audio Types with Object Views..................................................................... 3-10 3.1.15 Scripts for Creating and Populating an Audio Table from a BFILE Data Source.......... ..............................................................................................................................3-11 3.2 Media Data Examples......................................................................................................... 3-19 3.2.1 Defining a Media Object.............................................................................................. 3-20 3.2.2 Creating an Object Table DocumentsTable.............................................................. 3-21 3.2.3 Creating a List Object Containing a List of References to Media.......................... 3-21 3.2.4 Defining the Implementation of the documentList Object.................................... 3-21 3.2.5 Creating a Library Object and a Library Table........................................................ 3-22 3.2.6 Inserting Media into the DocumentsTable Table.................................................... 3-23 3.2.7 Inserting a Library into the LibraryTable Table...................................................... 3-24 3.2.8 Loading Media into the DocumentsTable Table..................................................... 3-24 3.2.9 Inserting a Reference to a Document Object into the Documents List in the LibraryTable Table .............................................................................................3-25 3.2.10 Adding a Library Reference to a Document............................................................ 3-26 3.2.11 Extending interMedia to Support a New Media Data Format.............................. 3-27 3.2.12 Extending interMedia with a New Type................................................................... 3-28 3.2.13 Using Document Types with Object Views............................................................. 3-28 3.2.14 Using the ORDDoc Object Type as a Repository.................................................... 3-29 3.2.15 Scripts for Creating and Populating a Media Table from a BFILE Data Source. 3-34 v 3.3 Image Data Examples......................................................................................................... 3-41 3.3.1 Adding Image Types to an Existing Table............................................................... 3-42 3.3.2 Adding Image Types to a New Table........................................................................ 3-42 3.3.3 Inserting a Row Using BLOB Images........................................................................ 3-43 3.3.4 Populating a Row Using BLOB Images.................................................................... 3-44 3.3.5 Inserting a Row Using BFILE Images........................................................................ 3-45 3.3.6 Populating a Row Using BFILE Images.................................................................... 3-46 3.3.7 Querying a Row............................................................................................................ 3-46 3.3.8 Importing an Image from an External File into the Database............................... 3-47 3.3.9 Retrieving an Image..................................................................................................... 3-48 3.3.10 Retrieving Images Similar to a Comparison Image (Content-Based Retrieval).. 3-50 3.3.11 Creating a Domain Index............................................................................................ 3-52 3.3.12 Retrieving Images Similar to a Comparison Image Using Index Operations (Indexed Content-Based Retrieval) ...................................................................................3-53 3.3.13 Copying an Image........................................................................................................ 3-53 3.3.14 Converting an Image Format...................................................................................... 3-54 3.3.15 Copying and Converting in One Step....................................................................... 3-54 3.3.16 Extending interMedia with a New Type................................................................... 3-55 3.3.17 Using Image Types with Object Views..................................................................... 3-57 3.3.18 Scripts for Creating and Populating an Image Table from a BFILE Data Source 3-59 3.3.19 Scripts for Populating an Image Table from an HTTP Data Source..................... 3-66 3.3.20 Addressing Globalization Support Issues................................................................ 3-68 3.4 Video Data Examples.......................................................................................................... 3-69 3.4.1 Defining a Clip Object................................................................................................. 3-70 3.4.2 Creating an Object Table ClipsTable......................................................................... 3-70 3.4.3 Creating a List Object Containing a List of Clips.................................................... 3-71 3.4.4 Defining the Implementation of the clipList Object................................................ 3-71 3.4.5 Creating a Video Object and a Video Table.............................................................. 3-71 3.4.6 Inserting a Video Clip into the ClipsTable Table..................................................... 3-72 3.4.7 Inserting a Row into the VideoTable Table.............................................................. 3-73 3.4.8 Loading a Video into the ClipsTable Table.............................................................. 3-73 3.4.9 Inserting a Reference to a Clip Object into the Clips List in the VideoTable Table....... .............................................................................................................................3-74 3.4.10 Inserting a Reference to a Video Object into the Clip............................................. 3-75 3.4.11 Retrieving a Video Clip from the VideoTable Table............................................... 3-76 3.4.12 Extending interMedia to Support a New Video Data Format............................... 3-76 vi 3.4.13 Extending interMedia with a New Object Type...................................................... 3-77 3.4.14 Using Video Types with Object Views..................................................................... 3-77 3.4.15 Scripts for Creating and Populating a Video Table from a BFILE Data Source.. 3-79 3.5 Extending interMedia to Support a New Data Source................................................... 3-86 4 Ensuring Future Compatibility with Evolving interMedia Object Types 4.1 When and How to Call the Compatibility Initialization Function................................ 4-1 compatibilityInit( )................................................................................................................ 4-3 5 Common Methods for interMedia Object Types Reference Information 5.1 Important Notes.................................................................................................................... 5-2 5.2 Methods.................................................................................................................................. 5-3 clearLocal( )............................................................................................................................ 5-5 closeSource( ).......................................................................................................................... 5-6 deleteContent( )..................................................................................................................... 5-8 export( )................................................................................................................................... 5-9 getBFILE( )............................................................................................................................ 5-13 getContent( )......................................................................................................................... 5-15 getMimeType( )................................................................................................................... 5-17 getSource( )........................................................................................................................... 5-19 getSourceLocation( )........................................................................................................... 5-21 getSourceName( )................................................................................................................ 5-22 getSourceType( ).................................................................................................................. 5-23 getUpdateTime( )................................................................................................................. 5-25 isLocal( )................................................................................................................................ 5-26 openSource( )....................................................................................................................... 5-27 processSourceCommand( )................................................................................................ 5-29 readFromSource( )............................................................................................................... 5-32 setLocal( ).............................................................................................................................. 5-34 setMimeType( ).................................................................................................................... 5-35 setSource( )........................................................................................................................... 5-37 setUpdateTime( )................................................................................................................. 5-39 vii trimSource( )......................................................................................................................... 5-40 writeToSource( )................................................................................................................... 5-42 6 ORDAudio Reference Information 6.1 Object Types........................................................................................................................... 6-2 ORDAudio Object Type........................................................................................................ 6-3 6.2 Constructors........................................................................................................................... 6-7 init( )........................................................................................................................................ 6-8 init(srcType,srcLocation,srcName)................................................................................... 6-10 6.3 Methods................................................................................................................................ 6-12 6.3.1 Example Table Definitions.......................................................................................... 6-16 checkProperties( )................................................................................................................ 6-17 getAllAttributes( )................................................................................................................ 6-19 getAttribute( )....................................................................................................................... 6-21 getAudioDuration( )............................................................................................................ 6-23 getContentLength( )............................................................................................................ 6-24 getCompressionType( )...................................................................................................... 6-25 getContentInLob( ).............................................................................................................. 6-26 getDescription( ).................................................................................................................. 6-28 getEncoding( )...................................................................................................................... 6-29 getFormat( ).......................................................................................................................... 6-30 getNumberOfChannels( )................................................................................................... 6-31 getSampleSize( )................................................................................................................... 6-32 getSamplingRate( ).............................................................................................................. 6-33 import( )................................................................................................................................ 6-34 importFrom( )....................................................................................................................... 6-36 processAudioCommand( )................................................................................................. 6-39 setAudioDuration( )............................................................................................................ 6-42 setCompressionType( )....................................................................................................... 6-43 setDescription( )................................................................................................................... 6-44 setEncoding( )....................................................................................................................... 6-46 viii setFormat( ).......................................................................................................................... 6-47 setKnownAttributes( )........................................................................................................ 6-49 setNumberOfChannels( )................................................................................................... 6-51 setProperties( )..................................................................................................................... 6-52 setSamplingRate( ).............................................................................................................. 6-54 setSampleSize( )................................................................................................................... 6-55 6.4 Packages or PL/SQL Plug-ins........................................................................................... 6-56 6.4.1 ORDPLUGINS.ORDX_DEFAULT_AUDIO Package............................................. 6-56 6.4.2 Extending interMedia to Support a New Audio Data Format.............................. 6-59 7 ORDDoc Reference Information 7.1 Object Types........................................................................................................................... 7-2 ORDDoc Object Type............................................................................................................ 7-3 7.2 Constructors........................................................................................................................... 7-5 init( )........................................................................................................................................ 7-6 init(srcType,srcLocation,srcName)..................................................................................... 7-8 7.3 Methods................................................................................................................................ 7-10 7.3.1 Example Table Definitions.......................................................................................... 7-12 getContentInLob( ).............................................................................................................. 7-14 getContentLength( )............................................................................................................ 7-16 getFormat.............................................................................................................................. 7-17 import( )................................................................................................................................ 7-18 importFrom( )....................................................................................................................... 7-21 setFormat( ).......................................................................................................................... 7-24 setProperties( )..................................................................................................................... 7-26 7.4 Packages or PL/SQL Plug-ins........................................................................................... 7-29 7.4.1 ORDPLUGINS.ORDX_DEFAULT_DOC Package.................................................. 7-29 7.4.2 Extending interMedia to Support a New Media Data Format.............................. 7-30 8 Image Object Types Reference Information 8.1 ORDImage Object Types...................................................................................................... 8-2 ORDImage Object Type........................................................................................................ 8-3 ix 8.1.1 Constructors.................................................................................................................... 8-6 init( ) for ORDImage............................................................................................................. 8-7 init(srcType,srcLocation,srcName) for ORDImage.......................................................... 8-9 8.1.2 Methods......................................................................................................................... 8-10 8.1.3 Example Table Definitions.......................................................................................... 8-13 checkProperties.................................................................................................................... 8-15 copy( ).................................................................................................................................... 8-16 getCompressionFormat...................................................................................................... 8-18 getContentFormat................................................................................................................ 8-19 getContentLength................................................................................................................ 8-20 getFileFormat....................................................................................................................... 8-21 getHeight.............................................................................................................................. 8-22 getWidth............................................................................................................................... 8-23 import( )................................................................................................................................ 8-24 importFrom( )....................................................................................................................... 8-26 process( )............................................................................................................................... 8-29 processCopy( )...................................................................................................................... 8-34 setProperties......................................................................................................................... 8-36 setProperties( ) for Foreign Images................................................................................... 8-38 8.2 ORDImageSignature Object Type..................................................................................... 8-40 ORDImageSignature Object Type..................................................................................... 8-42 8.2.1 Constructors.................................................................................................................. 8-42 init( ) for ORDImageSignature.......................................................................................... 8-44 8.2.2 Methods......................................................................................................................... 8-45 evaluateScore( ).................................................................................................................... 8-46 generateSignature( )............................................................................................................ 8-48 isSimilar( )............................................................................................................................. 8-49 8.2.3 ORDImageSignature Operators................................................................................. 8-51 IMGSimilar Operator.......................................................................................................... 8-52 IMGScore Operator............................................................................................................. 8-56 x

See more

The list of books you might like

Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.