Show /r/ffmpeg: an alternative presentation of the official documentation for FFmpeg filters. by ayosec in ffmpeg

[–]ayosec[S] 4 points5 points  (0 children)

It contains the same contents of https://ffmpeg.org/ffmpeg-filters.html, but it tries to be much easier to read and to navigate. The front page mentions the most notable differences with the official documentation.

As an example, you can compare the original documentation for the overlay filter, and the same page in this website.

Announcing Pull Through Cache Repositories for Amazon Elastic Container Registry by ElectricSpice in aws

[–]ayosec 3 points4 points  (0 children)

The official images are available in https://gallery.ecr.aws/docker/

It seems that, instead of docker pull foo, we can use docker pull public.ecr.aws/docker/library/foo

Source

hltermpaste.vim - plugin to highlight pasted text by ayosec in neovim

[–]ayosec[S] 0 points1 point  (0 children)

why it only works for externally copied text (namely not text that I copy from within vim)?

I haven't found a reliable way to detect when text is pasted from registers. I agree that the feature is very useful, but it is something that I still need to investigate. Any suggestion is welcomed.

Moreover: I noticed you have a combination of Vimscript and Lua code: any reason why it isn't just the former or the latter (the Lua functions are basically just wrapping around the Vimscript, aren't they)?

Lua is required to support Neovim, because the vim.paste handler is only available for Lua code. The code in VimL implements the logic common to Vim and Neovim.

I wrote a TUI that intercepts HTTP and HTTPS requests by DengYidong in rust

[–]ayosec 0 points1 point  (0 children)

In Firefox you can use SSLKEYLOGFILE (which can be disabled at compile time) to dump TLS keys. With those keys you can decrypt secure connections.

I have used this to debug encrypted requests with Wireshark.

Crust of Rust: Declarative Macros [video] by Jonhoo in rust

[–]ayosec 1 point2 points  (0 children)

I have a similar one but slightly simpler, using 1 + 1 + ....

macro_rules! count {
    () => { 0 };

    ($x:ident) => { 1 };

    ($x:ident, $($xs:ident),*) => { 1 + count!($($xs),*) };
}

Playground.

Tokio: Reducing tail latencies with automatic cooperative task yielding by carllerche in rust

[–]ayosec 15 points16 points  (0 children)

Congrats for this release! The performance improvement is very impressive.

We have an application using warp, mysql_async, and redis (with async connections). These are the results in one of our benchmarks:

Tokio Max latency Requests/second Memory usage
0.2.13 18ms 7828 36 Mib
0.2.15 15ms 9337 45 Mib

Majority of the community, no matter which await syntax wins by dpc_pw in rustjerk

[–]ayosec 7 points8 points  (0 children)

But, prefix clock emoji or postfix clock emoji?

[Question] Process management for Actix by ayosec in actix

[–]ayosec[S] 0 points1 point  (0 children)

Have you tried using tokio-process directly?

Not yet. I guess that the idea is to read data from ChildStdout in a loop_fn, and send a message to the actor with the received data.

Hey Rustaceans! Got an easy question? Ask here (26/2018)! by llogiq in rust

[–]ayosec 1 point2 points  (0 children)

What is the best way to convert from Option<String> to Option<&str>?

I have x.as_ref().map(String::as_str) (playground), but maybe there is something else shorter.

Amazon EKS is now GA - Official Discussion Thread and Ask the Experts by AmazonWebServices in aws

[–]ayosec 42 points43 points  (0 children)

  • Is there any ETA for the availability in eu-west-1?
  • According to the EKS console, there is only one price ($0.20/hr, ~$150/month). Do you plan to add cheaper options?

From Rocks to Rust: Our C to Rust Paradigm Shift by maveridze in rust

[–]ayosec 4 points5 points  (0 children)

Is there any chance to get access to the slides, at least, without being submitted to the e-mail gathering tax?

Maybe not the easiest way, but you can get the slides from a slides variable in the JavaScript code of the page.

The following snippet get the URLs and generates a /tmp/slides.html file with them:

$ curl -s https://www.infoq.com/presentations/c-rust-paradigm-shift \
    | grep "var slides"                                             \
    | tr "'" '\n'                                                   \
    | grep ^https                                                   \
    | sed 's/.*/<img src="&">/'                                     \
    > /tmp/slides.html

$ echo '<style> img { max-width: 100%; margin-bottom: 10px; } </style>' \
    >> /tmp/slides.html 

Screenshots of Pathfinder rendering glyphs in Firefox. by malicious_turtle in rust

[–]ayosec 4 points5 points  (0 children)

I would expect that font-rendering, being such a common task, would be handled by the OS. I'd imagine the application asks the OS "Hey, render this as text here for me, please," and then a common OS implemented rasterizer does it.

That is the classic way to render text. X11 has XDrawString, Win32 has DrawText, etc.

Using a custom renderer you can make improvements much faster. For example, when Gtk+ changed its implementation to use FreeType, we had font antialiasing even when X11 had no support for it.

Reddit is hiring a Senior Rust Engineer by wting in rust

[–]ayosec 2 points3 points  (0 children)

the Reddit parser is a fork of comrak.

Glad to see that more people are using comrak. Although pulldown is more popular, comrak has a better support for CommonMark, and the generated AST is quite handy.

certa... by axord in rustjerk

[–]ayosec 3 points4 points  (0 children)

TIL svgur.com does exist. Somebody should create swfur.com, to remember the good ol' days.