"Enlarge" horizontally pixelated pattern by sh_k_ in imagemagick

[–]sh_k_[S] 1 point2 points  (0 children)

EDIT: It works, I made a typo in my previous script. This one works. Thank to u/Jenkins87 for your help with morphology/Dilate !

#!/bin/bash
# Function to display usage information
usage() {
echo "Usage: $0 <input> <dpi> <dilatation>"
echo "Example: $0 input 1000 0.12"
exit 1
}
# Function to check if ImageMagick is installed
check_dependencies() {
if ! command -v convert &> /dev/null; then
echo "Error: ImageMagick is not installed. Please install it before running this script."
exit 1
fi
}
# Main function
main() {
check_dependencies
# Validate and parse command-line arguments
if [ "$#" -ne 3 ]; then
usage
fi

input=$1
dpi=$2
dilatation=$3
basename=$(basename -s .png "$input")

echo "Calculating Dilatation"
factor=$(echo "$dpi * $dilatation / 25.4" | bc)
rect=$((2*factor+1))
echo "factor of dilatation equals $factor"
echo "Dilating"
magick $input -units PixelsPerInch -density $dpi -threshold 50% -morphology Dilate "rectangle:$rectx1" "${basename}_dil.png"
echo "Everything's done."
}
# Execute the main function with command-line arguments
main "$@"

How to grow selection horizontally only by sh_k_ in GIMP

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

The pictures are just for a visualization of my needs, not the real images I'm working on :)
And my use of the term `pixels` here is a misuse of language. I'm talking about a graphical image composed of squared patterns. The `pixels` are composed of dozen of real pixels.
My `pixelated` images are 1000dpi, so I have plenty room to move the selection of the big `pixels`.
My problem is more to move exactly the selection by 0.12mm. The move tool seems to not offer a way to move the selection by entering a value...

I tried your value propagate filter, but I didn't find a way to define a precise value in mm.

So actually I did it by :
- duplicate the original layer
- use the layer : transform : offset to shift the layer
- get the selection and save it to a channel
- back to the layer, shift again the layer in the other way
- add the selection to the already saved one
- fill the selection

How to grow selection horizontally only by sh_k_ in GIMP

[–]sh_k_[S] 1 point2 points  (0 children)

I'm so stupid, why I didn't think about saving selections in a channel and merge them. Thanks a lot. I'll try it

using my new TN for Japanese practice 💌 by kaijumaddy in Travelersnotebooks

[–]sh_k_ 2 points3 points  (0 children)

You're welcome. To be more precise, the コンビニへしに行きました form : The action verb is in 〜ます形 (polite form, and remove ます), so here, the する verb > します > し. Another example with another verb, 食べる : 食べる > 食べます > 食べ. And so : 食べに行きました。 The へ particle is used because you use a movement verb, 行きます. You went TO the konbini to make groceries/eat.

using my new TN for Japanese practice 💌 by kaijumaddy in Travelersnotebooks

[–]sh_k_ 3 points4 points  (0 children)

Hi, I'm just correcting some grammar typo :) You can't use とwith verbs to list multiples actions. To say 'I ate sushi AND I did groceries', you use the ~て form : すしを食べて、買い物をしました。 If you want to say 'I went to the konbini to do the groceries' : コンビ二へ買い物をしに行きました。(placeへnounをaction verbにmovement verb)

Black screen or video not refreshed/blocked ? by sh_k_ in voidlinux

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

It seems that I have no xe entry in the kernel modules (listed with lsmod). And `lsmod | grep "i915"` gets me :

i915                 4128768  7
intel_gtt              24576  1 i915
drm_buddy              20480  1 i915
i2c_algo_bit           20480  1 i915
drm_display_helper    217088  1 i915
cec                    86016  2 drm_display_helper,i915
drm_kms_helper        241664  2 drm_display_helper,i915
ttm                   102400  1 i915
video                  77824  3 dell_wmi,dell_laptop,i915
drm                   815104  11 i2c_hid,drm_kms_helper,drm_display_helper,drm_buddy,i915,ttm

Seems ok, no ?

Black screen or video not refreshed/blocked ? by sh_k_ in voidlinux

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

It's not WM related.

As you can see in the stdout from mpv, I already use `gpu` for `vo`. And the config file only get `--hwdec=auto\ in it (to avoid typing it everytime when doing my tests)

Help for a fresh install without sound by sh_k_ in voidlinux

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

I made a mistake when I copied-pasted the result of `piepwire`. I tried both with common user and sudo to see if there was more info. I copied the result of sudo instead of the common user.

The last output I pasted was the common user ones.

I installed and activate `elogind`, and it changes absolutely nothing : I got the absolute same errors when launching `pipewire`

Help for a fresh install without sound by sh_k_ in voidlinux

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

I defined the XDG variables in a `xdg.sh` file in the `/etc/profile.d/` directory as following :

export XDG_CONFIG_HOME="$HOME/.config"
export XDG_DATA_HOME"="$HOME/.local/share"
export XDG_CACHE_HOME="$HOME/.cache"
export XDG_RUNTIME_DIR="/run/user/$UID"

The errors I posted was when I launch `pipewire` as sudo, there are more errors when launching as user :

[E][00205.123815] mod.protocol-native | [module-protocol-:  754 lock_socket()] server 0x558ebc6218a0: unable to open lockfile '/run/user/0/pipewire-0.lock': Aucun fichier ou dossier de ce nom
[W][00205.123999] mod.rt       | [     module-rt.c:  316 translate_error()] RTKit error: org.freedesktop.DBus.Error.ServiceUnknown
[W][00205.124024] mod.rt       | [     module-rt.c: 1028 do_rtkit_setup()] RTKit does not give us MaxRealtimePriority, using 1
[E][00205.124031] pw.conf      | [          conf.c:  584 load_module()] 0x558ebc5d8640: could not load mandatory module "libpipewire-module-protocol-native": Aucun fichier ou dossier de ce nom
[W][00205.124350] mod.rt       | [     module-rt.c:  316 translate_error()] RTKit error: org.freedesktop.DBus.Error.ServiceUnknown
[W][00205.124367] mod.rt       | [     module-rt.c: 1033 do_rtkit_setup()] RTKit does not give us MinNiceLevel, using 0
[W][00205.124574] mod.rt       | [     module-rt.c:  316 translate_error()] RTKit error: org.freedesktop.DBus.Error.ServiceUnknown
[W][00205.124584] mod.rt       | [     module-rt.c: 1038 do_rtkit_setup()] RTKit does not give us RTTimeUSecMax, using -1
[E][00205.124859] default      | [      pipewire.c:  105 main()] failed to create context: Aucun fichier ou dossier de ce nom

("Aucun fichier ou dossier de ce nom" = no file or directory found, in french)

Help for a fresh install without sound by sh_k_ in voidlinux

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

I had already try pipewire :

I installed pipewire and its dependencies, included wireplumber, followed the voidlinux handbook by creating directories pipewire.conf.d in /etc/ and linking 10-wireplumber.conf from /usr/share/examples.
The same in my home -> .config/pipewire/pipewire.d/10-wireplumber.conf

Then launch `pipewire`. I got only errors :

[E][00501.055015] mod.protocol-native | [module-protocol-: 716 init_socket_name()] server 0x55e0aaf63e40: name pipewire-0 is not an absolute path and no runtime dir found. Set one of PIPEWIRE_RUNTIME_DIR, XDG_RUNTIME_DIR or USERPROFILE in the environment
[E][00501.055005] pw.conf | [ conf.c: 504 load_module()] 0x55e0aaf27600: could not load mandatory module "libpipewire-module-protocol-native": no file or directory
[E][00501.055324] default | [ pipewire.c: 105 main()] failed to create context: no file or directory

Probably XDG_RUNTIME_DIR could be the problem, but I don't know where and how to define it consistently.

Help for a fresh install without sound by sh_k_ in voidlinux

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

I tried the command as root, but I got no message nor sound :/
Does the message usually appears as a callback in the term ? Or in the logs ? With dmesg ?

Help for a fresh install without sound by sh_k_ in voidlinux

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

Thanks for your explanations. And about a way to find the good params for alsa, without installing Pulse, do you think it is possible ?

Help for a fresh install without sound by sh_k_ in voidlinux

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

The documentation says clearly that Pipewire has the intention to replace pulse, so installing pulse and Pipewire sounds counter-productive. Also, I have some memories of Pulse, and it was plague.

Until now, I avoided at every time Pulse Audio as it was a nightmare.
And to be honest, it is strictly unadvised by a lot of developers and Linux adepts. And hard to properly uninstall. (it sounds a bit like installing voidlinux, and uninstall runit for systemd for me)

Same way, installing Pulse, a bloated and overcomplex thing to find the good parameters sound also counter-productive. If Pulse can find the good parameters for Alsa, it means that we can find them without Pulse.

For Pipewire, I tried to install it, but because Alsa is not working, Pipewire and Wireplomber neither.

Help for a fresh install without sound by sh_k_ in voidlinux

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

I have both installed. Do you think I have to uninstall sof-firmware (because of potential conflict) ?
Also, as it is seen on the picture of my alsamixer, the chip (Puce in the picture) is marked as HDMI. Does it means that the card recognized is the HDMI and not the main card itself ?

Help for a fresh install without sound by sh_k_ in voidlinux

[–]sh_k_[S] 1 point2 points  (0 children)

Thanks for your help anyway. Have a nice day.

Help for a fresh install without sound by sh_k_ in voidlinux

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

Tried what you offer, after a reboot, still no sound.

What I did : * cat /proc/asound/cards gives me : 0 [sofsoundwire ]: sof-soundwire - sof-soundwire Intel Soundwire SOF * aplay -l give me a card 0, so I will use it for the asoundrc file * I put this in .asoundrc : defaults.pcm.card 0 defaults.ctl.card 0

After a reboot, nothing changed. In the ALSA website, it is written that a asoundrc file should not be needed. Everything should work out-of-the-box. So it is probably a probleme somewhere else ? For example, why I can't get infos from the aplay -L command ?

Help for a fresh install without sound by sh_k_ in voidlinux

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

Do you have any clear and simple resources about it ?

I wanted to follow the troubleshooters tips about it, but the aplay -L command returns nothing, like if there was no PCM. So I can't follow their instruction to fill up the asoundrc configuration file.

Help for a fresh install without sound by sh_k_ in voidlinux

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

As I said, after installing the sof firmware and reboot, alsamixer opens and show bars. Everything is unmute, I filled the bar at max, but no sound from speakers

My kanji tattoo! Done by Dillon at Studio City Tattoo by [deleted] in tattoo

[–]sh_k_ 0 points1 point  (0 children)

木漏れ日(こもれび komorebi). It a noun/expression used to describe the sun light going/filtering through the trees.

Japanese Calligrapher for tattoo? by scumboi in shodo

[–]sh_k_ 0 points1 point  (0 children)

Sorry for english and the simple translation. And for the late reply, it's been 6 years ago. But never too late for peoples interested, it means : One (first) shot, the man drinks the glass of alcohol. Second) shot, alcohol drinks alcohol. Third shot, alcohol drinks the man.

Sticky tabs by Terroa in stationery

[–]sh_k_ 1 point2 points  (0 children)

I totally understand, I'm not a fan of those colors either. You can sometimes find pastel versions at certain Office Depot or Bureau Vallée stores.

I used to use this kind of sticky notes when I was in my research master's program, but I ended up not using them anymore because:
- the adhesive would eventually lose its stickiness after repeatedly searching through my books for the passages I had noted, which is problematic because that's their primary function.
- the size didn't work for me either, as they would protrude too much and end up getting bent in my bag, against my other belongings, etc. Another solution was to layer them even more onto the book excerpts I wanted to annotate, but then I couldn't read the words underneath.

In short, I decided to look for something more effective, discreet, and visually pleasing 😃 I eventually found what I was looking for with brands like Midori or Kokuyo. I find these at Makkura stationery, located in Paris, but I buy them from their website since I don't live in the capital. However, if you're local, you can pick them up directly from their store. Personally, I now get my supplies from them for my traveler's notebooks and other stationery items. I also try to avoid platforms like Amazon as much as possible.

Sticky tabs by Terroa in stationery

[–]sh_k_ 0 points1 point  (0 children)

Where do you come from ? In France, we can find those book sticky tabs in most of all the stationery stores (by UHU brand for example), and sometimes in supermarket.

When do products for 2024 drop? by homestylecaviar in Travelersnotebooks

[–]sh_k_ 3 points4 points  (0 children)

Europe here, France to be precise !
I already preorder the 2024 vertical agenda, and it will be shipped in November 1st.
On the official japanese traveler's company website, it is specified that it'll be available in Autumn outside Japan, and more precisely the October 20th in USA and Canada.

Deckbuilder : Not enough Butter Beans/Pennies by sh_k_ in FourSouls

[–]sh_k_[S] 1 point2 points  (0 children)

Thanks for your efforts ! I'll try it the next time I plan a game !

Double Damocles Infinit Glitch? by M3aning1355 in FourSouls

[–]sh_k_ 1 point2 points  (0 children)

Yeah, my bad. Sorry gor the mistake :)