Opened 14 years ago
Closed 11 years ago
#8807 closed enhancement (fixed)
Various improvements to MovieMacro
| Reported by: | Scott Gifford | Owned by: | Tetsuya Morimoto | 
|---|---|---|---|
| Priority: | normal | Component: | MovieMacro | 
| Severity: | normal | Keywords: | |
| Cc: | Trac Release: | 0.12 | 
Description
I have implemented several improvements to MovieMacro, including:
- Updating to latest version of flowplayer
- Support Image-macro style path arguments for local files (attachment:file.mp4,wiki:TestPage:2357b.mp4, etc.)
- Support for configuring in INI file:
- Default height
- Default width
- Streaming provider
- SWF file URL
 
- Support for setting in macro arguments:
- Starting position for scrubber (startpos)
- Clip start (implemented per Flowplayer docs, seems not to work) (stime)
- Clip duration (duration)
 
- Starting position for scrubber (
Attachments (1)
Change History (14)
Changed 14 years ago by
| Attachment: | moviemacro-sg-8807.patch added | 
|---|
comment:1 Changed 14 years ago by
Note that these also require flowplayer 3.2.7 or (hopefully) newer, currently available from:
comment:2 Changed 11 years ago by
I updated flowplayer's version to 5.5.0.
https://github.com/arielnetworks/TracMovieMacro/commit/b9dfb77f893acd46d8daced6619d4bea76d66b6c
comment:3 Changed 11 years ago by
I changed to set default width, height, splash image using trac.ini like this.
[moviemacro] width = 320px height = 180px splash = test.png
comment:4 Changed 11 years ago by
| Owner: | changed from Louis Cordier to Tetsuya Morimoto | 
|---|---|
| Status: | new → assigned | 
comment:5 Changed 11 years ago by
Replying to sgifford:
- Support Image-macro style path arguments for local files (
attachment:file.mp4,wiki:TestPage:2357b.mp4, etc.)
Yup, that makes using moviemacro easy.
comment:6 Changed 11 years ago by
ImageMacro parses the argument by itself without utility function. I will support restricted simple format only.
https://github.com/edgewall/trac/blob/trunk/trac/wiki/macros.py#L518
comment:7 Changed 11 years ago by
comment:8 Changed 11 years ago by
If the json requirement is the only reason for the Python >= 2.6 restriction in [14231], it would be easy enough to add a fallback:
try: import json except ImportError: import simplejson as json
and also conditionally add simplejson to requirements. For example, see: tracticketchangelogplugin/0.12/setup.py@13960:55#L37
comment:9 Changed 11 years ago by
The plugin supports only 2.6 and later, according to moviemacro/trunk/setup.py@14231:7-8.
However, we can replace with to_json (trac.util.presentation) which is available since Trac 0.12. Because it seems json library is used for only encoding to json string. At least, I think we can simply use json.dumps(query_dict) rather than json.JSONEncoder().encode(query_dict).
comment:10 Changed 11 years ago by
Thank you for good advice. I will replace to_json if possible, then we can remove Python > 2.6 limit. Also, I misunderstood json.dumps function, you're right. :)
comment:11 Changed 11 years ago by
It works and increased maintainability by changeset:14232. Thank you!
comment:12 Changed 11 years ago by
| Trac Release: | 0.11 → 0.12 | 
|---|
This change has been included in 0.3 version (ticket:12046#comment:2).
comment:13 Changed 11 years ago by
| Resolution: | → fixed | 
|---|---|
| Status: | assigned → closed | 




Patch with changes described in #8807