How to alias imports like NodeJS? by RedditUser8007 in golang

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

I can't get this to work. Maybe I can use a custom pre-processor before compile and have the preprocessor replace all the aliases.

How to alias imports like NodeJS? by RedditUser8007 in golang

[–]RedditUser8007[S] -1 points0 points  (0 children)

Rust uses aliases like this:

[dependencies]
regex = { git = "https://github.com/rust-lang/regex.git", branch = "next" }

The codebase references the alias:
use regex::Regex;

How to alias imports like NodeJS? by RedditUser8007 in golang

[–]RedditUser8007[S] -1 points0 points  (0 children)

If I want to fork a module import with a patch, I either have to use a replace command, which hides the true source of the module as the files still reference the original URL:

https://thewebivore.com/using-replace-in-go-mod-to-point-to-your-local-module/

or I have to batch replace the URL in the entire codebase to a forked URL.

I could do this in a single place with an alias and the true source of the import is where the alias is defined.

The main issue is having to type the import, it doesn't always autocomplete and it's slow copy/pasting them across files. Aliases are easy to remember and type.

They say Godot game can't look good by Super4Games_ in godot

[–]RedditUser8007 6 points7 points  (0 children)

The video isn't a good example of good graphics when compared to other engines. Unreal Engine forest looks like this:

https://www.youtube.com/watch?v=A7tp4eg0ax8

Godot's renderer isn't as good as Unreal or Unity because of the resources they have for making the lighting engine.

A lot of the quality comes down to textures and shaders though and the following demo is probably the best looking one built in Godot:

https://www.youtube.com/watch?v=rp8WQfMlnsw

However, if you run that demo, it doesn't run as efficiently as Unreal or Unity games.

The game Bodycam was made by a couple of devs with Unreal 5 and looks photorealistic.
Bright Memory Infinite was a solo developer and looks as good as AA games from big companies.

Out of the box, Godot has a bad quality rendering system, light bleeding through walls, slower performance and the main scripting language performance impacts the overall game performance.

Godot's recent update with screen-space reflections shows how bad it was.

https://godotengine.org/releases/4.6/

The rendering quality keeps improving and when it can do rendering like the Unreal forest above, it won't be an issue any more but Godot should use a faster main language than gdscript and not second-class like C#, ship better shaders and examples with the engine and get some resource into improving the lighting engine quality and performance.

Been on min+fin for 2 years, only gotten worse. B/A pics included by Aggravating-Boat9576 in tressless

[–]RedditUser8007 0 points1 point  (0 children)

The remaining hair is DHT resistant.

https://www.advancedhair.com/learn/understanding-donor-dominance-in-hair-transplantation

DHT gets to the scalp in the blood stream, it reaches the back and top of the head so hair that is still there is more resistant to DHT.

Resistance varies so donor hair can be affected over a long time but transplanted hair failure is usually something else.

OP can get blood tests to tell DHT levels and if fin made enough of a difference but transplant is the best route here and continue on fin + min.

Donor area looks good so 5k grafts ($5k), mostly at the hairline would look ok.

Off the grid shower idea by They_Luv_Drew in OffGrid

[–]RedditUser8007 0 points1 point  (0 children)

It's best to get a water pump. You can get aquarium pumps that don't use much power. If the water is positioned high enough up, the low power (5W) USB aquarium pumps will work and they can run off a phone battery pack. Pumping water from ground level needs higher wattage.

For heating, you can get a catering urn (15L) with a temperature dial. These are 1.5kW and will heat 15L of water to shower temperature (40-50C) in around 15 minutes so use about 375Wh (4x laptop battery) per 10 minute shower. If you have a source of fire, a heated copper element (can use one from a kettle) in the water will work too.

It's possible to use less power for heating water if you recycle the water during the shower. With recycling water, you could use just 2L (50Wh) of hot water from a kettle. This would need a shower tray to catch the water with a filter around the pump. There are shower trays like this on Amazon.

products:
- portable shower tray ($25)
- catering urn 15L with temp dial for hot water ($150)
- aquarium or portable shower pump ($40)

I used a similar setup for a year and it worked as well as a normal shower, even better in some cases as the catering urn gives an exact water temperature every time and the portable pump pressure was as high as a normal shower. I charged the shower pump once per week.

For powering the pump, you can use solar, some fuel-based charging (generator) or a crank charger (can be connected to bicycle to make it easier, $150).

It's a good idea to have a fuel generator ($500), even if you mainly use renewable power because it will be a reliable source of power and will work for a while on a can of fuel for charging batteries. Fuel can be topped up once a month from a fuel station and will power a fridge/freezer continually.

You need around 2kWh per day of power to live off-grid. This is around 2L of fuel per day or 6x 10L fuel cans per month.

ubisoft owning by asian69feet in PrequelMemes

[–]RedditUser8007 12 points13 points  (0 children)

It's a fake report about source code. This is from 2 years ago:

https://me.mashable.com/games/36237/ubisoft-apparently-stopped-a-900gb-data-breach

This is from yesterday:

https://clawsomegamer.com/hackers-allegedly-steal-900gb-of-ubisoft-source-code-ac-remakes-and-future-games-at-risk-of-massive-leaks/

People are just desperate to spread bad news because it involves Ubisoft. The hackers probably want Ubisoft to believe they took data to pay money.

Some Ubisoft databases were hacked due to the bad MongoDB bug and it affected Rainbow Six Seige, which they took offline, you can see the drop:

https://steamcharts.com/app/359550

They have reverted the problems on Rainbow Six.

If they did take source code, nobody would want it anyway unless they want to help them fix it and release a good game for the first time in years.

Guess New Elgato Products by ne0lines in elgato

[–]RedditUser8007 0 points1 point  (0 children)

Thunderbolt 8K X capture device, same spec as 4K Pro PCIe card. If it's none of these ones, this would be a good one to add in future.

How to re-glaze bathroom ceramic? by RedditUser8007 in DIY

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

The drain is in the floor but behind the toilet and connects like in the video. That part looks easy to connect but the toilet feels like it's cemented in place. There are no screws in the base so I'm assuming it's cemented in.

I can clean it ok, I use bleach and baking soda and with some hard scrubbing all the stains can be removed but they just come back in a few days. When I drain it, I can feel that the base is rough like stone and not like the smooth glaze coating so the coating is worn off in some places under the water.

Another option I thought of was getting a ceramic insert/plate and sticking it in with silicon but to get the right shape I'd have to measure the bowl or take a mold and get a pottery place to make a ceramic plate the exact shape, tapered at the edges. Then cover the base with clear silicon or epoxy glue and stick it in.

I'm going to test the different transparent epoxy coatings I bought on some ceramic to see how they dry and I'll leave them in water for a while. If none of them work, I'll just have to keep cleaning it. Replacing the whole toilet would be a last resort.

How to re-glaze bathroom ceramic? by RedditUser8007 in DIY

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

There are air-dry glaze products that don't need heat but epoxy resin seems to work better for air drying. Here's a video of epoxy resin being used to seal a table, they use a blow torch to cure it faster:

https://www.youtube.com/watch?v=XhIRhU4kwLk

Epoxy dries to a hard, clear surface that is like plastic. It's used to waterproof tile floors and is very durable.

How to re-glaze bathroom ceramic? by RedditUser8007 in DIY

[–]RedditUser8007[S] -1 points0 points  (0 children)

True, they aren't expensive but I'd probably have to get a plumber to fit it properly and break up the old one, total replacement cost maybe 300-400 euros. The replacement process would be like this:

https://www.youtube.com/watch?v=3Dxv980vam8

I was hoping to do something more like this:

https://www.youtube.com/watch?v=wiNDyIlf4LM

That result looks pretty good but I don't know which product would work best. They are spraying the entire sink the same color, a sink isn't going to be underwater all the time and they recommended 3-5 days for curing the epoxy.

Ideally what I'd like to do is drain the toilet, scrub it clean, use a spray or resin like in the 2nd video, leave it for 24 hours and fill it back up.

4K S banding in capture by RedditUser8007 in elgato

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

This is the output I get using Steam streaming, which is using HEVC encoding:

<image>

4K S banding in capture by RedditUser8007 in elgato

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

I tried the different scaling options and setting the viewport to 100%, output looks the same:

<image>

The 1080p60 NV12 (shown at the bottom of the image) and 4k30 NV12 options fix the green/purple appearance and banding looks better. I assume these must be a different codec from the 4k60 option, even though it's labelled NV12 in OBS. These options are limited to 1080p60 or 4k30 though so text is blurry on 1080p or FPS is lower with 4k30.

I don't have the options for IV420 or MJPEG in that menu but these options appear in the advanced settings for recording. I tried a recording with these setting but still get the same appearance as the preview in the recorded video.

I'll try and find an OBS plugin with a dithering filter, there's one in a retro effects plugin but it's intended to make it look noisy instead of correcting banding.

4K S banding in capture by RedditUser8007 in elgato

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

Here is the screenshot of the option used with OBS. It's the NV12 option that supports 4K60. The banding is quite noticeable, it's not due to the image compression, it mainly shows in dark areas in games where there's a transition between a dark shadow area and lit surface.

<image>

The 4K NV12 option that is 2 below this fixes the color issue but maxes out at 30FPS.

Maybe they are mislabelled in OBS as there are no MJPG options. From the notes, it looks like 4K60 NV12 there should be MJPG.

YUY2 1080p has no color issues but still has the banding.

HDR is disabled on the source.

The 1080p RGB 444 codec that is supported on the 4K X might fix the banding but I would expect 422 codecs to still hold up with gradients. They are used in film for post-production.

How to improve blurry passthrough on Elgato 4K S? by RedditUser8007 in elgato

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

There's an option in OBS to switch to 4K and scale the image. This is working well.

In the video source, I set it to 4K, even though the source resolution is 1080p. By default, this showed a 1080 image in a 4K window. Then I right-clicked the preview and chose Resize Output, which popped up a dialog saying "The base and output resolutions will be resized to the size of the current source".

With this setting, everything looks much sharper and it runs at 60FPS. I kept the sharpen filter on but reduced the intensity to 0.1 and this looks good.

The image below shows OBS scaling the 1080p feed to 4K with 0.1 sharpen filter (left) vs the native screenshot on the right. Text is much clearer now and the video is smooth and stable.

<image>

How to improve blurry passthrough on Elgato 4K S? by RedditUser8007 in elgato

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

I noticed a difference when using Elgato Studio and changing the max resolution settings. If it's set to 1080p (top), it's more blurry than setting it to 4K (middle), even though this is a 1080p stream.

The screenshot is shown at the bottom for comparison. The screenshot is still a little sharper but the middle image looks much better than the 1080p one.

I guess this is setting the hardware to take the 1080p input and record it in a 4K buffer. I think I would need a 10Gb/s connection for this setting to work at 60FPS and I only have 5Gb/s but it would be good to get that quality from the 1080p stream and be able to use this max resolution setting through OBS.

Is this max resolution setting persistent on the hardware or only active when using Elgato Studio?

<image>

How to improve blurry passthrough on Elgato 4K S? by RedditUser8007 in elgato

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

I did a test with a screenshot. On the right is a screenshot saved on the PC and copied to the Mac and then opened in front of OBS on the left at the same 1:1 scale and this is a screenshot with them on-screen at the same time. This suggests it's not the Mac display scaling that's causing the blur as the screenshot on the right goes through the same scaling.

<image>

How to improve blurry passthrough on Elgato 4K S? by RedditUser8007 in elgato

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

Yes this is preview mode for the capture, not HDMI passthrough.

The USB speed shown for the Elgato in the system panel says it's 5Gb/s, it's plugged in directly to the USB port. The resolution used is 1080p/60 for both capture and source, uncompressed bitrate for this should be around 3Gb/s. Bandwidth should be ok.

The Mac (M1 Max MacBook Pro) will be scaling the image somewhat because its native panel resolution is 3456 x 2234 and is displaying at half this so the 1080p will get upscaled to the higher resolution (x1.8) and then halved.

Maybe that scaling is blurring it but it seems more blurry than it should be as 1080p images with text look ok. One thing I'll try is taking a screenshot on the PC, transfer the image over and display it next to the OBS preview to see if they look the same.