A method and architecture for obtaining a desired frame and identifying a selected frame in an image container. A request for a frame of an image is received. The request may include an identifier that identifies a type of frame. In response thereto, a frame is located corresponding to the identifier and a reference to the frame is provided. In another aspect, a request is received to identify a frame of an image. A determination is made as to what identifier identifies the frame. The identified frame is returned to the requesting component.
|
10. In a computing environment, a method for returning a frame in response to a request for the frame that identifies the type of frame requested, the method comprising:
receiving a request at a decoder from a requesting component for a frame of an image having multiple frames each of a different type, wherein a plurality of the frames of the image is stored in an image container, wherein the request includes an identifier that identifies the type of the requested frame, wherein a frame comprises data that may be used to display a view of the image, and wherein the type of each frame comprises one of a thumbnail type, a full-resolution type, an embedded preview type, a fast preview type, or a raw sensor data type, wherein the decoder is configured to recognize a canonical set of frame names corresponding to each frame type such that each frame type is identifiable by its corresponding name;
locating the requested frame via the identifier; and
providing a reference to the requested frame such that the requesting component determines the type of the received frame based on the request that identifies the type of the requested frame rather than based on an evaluation of the characteristics of the frame received in response to the request.
1. A computer-readable storage medium having computer-executable instructions which when executed perform a method for returning a frame in response to a request for a frame that identifies the type of frame requested, comprising:
receiving a request at a decoder from a requesting component for a frame of an image having multiple frames each of a different type, wherein a plurality of the frames of the image is stored in an image container, wherein the request includes an identifier that identifies the type of the requested frame, wherein a frame comprises data that may be used to display a view of the image, and wherein the type of each frame comprises one of a thumbnail type, a full-resolution type, an embedded preview type, a fast preview type, or a raw sensor data type, wherein the decoder is configured to recognize a canonical set of frame names corresponding to each frame type such that each frame type is identifiable by its corresponding name;
locating the requested frame via the identifier; and
providing a reference to the requested frame such that the requesting component determines the type of the received frame based on the request that identifies the type of the requested frame rather than based on an evaluation of the characteristics of the frame received in response to the request.
16. In a computing environment, a method performed by a processor of a computer for requesting each available frame in a frame container to determine whether a desired frame exists, the method comprising:
obtaining a first frame from a decoder by calling a function of the decoder and providing an index of the first frame, wherein the first frame is stored in a frame container with at least one other frame, and wherein each frame in the container is of a different type that is identifiable by a name of the frame type, wherein the decoder recognizes a canonical set of frame names corresponding to each frame type such that each frame type is identifiable by its corresponding name;
querying the decoder for the type of the first frame;
in response to the query, receiving the name of the first frame, the name comprising a string;
determining whether the first frame is of the desired type by comparing the received name to the name of the desired frame type;
upon determining that the first frame is not the desired type, obtaining a second frame from the decoder by calling the function of the decoder and providing an index of the second frame;
querying the decoder for the type of the second frame;
in response to the query, receiving the name of the second frame, the name comprising a string; and
determining that the second frame is of the desired type by comparing the received name of the second frame to the name of the desired frame type.
2. The computer-readable storage medium of
3. The computer-readable storage medium of
5. The computer-readable storage medium of
6. The computer-readable storage medium of
7. The computer-readable storage medium of
8. The computer-readable storage medium of
9. The computer-readable storage medium of
selecting a type different from the requested type that is closest in size to the requested type and providing a reference to the frame of the different type.
12. The method of
15. The method of
|
The invention relates generally to computers, and more particularly to images.
An image may have several frames—logical and physical—associated with it. A frame may comprise an alternate or specialized representation of the main image or may comprise a separate image in the same container that includes the main image. For example, a typical image container may include a thumbnail frame and a full-resolution image frame. As another example, a Tiff file representing a fax may have several frames in it, each representing a different page of the fax. The data associated with physical frames of an image is usually stored in a container associated with the image. The container may include one or more physical frames and metadata regarding the image.
A physical frame comprises data that is stored in the container that may be used to display a view of the image. For example, a camera picture image container may include a frame that includes raw sensor data of the image.
The data of a logical frame, on the other hand, is not stored in the container of an image; rather, a logical frame may be created upon demand from image data. For example, a preview frame may be created from image data and displayed upon demand. The preview frame may be cached in memory or disposed of after use, but need not be stored in the container.
It may be desirable to associate other frames such as embedded preview, fast preview, full resolution image, and the like with an image. What is needed is a method and system for obtaining a desired frame or identifying a selected frame.
Briefly, the present invention provides a method and architecture for obtaining a desired frame. A request for a frame of an image is received. The request may include an identifier that identifies a type of frame. In response thereto, a frame is located corresponding to the identifier and a reference (e.g., pointer) to the frame is provided.
In another aspect, a selected frame is identified. A request is received to identify a frame of an image. A determination is made as to what identifier identifies the frame. The identifier is returned to the requesting component.
In another aspect, an application programming interface is provided that receives a name parameter. The name parameter identifies a type of frame. In response to receiving the name parameter, a function operates on the name parameter and frames of an image, obtains a reference to a frame of a type corresponding to the parameter.
Other aspects will become apparent from the following detailed description when taken in conjunction with the drawings, in which:
Exemplary Operating Environment
The invention is operational with numerous other general purpose or special purpose computing system environments or configurations. Examples of well known computing systems, environments, and/or configurations that may be suitable for use with the invention include, but are not limited to, personal computers, server computers, hand-held or laptop devices, multiprocessor systems, microcontroller-based systems, set top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, distributed computing environments that include any of the above systems or devices, and the like.
The invention may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, and so forth, which perform particular tasks or implement particular abstract data types. The invention may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
With reference to
Computer 110 typically includes a variety of computer-readable media. Computer-readable media can be any available media that can be accessed by the computer 110 and includes both volatile and nonvolatile media, and removable and non-removable media. By way of example, and not limitation, computer-readable media may comprise computer storage media and communication media. Computer storage media includes both volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer-readable instructions, data structures, program modules, or other data. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other medium which can be used to store the desired information and which can accessed by the computer 110. Communication media typically embodies computer-readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism and includes any information delivery media. The term “modulated data signal” means a signal that has one or more of its characteristics set or changed in such a manner as to encode information in the signal. By way of example, and not limitation, communication media includes wired media such as a wired network or direct-wired connection, and wireless media such as acoustic, RF, infrared and other wireless media. Combinations of the any of the above should also be included within the scope of computer-readable media.
The system memory 130 includes computer storage media in the form of volatile and/or nonvolatile memory such as read only memory (ROM) 131 and random access memory (RAM) 132. A basic input/output system 133 (BIOS), containing the basic routines that help to transfer information between elements within computer 110, such as during start-up, is typically stored in ROM 131. RAM 132 typically contains data and/or program modules that are immediately accessible to and/or presently being operated on by processing unit 120. By way of example, and not limitation,
The computer 110 may also include other removable/non-removable, volatile/nonvolatile computer storage media. By way of example only,
The drives and their associated computer storage media, discussed above and illustrated in
The computer 110 may operate in a networked environment using logical connections to one or more remote computers, such as a remote computer 180. The remote computer 180 may be a personal computer, a server, a router, a network PC, a peer device or other common network node, and typically includes many or all of the elements described above relative to the computer 110, although only a memory storage device 181 has been illustrated in
When used in a LAN networking environment, the computer 110 is connected to the LAN 171 through a network interface or adapter 170. When used in a WAN networking environment, the computer 110 typically includes a modem 172 or other means for establishing communications over the WAN 173, such as the Internet. The modem 172, which may be internal or external, may be connected to the system bus 121 via the user input interface 160 or other appropriate mechanism. In a networked environment, program modules depicted relative to the computer 110, or portions thereof, may be stored in the remote memory storage device. By way of example, and not limitation, FIG. 1 illustrates remote application programs 185 as residing on memory device 181. It will be appreciated that the network connections shown are exemplary and other means of establishing a communications link between the computers may be used.
Interfaces
A programming interface (or more simply, interface) may be viewed as any mechanism, process, or protocol for enabling one or more segment(s) of code to communicate with or access the functionality provided by one or more other segment(s) of code. Alternatively, a programming interface may be viewed as one or more mechanism(s), method(s), function call(s), module(s), object(s), and the like of a component of a system capable of communicative coupling to one or more mechanism(s), method(s), function call(s), module(s), and the like of other component(s). The term “segment of code” is intended to include one or more instructions or lines of code, and includes, for example, code modules, objects, subroutines, functions, and so on, regardless of the terminology applied or whether the code segments are separately compiled, or whether the code segments are provided as source, intermediate, or object code, whether the code segments are utilized in a runtime system or process, or whether they are located on the same or different machines or distributed across multiple machines, or whether the functionality represented by the segments of code are implemented wholly in software, wholly in hardware, or a combination of hardware and software.
Notionally, a programming interface may be viewed generically, as shown in
Aspects of such a programming interface may include the method whereby the first code segment transmits information (where “information” is used in its broadest sense and includes data, commands, requests, etc.) to the second code segment; the method whereby the second code segment receives the information; and the structure, sequence, syntax, organization, schema, timing, and content of the information. In this regard, the underlying transport medium itself may be unimportant to the operation of the interface, whether the medium be wired or wireless, or a combination of both, as long as the information is transported in the manner defined by the interface. In certain situations, information may not be passed in one or both directions in the conventional sense, as the information transfer may be either via another mechanism (e.g., information placed in a buffer, file, etc. separate from information flow between the code segments) or non-existent, as when one code segment simply accesses functionality performed by a second code segment. Any or all of these aspects may be important in a given situation, for example, depending on whether the code segments are part of a system in a loosely coupled or tightly coupled configuration, and so this list should be considered illustrative and non-limiting.
This notion of a programming interface is known to those skilled in the art and is clear from the foregoing detailed description. There are, however, other ways to implement a programming interface, and, unless expressly excluded, these too are intended to be encompassed by the claims set forth at the end of this specification. Such other ways may appear to be more sophisticated or complex than the simplistic view of
A. Factoring
A communication from one code segment to another may be accomplished indirectly by breaking the communication into multiple discrete communications. This is depicted schematically in
As illustrated in
The factoring of interfaces may also follow associative, commutative, and other mathematical properties such that the factoring may be difficult to recognize. For instance, ordering of operations may be unimportant, and consequently, a function carried out by an interface may be carried out well in advance of reaching the interface, by another piece of code or interface, or performed by a separate component of the system. Moreover, one of ordinary skill in the programming arts can appreciate that there are a variety of ways of making different function calls that achieve the same result.
B. Redefinition
In some cases, it may be possible to ignore, add, or redefine certain aspects (e.g., parameters) of a programming interface while still accomplishing the intended result. This is illustrated in
Precision may very well be a meaningful parameter to some downstream or other portion of the computing system; however, once it is recognized that precision is not necessary for the narrow purpose of calculating the square, it may be replaced or ignored. For example, instead of passing a valid precision value, a meaningless value such as a birth date could be passed without adversely affecting the result. Similarly, as shown in
C. Inline Coding
It may also be feasible to merge some or all of the functionality of two separate code modules such that the “interface” between them changes form. For example, the functionality of
For a concrete example, consider that the interface 210 from
D. Divorce
A communication from one code segment to another may be accomplished indirectly by breaking the communication into multiple discrete communications. This is depicted schematically in
Similarly, as shown in
E. Rewriting
Yet another possible variant is to dynamically rewrite the code to replace the interface functionality with something else but which achieves the same overall result. For example, there may be a system in which a code segment presented in an intermediate language (e.g. Microsoft IL, Java® ByteCode, etc.) is provided to a Just-in-Time (JIT) compiler or interpreter in an execution environment (such as that provided by the .Net framework, the Java® runtime environment, or other similar runtime type environments). The JIT compiler may be written so as to dynamically convert the communications from the 1st Code Segment to the 2nd Code Segment, i.e., to conform them to a different interface as may be required by the 2nd Code Segment (either the original or a different 2nd Code Segment). This is depicted in
As can be seen in
It is also noted that the above-described scenarios for achieving the same or similar result as an interface via alternative embodiments may also be combined in various ways, serially and/or in parallel, or with other intervening code. Thus, the alternative embodiments presented above are not mutually exclusive and may be mixed, matched, and combined to produce the same or equivalent scenarios to the generic scenarios presented in
Obtaining Frame by Frame Type and Frame Type of Selected Frame
Each of the requesting component 910, the codecs component 915, and the decoder 920 may comprise code that executes on or hardware associated with a computer, such as the computer system 120 of
In one embodiment, the requesting component 910 instantiates a decoder by communicating with the codecs component 915 and passing a file name or stream object. After instantiating the decoder 920, the requesting component 910 may then request a frame from the decoder 920 by passing a frame type (e.g., “preview”) to the decoder 920. If the frame comprises a logical frame, the decoder 920 may then construct the frame or retrieve it from cache if it was previously constructed and cached in memory. If the frame is a physical frame, the decoder 920 may retrieve the frame from the image container 925. The decoder 920 may then pass a pointer to the frame (or an object that includes the frame) to the requesting component 910.
In accordance with an aspect of the present invention, the requesting component 910 may request a frame by frame type from the decoder 920. For example, the requesting component 910 may send a string (e.g., “preview”) to the decoder 920 to request a particular type of frame (e.g., the preview frame). As another example, the requesting component may send a globally unique identifier (GUID) that identifies a particular type of frame. Upon receiving a request for a frame by frame type, the decoder 920 searches the image container 925 (or an index related thereto) to obtain a frame corresponding to the name. If the frame exists or can be constructed by the decoder 920, the decoder returns the appropriate frame to the requesting component 910. Otherwise, an error code may be returned.
In the past, decoders did not generally have the ability to return frames by frame name. It was up to the requesting component 910 to determine based on size or some other characteristic of the frame what type of frame the decoder 920 had provided.
In accordance with another aspect of the present invention, the requesting component 910 may enumerate through the frames provided by the decoder 920 and may query the decoder 920 as to the type of any particular frame. In response to such a query, the decoder 920 may return a string or (GUID) identifying the type of frame or a value in an enumeration.
In one embodiment, the decoder 920 recognizes a “canonical” set of frame names including thumbnail, raw sensor data, embedded preview, fast screen resolution preview, and full resolution image. If an exact match for a frame does not exist in an image container, the decoder 920 may return a closest match. For example, the decoder 920 may receive a request for a preview frame. A container may store a thumbnail frame and a full image frame. In response to the request, the decoder 920 may determine whether the thumbnail frame or the full image frame is closest in size to the size of the preview frame and return either the thumbnail frame or the full image frame accordingly.
In one embodiment, the set of frames may be locked and not modifiable except through a codecs update. In another embodiment, the set of frames may be modified by an application, user, or otherwise without departing from the spirit or scope of the present invention.
At block 1110, a decoder is instantiated. This may be done by calling a codecs component with a file name or stream object as previously indicated.
At block 1115, the requesting component requests a frame (by asking for a frame of a frame type) from the decoder. This may be done by calling a method of the decoder with a string or GUID identifying the requested frame type.
At block 1120, a determination is made as to whether an exact match exists for the requested frame. If so, the actions continue at block 1125; otherwise, the actions continue at block 1130. In some embodiments only exact matches are accepted. If a requesting component attempts to request a frame with a frame name or GUID that is not valid, an error is returned.
At block 1125, the frame is returned. The frame may be returned as reference (e.g., pointer) to an object having methods to access the data in the frame.
At block 1130, the frame that is the closest match to the requested frame is returned. For example, a thumbnail may be returned for a request for a preview frame.
At block 1135, the requesting component performs an operation with the frame as desired.
At block 1140, the actions end.
At block 1210, a decoder is instantiated. At block 1215, the first frame is obtained from the decoder. This may be accomplished by calling the decoder and providing an index of the first frame (e.g., 0).
At block 1220, the type of the frame is obtained. The frame object may include an interface that allows a component to ask what type of frame the frame object includes. In response to a query, the frame object may return a string or GUID, for example.
At block 1125, the requesting component determines whether the frame is of the type desired. If not, processing branches to block 1230; otherwise, processing branches to block 1240.
At block 1230, a determination is made as to whether the current frame is the last frame of the container. If so, processing branches to block 1245; otherwise, processing branches to block 1235. The decoder may provide an interface that allows a requesting component to query how many frames exist in a container. If the requesting component keeps track of the frames it has requested, it can know when it has obtained all the available frames.
At block 1235, the next frame is obtained from the decoder. The actions associated with 1220-1235 may be repeated until either all the frames in the container are exhausted or until a desired frame type is found.
At block 1240, the actions end in success having found the desired frame. At block 1245, the actions end in failure having not found the desired frame before running out of frames.
In some embodiments, both the ability to retrieve a frame by name (e.g., frame type) and to query for a frame type may be provided.
As can be seen from the foregoing detailed description, there is provided a method and architecture for obtaining a desired frame by name and to identify a selected frame. While the invention is susceptible to various modifications and alternative constructions, certain illustrated embodiments thereof are shown in the drawings and have been described above in detail. It should be understood, however, that there is no intention to limit the invention to the specific forms disclosed, but on the contrary, the intention is to cover all modifications, alternative constructions, and equivalents falling within the spirit and scope of the invention.
Albert, David, Kasperkiewicz, Tomasz S. M., Turner, Jr., Richard S.
Patent | Priority | Assignee | Title |
Patent | Priority | Assignee | Title |
5586316, | Jul 09 1993 | Hitachi, Ltd. | System and method for information retrieval with scaled down image |
5666215, | Feb 25 1994 | Eastman Kodak Company | System and method for remotely selecting photographic images |
6072586, | Sep 04 1996 | Intellectual Ventures Fund 83 LLC | Computer program product for storing preselected zoom and crop data |
6829624, | Jan 29 2001 | FUJIFILM Corporation | Data processing method for digital camera |
6993196, | Mar 18 2002 | Monument Peak Ventures, LLC | Digital image storage method |
7307636, | Dec 26 2001 | RPX Corporation | Image format including affective information |
7447369, | Mar 07 2003 | RICOH CO , LTD | Communication of compressed digital images |
7460724, | Mar 07 2003 | RICOH CO , LTD | JPP-stream to JPEG 2000 codestream conversion |
7548927, | Apr 21 2005 | Microsoft Technology Licensing, LLC | Abstracted metadata policy component and related architecture |
20030028896, | |||
20040189695, | |||
20050203920, | |||
20060088228, |
Executed on | Assignor | Assignee | Conveyance | Frame | Reel | Doc |
Apr 19 2005 | TURNER, JR , RICHARD S | Microsoft Corporation | ASSIGNMENT OF ASSIGNORS INTEREST SEE DOCUMENT FOR DETAILS | 016096 | /0932 | |
Apr 19 2005 | ALBERT, DAVID | Microsoft Corporation | ASSIGNMENT OF ASSIGNORS INTEREST SEE DOCUMENT FOR DETAILS | 016096 | /0932 | |
Apr 19 2005 | KASPERKIEWICZ, TOMASZ S M | Microsoft Corporation | ASSIGNMENT OF ASSIGNORS INTEREST SEE DOCUMENT FOR DETAILS | 016096 | /0932 | |
Apr 20 2005 | Microsoft Corporation | (assignment on the face of the patent) | / | |||
Oct 14 2014 | Microsoft Corporation | Microsoft Technology Licensing, LLC | ASSIGNMENT OF ASSIGNORS INTEREST SEE DOCUMENT FOR DETAILS | 034543 | /0001 |
Date | Maintenance Fee Events |
Mar 23 2010 | ASPN: Payor Number Assigned. |
Mar 18 2013 | M1551: Payment of Maintenance Fee, 4th Year, Large Entity. |
Aug 17 2017 | M1552: Payment of Maintenance Fee, 8th Year, Large Entity. |
Oct 18 2021 | REM: Maintenance Fee Reminder Mailed. |
Apr 04 2022 | EXP: Patent Expired for Failure to Pay Maintenance Fees. |
Date | Maintenance Schedule |
Mar 02 2013 | 4 years fee payment window open |
Sep 02 2013 | 6 months grace period start (w surcharge) |
Mar 02 2014 | patent expiry (for year 4) |
Mar 02 2016 | 2 years to revive unintentionally abandoned end. (for year 4) |
Mar 02 2017 | 8 years fee payment window open |
Sep 02 2017 | 6 months grace period start (w surcharge) |
Mar 02 2018 | patent expiry (for year 8) |
Mar 02 2020 | 2 years to revive unintentionally abandoned end. (for year 8) |
Mar 02 2021 | 12 years fee payment window open |
Sep 02 2021 | 6 months grace period start (w surcharge) |
Mar 02 2022 | patent expiry (for year 12) |
Mar 02 2024 | 2 years to revive unintentionally abandoned end. (for year 12) |