Java Doc for FramePositioningControl.java in  » 6.0-JDK-Modules » j2me » javax » microedition » media » control » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » 6.0 JDK Modules » j2me » javax.microedition.media.control 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


javax.microedition.media.control.FramePositioningControl

FramePositioningControl
public interface FramePositioningControl extends javax.microedition.media.Control(Code)
The FramePositioningControl is the interface to control precise positioning to a video frame for Players.

Frame numbers for a bounded movie must be non-negative and should generally begin with 0, corresponding to media time 0. Each video frame of a movie must have a unique frame number that is one bigger than the previous frame.

There is a direct mapping between the frame number and the media time of a video frame; although not all Players can compute that relationship. For Players that can compute that relationship, the mapFrameToTime and mapTimeToFrame methods can be used.

When a Player is seeked or skipped to a new video frame, the media time of the Player will be changed to the media time of the corresponding video frame.

As much as possible, the methods in this interface should provide frame-level accuracy with a plus-or-minus-one-frame margin of error to accommodate for round-off errors. However, if the content has inaccurate frame positioning information, implementations may not be able to provide the necessary frame-level accuracy. For instance, some media content may contain wrong time-stamps or have missing frames. In any case, the results of each operation should represent the best effort. For the seek and skip methods, the returned value should indicate the actual new location or the number of frames skipped.





Method Summary
 longmapFrameToTime(int frameNumber)
     Converts the given frame number to the corresponding media time. The method only performs the calculations.
 intmapTimeToFrame(long mediaTime)
     Converts the given media time to the corresponding frame number. The method only performs the calculations.
 intseek(int frameNumber)
     Seek to a given video frame. The media time of the Player will be updated to reflect the new position set.

This method can be called on a stopped or started Player. If the Player is in the Started state, this method may cause the Player to change states.

 intskip(int framesToSkip)
     Skip a given number of frames from the current position. The media time of the Player will be updated to reflect the new position set.

This method can be called on a stopped or started Player. If the Player is in the Started state, the current position is changing.




Method Detail
mapFrameToTime
long mapFrameToTime(int frameNumber)(Code)
Converts the given frame number to the corresponding media time. The method only performs the calculations. It does not position the media to the given frame.
Parameters:
  frameNumber - the input frame number for the conversion. the converted media time in microseconds for the given frame. If the conversion fails, -1 is returned.



mapTimeToFrame
int mapTimeToFrame(long mediaTime)(Code)
Converts the given media time to the corresponding frame number. The method only performs the calculations. It does not position the media to the given media time.

The frame returned is the nearest frame that has a media time less than or equal to the given media time.

mapTimeToFrame(0) must not fail and must return the frame number of the first frame.
Parameters:
  mediaTime - the input media time for the conversion in microseconds. the converted frame number for the given media time. If the conversion fails, -1 is returned.




seek
int seek(int frameNumber)(Code)
Seek to a given video frame. The media time of the Player will be updated to reflect the new position set.

This method can be called on a stopped or started Player. If the Player is in the Started state, this method may cause the Player to change states. If that happens, the appropriate transition events will be posted by the Player when its state changes.

If the given frame number is less than the first or larger than the last frame number in the media, seek will jump to either the first or the last frame respectively.
Parameters:
  frameNumber - the frame to seek to. the actual frame that the Player has seeked to.




skip
int skip(int framesToSkip)(Code)
Skip a given number of frames from the current position. The media time of the Player will be updated to reflect the new position set.

This method can be called on a stopped or started Player. If the Player is in the Started state, the current position is changing. Hence, the frame actually skipped to will not be exact.

If the Player is in the Started state, this method may cause the Player to change states. If that happens, the appropriate transition events will be posted.

If the given framesToSkip will cause the position to extend beyond the first or last frame, skip will jump to the first or last frame respectively.
Parameters:
  framesToSkip - the number of frames to skip from the currentposition. If framesToSkip is positive, it will seek forwardby framesToSkip number of frames. If framesToSkip is negative, it will seek backward by framesToSkip number of frames.e.g. skip(-1) will seek backward one frame. the actual number of frames skipped.




www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.