wiki:UNPLANNED_APP_RESOURCE_PREVIEW_DISPLAY_R0
Last modified 16 years ago Last modified on 07/07/09 13:59:36

Error: Macro BackLinksMenu(None) failed
compressed data is corrupt

Error: Macro TicketQuery(summary=UNPLANNED_APP_RESOURCE_PREVIEW_DISPLAY_R0, format=table, col=summary|owner|status|type|component|priority|effort|importance, rows=description|analysis_owners|analysis_reviewers|analysis_score|design_owners|design_reviewers|design_score|implementation_owners|implementation_reviewers|implementation_score|test_owners|test_reviewers|test_score|) failed
current transaction is aborted, commands ignored until end of transaction block

Analysis

Overview

In addition to APP_RESOURCE_PREVIEW_DISPLAY_R0 should show first frame of a video resource. In the next revisions for this task there should be controls that allow the user to view the entire movie.

Task requirements

  • Implement preview of video resources. It must show the first frame of the video file and act like the image preview for now.
  • Integrate this in resource palate.

Task result

  • The result should be source code.

Implementation idea

Use APP_RESOURCE_PREVIEW_DISPLAY_R0 for implementation ideas

APP_RESOURCE_PREVIEW_DISPLAY_R0

How to demo

  • Import video file inside the application.
  • Select a video resource from the resource palette and show the preview

Design

When an user clicks on an element, which is video in the Resources palette, a preview will be shown in the Detail view palette.
For solving this task I will do the following things:

  • Add new method in the org.sophie2.base.media.engines.VideoEngine interface called getPreview, with one argument of type org.sophie2.base.media.interfaces.MediaSource;
  • Implement this method in org.sophie2.main.media.fobs.JMFEngine;
  • Add new extension to sophie's extension point in org.sophie2.main.func.media.MainFuncMediaModule;
  • Add new class called org.sophie2.main.func.media.view.VideoContentPreviewProvider, which:
    • implements org.sophie2.main.func.resources.ResourcePreviewProvider;
    • contains an inner class called VideoResourcePreview, which represents the SwingVisualElement (one JPanel, on which the preview image is drawn) and for that reason it implements SwingVisualElement and extends BaseVisualElement. Here the getPreview method is used for taking the preview image;
    • contains one field of type org.sophie2.main.func.media.model.resources.VideoBookResource, which is set through the constructor of VideoResourcePreview.class. This field is used for taking the MediaSource of the concrete video resource, which is an argument of getPreview method.

source:/branches/private/ntraykov/sophie2-platform/doc/uml-design-diagrams/VideoEngine.jpg

source:/branches/private/ntraykov/sophie2-platform/doc/uml-design-diagrams/ResourcePreviewProvider.jpg

Implementation

(Describe and link the implementation results here (from the wiki or the repository).)

Testing

(Place the testing results here.)

Comments

(Write comments for this or later revisions here.)