Skip to content

c1-g/org-noter-media

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 

Repository files navigation

org-noter-media

Caveat & Installation

Incompatibility with upstream org-noter

The way org-noter originally works is that it will call find-file on the value of NOTER_DOCUMENT, resulting in a new buffer then, get the major-mode of this new buffer to call the appropriate functions for the mode.

For example, if your NOTER_DOCUMENT is a path to a pdf file, org-noter will call find-file resulting in a new buffer with in the major-mode called pdf-view-mode. Org-noter then passes the pdf-view-mode to various function to handle the mode as expected.

This breaks down, however, when our NOTER_DOCUMENT is a binary file (mp3, mp4, etc.) that Emacs has no mode to handle or a URL.

If only we can customize the way org-noter find its NOTER_DOCUMENT and try to remove major-mode from the equation.

The implementation

This modified version of org-noter can handle URL as its source document.

See https://github.com/c1-g/org-noter-plus-djvu.

To install it, with straight.el and use-package,

put these in your config file.

(use-package org-noter
  :straight '(org-noter :type git
                        :host github
                        :repo "weirdNox/org-noter"
                        :fork "c1-g/org-noter-plus-djvu"
                        :files ("other/*.el" "*.el" "modules/*.el"))
  :config
  (use-package org-noter-nov :ensure nil)
  (use-package org-noter-djvu :ensure nil)
  (use-package org-noter-pdf :ensure nil))

and then to install this package,

(use-package org-noter-media
  :straight '(org-noter-media :type git
                              :host github
                              :repo "auroranil/org-noter-media"
                              :fork "c1-g/org-noter-media"))

Integration with mpv player

Operations

Inserting [1/1]

  • [X] org-noter-insert-note

Synchronizing [1/1]

  • [X] org-noter-sync-current-note

Media player specific [0/1]

  • [-] org-noter-media-toggle-play

Plan

  1. [X] Creating new org-noter session with media file in NOTER_DOCUMENT property should open mpv playing that media file from beginning
  2. [X] Specifying NOTER_PAGE property in root org heading should open mpv playing that media file at that specified time
  3. [X] Communicate to org-noter-media its timestamp as video is playing, so that it knows when to sync automatically
  4. [X] Specifying NOTER_PAGE property in non-root org heading should show that heading and hide others (when org-noter-hide-others is set to true) when playing video reaches that section
  5. [X] Implement org-noter-sync-current-note
  6. [X] Implement org-noter-insert-note
  7. [-] Implement org-noter-media-toggle-play

    This feature is already available in mpv.el. Try M-x mpv-pause

  8. [-] Find out a way to customise org-noter properties so that its terminology aligns with media files

    For me, the default NOTER_DOCUMENT is already satisfactory. I tend to think of “document” in a more abstract sense, that is, an object that gives information; so it is not only a paper but it can be a video, audio, speech, etc.

    But for a more neutral term, maybe NOTER_SOURCE?

About

org-noter for video/audio files via mpv

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Emacs Lisp 100.0%