Giter Club home page Giter Club logo

ii-vision's People

Contributors

kriskennaway avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

michaelquigley

ii-vision's Issues

Stop hosting transcoder/data in LFS

Any chance of sticking the example videos on Google Drive, or some similar service?

I've got a bunch of this stack ready to go, but I'm struggling with trying to transcode a video. Would love to test with a known-good video.

Feature request: Support positional/ordered dithering

BMP2DHR only supports error-diffusion dithering which is not appropriate for video. Positional/ordered dithering is much more appropriate for video; it is stable across the spatial domain, which translates into being stable across the time domain. Without any changes in the player, this will allow for larger display updates with less dither noise.

Some good free algorithms for doing this are at https://bisqwit.iki.fi/story/howto/dither/jy/

Consider using A2BestPix instead of BMP2DHR

Congratulations, this is super cool in every way!

Have you considered using the amazing A2BestPix DHGR encoder described here?...

He's researched a way to get exceptional conversions by taking advantage of the fuzzy bleeding artifacts between each pixel on an analog Apple II display. His sample images are stunning and I'd really love to see those come to life in your transcoder.

Where to find a demo video

Hi

I am trying to stream an mp4 to an Apple ii, but really struggle to make transcode/main.py to work.

Errors look like

Palette NTSC
Input frame rate = 30.000000
Starting frame 1
Similarity 0.000000
Traceback (most recent call last):
  File "/home/andrea/projects/cvs/3rdParty/ii-vision/transcoder/main.py", line 73, in <module>
    main(parser.parse_args())
  File "/home/andrea/projects/cvs/3rdParty/ii-vision/transcoder/main.py", line 68, in main
    for bytes_out, b in enumerate(m.emit_stream(m.encode())):
  File "/home/andrea/projects/cvs/3rdParty/ii-vision/transcoder/movie.py", line 110, in emit_stream
    for op in ops:
  File "/home/andrea/projects/cvs/3rdParty/ii-vision/transcoder/movie.py", line 87, in encode
    (page, content, offsets) = next(
  File "/home/andrea/projects/cvs/3rdParty/ii-vision/transcoder/video.py", line 88, in encode_frame
    yield from self._index_changes(
  File "/home/andrea/projects/cvs/3rdParty/ii-vision/transcoder/video.py", line 119, in _index_changes
    diff_weights = target_pixelmap.diff_weights(self.pixelmap, is_aux)
  File "/home/andrea/projects/cvs/3rdParty/ii-vision/transcoder/screen.py", line 403, in diff_weights
    return self._diff_weights(source.packed, is_aux)
  File "/home/andrea/projects/cvs/3rdParty/ii-vision/transcoder/screen.py", line 438, in _diff_weights
    dist = self.edit_distances(self.palette)[o][pair].reshape(
  File "/home/andrea/projects/cvs/3rdParty/ii-vision/transcoder/screen.py", line 348, in edit_distances
    dist = pickle.load(ed)  # type: List[np.ndarray]
  File "/usr/lib/python3.8/bz2.py", line 172, in peek
    return self._buffer.peek(n)
  File "/usr/lib/python3.8/_compression.py", line 68, in readinto
    data = self.read(len(byte_view))
  File "/usr/lib/python3.8/_compression.py", line 103, in read
    data = self._decompressor.decompress(rawblock, size)
OSError: Invalid data stream

Do you have an example file I could try?

Bmp2DHR Error in Transcoding

I'm running into the following error when trying to transcode a video. It appears to be hitting bmp2dhr, which is emitting the following:

% python3 transcoder/main.py voir.mp4              
/Users/michael/Repos/ii-vision/transcoder/audio.py:58: FutureWarning: Pass orig_sr=48000, target_sr=14700.0 as keyword args. From version 0.10 passing these as positional arguments will result in an error
  a = librosa.resample(a, f.samplerate,
Palette NTSC
Input frame rate = 23.976024
Palette 5: tohgr NTSC DHGR Colors
Preview Palette 5: tohgr NTSC DHGR Colors
voir/DHGR/NTSC/00000000.bmp is in the wrong format!
Exception in thread Thread-1:
Traceback (most recent call last):
  File "/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.9/lib/python3.9/threading.py", line 973, in _bootstrap_inner
    self.run()
  File "/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.9/lib/python3.9/threading.py", line 910, in run
    self._target(*self._args, **self._kwargs)
  File "/Users/michael/Repos/ii-vision/transcoder/frame_grabber.py", line 125, in worker
    q.put(decode(_idx, _frame))
  File "/Users/michael/Repos/ii-vision/transcoder/frame_grabber.py", line 112, in _dhgr_decode
    _main = np.fromfile(mainfile, dtype=np.uint8)
FileNotFoundError: [Errno 2] No such file or directory: 'voir/DHGR/NTSC/00000000.BIN'

The error appears to be bmp2dhr spitting out voir/DHGR/NTSC/00000000.bmp is in the wrong format!

I tried to contact the author of Bmp2DHR but the email just bounces.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.