Recherche avancée

Médias (1)

Mot : - Tags -/bug

Autres articles (72)

  • Qu’est ce qu’un éditorial

    21 juin 2013, par

    Ecrivez votre de point de vue dans un article. Celui-ci sera rangé dans une rubrique prévue à cet effet.
    Un éditorial est un article de type texte uniquement. Il a pour objectif de ranger les points de vue dans une rubrique dédiée. Un seul éditorial est placé à la une en page d’accueil. Pour consulter les précédents, consultez la rubrique dédiée.
    Vous pouvez personnaliser le formulaire de création d’un éditorial.
    Formulaire de création d’un éditorial Dans le cas d’un document de type éditorial, les (...)

  • Creating farms of unique websites

    13 avril 2011, par

    MediaSPIP platforms can be installed as a farm, with a single "core" hosted on a dedicated server and used by multiple websites.
    This allows (among other things) : implementation costs to be shared between several different projects / individuals rapid deployment of multiple unique sites creation of groups of like-minded sites, making it possible to browse media in a more controlled and selective environment than the major "open" (...)

  • Contribute to a better visual interface

    13 avril 2011

    MediaSPIP is based on a system of themes and templates. Templates define the placement of information on the page, and can be adapted to a wide range of uses. Themes define the overall graphic appearance of the site.
    Anyone can submit a new graphic theme or template and make it available to the MediaSPIP community.

Sur d’autres sites (5275)

  • Solved : ffmpeg : How can a MOV with transparent background be created ?

    25 mars 2017, par Mat

    (Remark : the error sat, as usual, between back-rest and keyboard. Thanks, Mulvya !)

    Hi, specialists !

    I’m trying - with no success at all - to convert the green pixels of a background into transparent ones and output the result as clip with ffmpeg. N.b. I do not want to lay the clip over anything ; I’m not having a problem with that. What I want is a clip with transparent background for the OpenShot video editor (the chromakey filter of which doesn’t work satisfyingly).

    What I have tried (amongst a felt 1 zillion other things over the last 15 hrs.) was

    ffmpeg.exe -i in.mov -vf chromakey=0x008001:0.115:0.0 -c:v qtrle out.mov

    but the pixels simply would not be transparent. Seemingly, nothing happens. I reckon the filter is ok, because it works fine in a complex chain (overlaying a background image).

    The output of ffprompt -show_stream -show_format of out.mov is as follows :

    [STREAM]
    index=0
    codec_name=qtrle
    codec_long_name=QuickTime Animation (RLE) video
    profile=unknown
    codec_type=video
    codec_time_base=1/30
    codec_tag_string=rle
    codec_tag=0x20656c72
    width=1920
    height=1080
    coded_width=1920
    coded_height=1080
    has_b_frames=0
    sample_aspect_ratio=1:1
    display_aspect_ratio=16:9
    pix_fmt=bgra
    level=-99
    color_range=N/A
    color_space=unknown
    color_transfer=unknown
    color_primaries=unknown
    chroma_location=unspecified
    field_order=progressive
    timecode=N/A
    refs=1
    id=N/A
    r_frame_rate=30/1
    avg_frame_rate=30/1
    time_base=1/15360
    start_pts=0
    start_time=0.000000
    duration_ts=54789
    duration=3.566992
    bit_rate=822383192
    max_bit_rate=N/A
    bits_per_raw_sample=N/A
    nb_frames=107
    nb_read_frames=N/A
    nb_read_packets=N/A
    DISPOSITION:default=1
    DISPOSITION:dub=0
    DISPOSITION:original=0
    DISPOSITION:comment=0
    DISPOSITION:lyrics=0
    DISPOSITION:karaoke=0
    DISPOSITION:forced=0
    DISPOSITION:hearing_impaired=0
    DISPOSITION:visual_impaired=0
    DISPOSITION:clean_effects=0
    DISPOSITION:attached_pic=0
    DISPOSITION:timed_thumbnails=0
    TAG:language=eng
    TAG:handler_name=DataHandler
    TAG:encoder=Lavc57.64.101 qtrle
    [/STREAM]
    [STREAM]
    index=1
    codec_name=aac
    codec_long_name=AAC (Advanced Audio Coding)
    profile=LC
    codec_type=audio
    codec_time_base=1/44100
    codec_tag_string=mp4a
    codec_tag=0x6134706d
    sample_fmt=fltp
    sample_rate=44100
    channels=2
    channel_layout=stereo
    bits_per_sample=0
    id=N/A
    r_frame_rate=0/0
    avg_frame_rate=0/0
    time_base=1/44100
    start_pts=926
    start_time=0.020998
    duration_ts=157481
    duration=3.570998
    bit_rate=132103
    max_bit_rate=132103
    bits_per_raw_sample=N/A
    nb_frames=153
    nb_read_frames=N/A
    nb_read_packets=N/A
    DISPOSITION:default=1
    DISPOSITION:dub=0
    DISPOSITION:original=0
    DISPOSITION:comment=0
    DISPOSITION:lyrics=0
    DISPOSITION:karaoke=0
    DISPOSITION:forced=0
    DISPOSITION:hearing_impaired=0
    DISPOSITION:visual_impaired=0
    DISPOSITION:clean_effects=0
    DISPOSITION:attached_pic=0
    DISPOSITION:timed_thumbnails=0
    TAG:language=eng
    TAG:handler_name=DataHandler
    [/STREAM]
    [FORMAT]
    filename=out.mov
    nb_streams=2
    nb_programs=0
    format_name=mov,mp4,m4a,3gp,3g2,mj2
    format_long_name=QuickTime / MOV
    start_time=0.000000
    duration=3.567000
    size=366708874
    bit_rate=822447712
    probe_score=100
    TAG:major_brand=qt
    TAG:minor_version=512
    TAG:compatible_brands=qt
    TAG:encoder=Lavf57.56.101
    [/FORMAT]

    I have a "sample" clip which shows the behaviour I want, with the following stream and information :

    [STREAM]
    index=0
    codec_name=qtrle
    codec_long_name=QuickTime Animation (RLE) video
    profile=unknown
    codec_type=video
    codec_time_base=1/24
    codec_tag_string=rle
    codec_tag=0x20656c72
    width=1920
    height=1080
    coded_width=1920
    coded_height=1080
    has_b_frames=0
    sample_aspect_ratio=0:1
    display_aspect_ratio=0:1
    pix_fmt=bgra
    level=-99
    color_range=N/A
    color_space=unknown
    color_transfer=unknown
    color_primaries=unknown
    chroma_location=unspecified
    field_order=progressive
    timecode=N/A
    refs=1
    id=N/A
    r_frame_rate=24/1
    avg_frame_rate=24/1
    time_base=1/12288
    start_pts=0
    start_time=0.000000
    duration_ts=74760
    duration=6.083984
    bit_rate=49226848
    max_bit_rate=N/A
    bits_per_raw_sample=N/A
    nb_frames=146
    nb_read_frames=N/A
    nb_read_packets=N/A
    DISPOSITION:default=1
    DISPOSITION:dub=0
    DISPOSITION:original=0
    DISPOSITION:comment=0
    DISPOSITION:lyrics=0
    DISPOSITION:karaoke=0
    DISPOSITION:forced=0
    DISPOSITION:hearing_impaired=0
    DISPOSITION:visual_impaired=0
    DISPOSITION:clean_effects=0
    DISPOSITION:attached_pic=0
    DISPOSITION:timed_thumbnails=0
    TAG:language=eng
    TAG:handler_name=DataHandler
    TAG:encoder=Lavc57.24.102 qtrle
    [/STREAM]
    [STREAM]
    index=1
    codec_name=aac
    codec_long_name=AAC (Advanced Audio Coding)
    profile=LC
    codec_type=audio
    codec_time_base=1/48000
    codec_tag_string=mp4a
    codec_tag=0x6134706d
    sample_fmt=fltp
    sample_rate=48000
    channels=2
    channel_layout=stereo
    bits_per_sample=0
    id=N/A
    r_frame_rate=0/0
    avg_frame_rate=0/0
    time_base=1/48000
    start_pts=0
    start_time=0.000000
    duration_ts=293856
    duration=6.122000
    bit_rate=53537
    max_bit_rate=128000
    bits_per_raw_sample=N/A
    nb_frames=288
    nb_read_frames=N/A
    nb_read_packets=N/A
    DISPOSITION:default=1
    DISPOSITION:dub=0
    DISPOSITION:original=0
    DISPOSITION:comment=0
    DISPOSITION:lyrics=0
    DISPOSITION:karaoke=0
    DISPOSITION:forced=0
    DISPOSITION:hearing_impaired=0
    DISPOSITION:visual_impaired=0
    DISPOSITION:clean_effects=0
    DISPOSITION:attached_pic=0
    DISPOSITION:timed_thumbnails=0
    TAG:language=eng
    TAG:handler_name=DataHandler
    [/STREAM]
    [FORMAT]
    filename=templateOK.mov
    nb_streams=2
    nb_programs=0
    format_name=mov,mp4,m4a,3gp,3g2,mj2
    format_long_name=QuickTime / MOV
    start_time=0.000000
    duration=6.144000
    size=37478506
    bit_rate=48800138
    probe_score=100
    TAG:major_brand=qt
    TAG:minor_version=512
    TAG:compatible_brands=qt
    TAG:encoder=Lavf57.25.100
    [/FORMAT]

    and I simply am not able to spot the relevant difference.

    Any suggestions would be highly appreciated !

    Cheers,

    Mat

    The input, output and the working template can be found here.

    (The security issue you might see when clicking the link comes from the server certificate being self-signed. You can accept a temporal exception. Btw : The ridiculous file size of the output file will be the next nut to crack. Probably s.t. about compression.)

  • Creating buttons with Imagick

    9 juin 2010, par Mikko Koppanen — Imagick, PHP stuff

    A fellow called kakapo asked me to create a button with Imagick. He had an image of the button and a Photoshop tutorial but unfortunately the tutorial was in Chinese. My Chinese is a bit rusty so it will take a little longer to create that specific button ;)

    The button in this example is created after this tutorial http://xeonfx.com/tutorials/easy-button-tutorial/ (yes, I googled “easy button tutorial”). The code and the button it creates are both very simple but the effect looks really nice.

    Here we go with the code :

    1. < ?php
    2.  
    3. /* Create a new Imagick object */
    4. $im = new Imagick() ;
    5.  
    6. /* Create empty canvas */
    7. $im->newImage( 200, 200, "white", "png" ) ;
    8.  
    9. /* Create the object used to draw */
    10. $draw = new ImagickDraw() ;
    11.  
    12. /* Set the button color.
    13.   Changing this value changes the color of the button */
    14. $draw->setFillColor( "#4096EE" ) ;
    15.  
    16. /* Create the outer circle */
    17. $draw->circle( 50, 50, 70, 70 ) ;
    18.  
    19. /* Create the smaller circle on the button */
    20. $draw->setFillColor( "white" ) ;
    21.  
    22. /* Semi-opaque fill */
    23. $draw->setFillAlpha( 0.2 ) ;
    24.  
    25. /* Draw the circle */
    26. $draw->circle( 50, 50, 68, 68 ) ;
    27.  
    28. /* Set the font */
    29. $draw->setFont( "./test1.ttf" ) ;
    30.  
    31. /* This is the alpha value used to annotate */
    32. $draw->setFillAlpha( 0.17 ) ;
    33.  
    34. /* Draw a curve on the button with 17% opaque fill */
    35. $draw->bezier( array(
    36.           array( "x" => 10 , "y" => 25 ),
    37.           array( "x" => 39, "y" => 49 ),
    38.           array( "x" => 60, "y" => 55 ),
    39.           array( "x" => 75, "y" => 70 ),
    40.           array( "x" => 100, "y" => 70 ),
    41.           array( "x" => 100, "y" => 10 ),
    42.          ) ) ;
    43.  
    44. /* Render all pending operations on the image */       
    45. $im->drawImage( $draw ) ;
    46.  
    47. /* Set fill to fully opaque */
    48. $draw->setFillAlpha( 1 ) ;
    49.  
    50. /* Set the font size to 30 */
    51. $draw->setFontSize( 30 ) ;
    52.  
    53. /* The text on the */
    54. $draw->setFillColor( "white" ) ;
    55.  
    56. /* Annotate the text */
    57. $im->annotateImage( $draw, 38, 55, 0, "go" ) ;
    58.  
    59. /* Trim extra area out of the image */
    60. $im->trimImage( 0 ) ;
    61.  
    62. /* Output the image */
    63. header( "Content-Type : image/png" ) ;
    64. echo $im ;
    65.  
    66.  ?>

    And here is a few buttons I created by changing the fill color value :

    red

    green

    blue

  • Specifying FFMPEG in the requirements section of 'buildozer.spec' causing [libavformat/network.o] Error 1

    18 juillet 2022, par GJ78

    My question relates to how to mitigate an ffmpeg requirement listed in a buildozer.spec that is causing compile errors using buildozer.

    &#xA;&#xA;

    GOAL :

    &#xA;&#xA;

    Using buildozer to ensure FFMPEG can be embedded within a small Kivy app so i can utilise youtube_dl functionality on my android phone.

    &#xA;&#xA;

    THE ISSUE :&#xA;Specifying FFMPEG in the requirements section of 'buildozer.spec' causes the following error message :
    &#xA;common.mak:60 : recipe for target 'libavformat/network.o' failed
    &#xA;make : [libavformat/network.o] Error 1
    &#xA;make : Waiting for unfinished jobs...

    &#xA;&#xA;

    What have I done to resolve myself :
    &#xA;1. Ensured LOG LEVEL 2 is specified.

    &#xA;&#xA;

      &#xA;
    1. Upgraded cython from Version 21 to 27. Then downgraded to 25, then 21 then 20 to see if this resolved anything. It didn't.

    2. &#xA;

    3. In BUILDOZER.SPEC, switched between Android NDK crystax-ndk-10.3.2 and android-ndk-r16b. (Note have reverted back to Crystax 10.3.2) in my NDK PATH.

    4. &#xA;

    5. In BUILDOZER.SPEC, changed android.api from 19 to 15 (just to see if this has any positive effects).

    6. &#xA;

    7. executed : rm -Rf .buildozer between each compiling attempt.

    8. &#xA;

    9. Part extract of Buildozer.log :

      &#xA;&#xA;

      In file included from libavformat/dump.c:37:0 :
      &#xA;libavformat/avformat.h:893:21 : note : declared here
      &#xA; AVCodecContext codec ;&#xA; ^
      &#xA;CC libavformat/format.o
      &#xA;CC libavformat/golomb_tab.o
      &#xA;CC libavformat/h264dec.o
      &#xA;CC libavformat/hevc.o
      &#xA;CC libavformat/http.o
      &#xA;CC libavformat/httpauth.o
      &#xA;CC libavformat/id3v1.o
      &#xA;CC libavformat/id3v2.o
      &#xA;CC libavformat/img2.o
      &#xA;CC libavformat/isom.o
      &#xA;CC libavformat/log2_tab.o
      &#xA;CC libavformat/m4vdec.o
      &#xA;CC libavformat/metadata.o&#xA;CC libavformat/mov_chan.o
      &#xA;CC libavformat/mov.o
      &#xA;CC libavformat/movenc.o
      &#xA;CC libavformat/movenccenc.o
      &#xA;CC libavformat/movenchint.o
      &#xA;CC libavformat/mpegvideodec.o
      &#xA;CC libavformat/mux.o
      &#xA;CC libavformat/network.o
      &#xA;In file included from libavformat/network.h:29:0,
      &#xA; from libavformat/network.c:22 :
      &#xA;libavformat/os_support.h:67:32 : error : expected declaration specifiers or '...' before '(' token
      &#xA; # define lseek(f,p,w) lseek64((f), (p), (w))
      &#xA; ^&#xA;libavformat/os_support.h:67:37 : error : expected declaration specifiers or '...' before '(' token
      &#xA; # define lseek(f,p,w) lseek64((f), (p), (w))
      &#xA; ^&#xA;libavformat/os_support.h:67:42 : error : expected declaration specifiers or '...' before '(' token
      &#xA; # define lseek(f,p,w) lseek64((f), (p), (w))
      &#xA; ^&#xA;common.mak:60 : recipe for target 'libavformat/network.o' failed
      &#xA;make :
      [libavformat/network.o] Error 1
      &#xA;make : * Waiting for unfinished jobs....

    10. &#xA;

    11. Part extract of Buildozer.spec

      &#xA;&#xA;

      (str) Title of your application

      &#xA;&#xA;

      title = myapplication

      &#xA;&#xA;

      (str) Package name

      &#xA;&#xA;

      package.name = myapp

      &#xA;&#xA;

      (str) Package domain (needed for android/ios packaging)

      &#xA;&#xA;

      package.domain = org.test

      &#xA;&#xA;

      (str) Source code where the main.py live

      &#xA;&#xA;

      source.dir = .

      &#xA;&#xA;

      (list) Source files to include (let empty to include all the files)

      &#xA;&#xA;

      source.include_exts = py,png,jpg,kv,atlas

      &#xA;&#xA;

      (list) List of inclusions using pattern matching

      &#xA;&#xA;

      source.include_patterns = assets/,images/.png

      &#xA;&#xA;

      (list) Source files to exclude (let empty to not exclude anything)

      &#xA;&#xA;

      source.exclude_exts = spec

      &#xA;&#xA;

      (list) List of directory to exclude (let empty to not exclude anything)

      &#xA;&#xA;

      source.exclude_dirs = tests, bin

      &#xA;&#xA;

      (list) List of exclusions using pattern matching

      &#xA;&#xA;

      source.exclude_patterns = license,images//.jpg

      &#xA;&#xA;

      (str) Application versioning (method 1)

      &#xA;&#xA;

      version = 0.1

      &#xA;&#xA;

      (str) Application versioning (method 2)

      &#xA;&#xA;

      version.regex = version = '"['"]

      &#xA;&#xA;

      version.filename = %(source.dir)s/main.py

      &#xA;&#xA;

      (list) Application requirements

      &#xA;&#xA;

      comma seperated e.g. requirements = sqlite3,kivy

      &#xA;&#xA;

      requirements = ffmpeg,python2,hostpython2,kivy,youtube-dl

      &#xA;&#xA;

      (str) Custom source folders for requirements

      &#xA;&#xA;

      Sets custom source for any requirements with recipes

      &#xA;&#xA;

      requirements.source.kivy = ../../kivy

      &#xA;&#xA;

      (list) Garden requirements

      &#xA;&#xA;

      garden_requirements =

      &#xA;&#xA;

      (str) Presplash of the application

      &#xA;&#xA;

      presplash.filename = %(source.dir)s/data/presplash.png

      &#xA;&#xA;

      (str) Icon of the application

      &#xA;&#xA;

      icon.filename = %(source.dir)s/data/icon.png

      &#xA;&#xA;

      (str) Supported orientation (one of landscape, portrait or all)

      &#xA;&#xA;

      orientation = portrait

      &#xA;&#xA;

      (list) List of service to declare

      &#xA;&#xA;

      services = NAME:ENTRYPOINT_TO_PY,NAME2:ENTRYPOINT2_TO_PY

      &#xA;&#xA;

      OSX Specific

      &#xA;&#xA;

      author = © Copyright Info

      &#xA;&#xA;

      change the major version of python used by the app

      &#xA;&#xA;

      osx.python_version = 3

      &#xA;&#xA;

      Kivy version to use

      &#xA;&#xA;

      osx.kivy_version = 1.9.1

      &#xA;&#xA;

      Android specific

      &#xA;&#xA;

      (bool) Indicate if the application should be fullscreen or not

      &#xA;&#xA;

      fullscreen = 0

      &#xA;&#xA;

      (string) Presplash background color (for new android toolchain)

      &#xA;&#xA;

      Supported formats are : #RRGGBB #AARRGGBB or one of the following names :

      &#xA;&#xA;

      red, blue, green, black, white, gray, cyan, magenta, yellow, lightgray,

      &#xA;&#xA;

      darkgray, grey, lightgrey, darkgrey, aqua, fuchsia, lime, maroon, navy,

      &#xA;&#xA;

      olive, purple, silver, teal.

      &#xA;&#xA;

      android.presplash_color = #FFFFFF

      &#xA;&#xA;

      (list) Permissions

      &#xA;&#xA;

      android.permissions = INTERNET

      &#xA;&#xA;

      (int) Android API to use

      &#xA;&#xA;

      android.api = 19

      &#xA;&#xA;

      (int) Minimum API required

      &#xA;&#xA;

      android.minapi = 9

      &#xA;&#xA;

      (int) Android SDK version to use

      &#xA;&#xA;

      android.sdk = 20

      &#xA;&#xA;

      (str) Android NDK version to use

      &#xA;&#xA;

      android.ndk = 10.3.2

      &#xA;&#xA;

      (bool) Use —private data storage (True) or —dir public storage (False)

      &#xA;&#xA;

      android.private_storage = True

      &#xA;&#xA;

      (str) Android NDK directory (if empty, it will be automatically downloaded.)

      &#xA;&#xA;

      android.ndk_path = /home/gjones/Downloads/crystax-ndk-10.3.2

      &#xA;&#xA;

      (str) Android SDK directory (if empty, it will be automatically downloaded.)

      &#xA;&#xA;

      android.sdk_path =

      &#xA;&#xA;

      (str) ANT directory (if empty, it will be automatically downloaded.)

      &#xA;&#xA;

      android.ant_path =

    12. &#xA;

    13. Lastly, when I remove ffmpeg from requirements in buildozer.spec, the .APK compiles successfully and i can deploy it on to my phone with the KIVY GUI. Obviously, ffmpeg functionality is not present.

    14. &#xA;

    &#xA;&#xA;

    Current Environment Specs :

    &#xA;&#xA;

      &#xA;
    1. Running Linux Mint 17.2 as a Virtual Box VM
    2. &#xA;

    3. Buildozer Version : 0.35dev
    4. &#xA;

    5. Cython Version : 0.25
    6. &#xA;

    &#xA;&#xA;

    Any advice would be greatly appreciated.

    &#xA;&#xA;

    Lastly, if there is no obvious solution via buildozer, do i need to compile ffmpeg for Android separately and somehow include this somewhere in the buildozer spec file to prevent this error message ?

    &#xA;&#xA;

    Thanks in advance.

    &#xA;