TGViewer
Channel Public Channel
Everyday Unity

Everyday Unity

@everydayunity

A game developer and tech lead in a top grossing company posting Unity, programming, and gamedev related stuff that I find interesting
Website: https://gamedev.center

Most used tags are:
#performance
#shader
#interview

Author: @alexmtr
Subscribers
1.18K
Photos
169
Videos
61
Links
2.4K

Showing posts older than #2360 · Back to latest

Older Posts 20 shown
Post #2359 688
A simple project that shows how to create an Android service for Unity application working on background

The Unity Background Service is a project demonstrating how to create an Android service for a Unity application to operate in the background. Typically, Android services, especially within Unity apps, shut down when we terminate the app. It is impossible to keep the service fully operational in the background. The only solution is to allow the service to run in the foreground, accompanied by a notification. Users can then choose to hide that notification if they wish.

https://github.com/nintendaii/unity-background-service

#native #background
GitHub GitHub - nintendaii/unity-background-service: A simple project that shows how to create an Android service for Unity application… A simple project that shows how to create an Android service for Unity application working on background - nintendaii/unity-background-service
  • 🔥 7
  • 👍 2
Post #2358 695
12 Debugging Techniques In JetBrains Rider You Should Know About

A great post with debugging tips. At some point in the past, I had been using Rider for multiple years when a colleague showed me the Drag Execution Pointer functionality. I was blown away by how useful it is and realized I had no clue it existed. So take the time to read the post to ensure you know how to use the debugger to its full extent when needed.
Like the tip from the Pragmatic Programmer: Achieve Editor Fluency. Keep learning your tools to make your work easier and more efficient.

https://blog.jetbrains.com/dotnet/2024/01/29/12-debugging-techniques-in-jetbrains-rider-you-should-know-about/

#debug #rider
  • 👍 5
  • 🔥 2
Post #2357 704
cognitive-load: 🧠 Cognitive Load In Software Development

This post provides a good list of principles on how to make code more readable. During code review, I always advocate for reducing cognitive load on developers at all levels, even in the smallest things like if conditions or variable names. The post covers various principles from low-level to high-level concepts, so I would definitely recommend checking it out.

https://github.com/zakirullin/cognitive-load

#architecture
GitHub GitHub - zakirullin/cognitive-load: 🧠 Cognitive load is what matters 🧠 Cognitive load is what matters. Contribute to zakirullin/cognitive-load development by creating an account on GitHub.
  • 🔥 6
  • 👍 1
Post #2356 821
Unity Debug Sheet

To be fair it looks pretty well for a debug window. I believe it can be even reused for prototypes to create UI really fast and have a decent appearance.

https://github.com/Haruma-K/UnityDebugSheet

#debug #tools
  • 👍 6
  • 🔥 3
Post #2354 590
  • 👍 3
  • 🔥 2
Post #2353 686
Build-History: Keep a history of all the builds you do.

It comes in handy to track when the build size grows, especially when aiming to stay under the 200 MB limit on Android, particularly in large teams where you may not check each PR or change made. So it would help localizing the problem.

https://github.com/FronkonGames/Build-History

#editortools #build
GitHub GitHub - FronkonGames/Build-History: Keep a history of all the builds you do. Keep a history of all the builds you do. Contribute to FronkonGames/Build-History development by creating an account on GitHub.
  • 👍 7
  • 🔥 3
Post #2352 694
Introducing Arm Frame Advisor

The previous post was about a low-overhead profiler, which allows detecting where issues are. After that it's time for a deep-dive profiler like Frame Advisor to investigate in detail what the root cause of the issue is.

https://community.arm.com/arm-community-blogs/b/graphics-gaming-and-vr-blog/posts/arm-mobile-studio-2023-5

#profiling
Arm Introducing Arm Frame Advisor Learn about Frame Advisor, a new frame-based performance analysis tool to help you optimize rendering workloads for Arm Immortalis and Mali GPUs.
  • 👍 3
  • 🔥 1
Post #2351 826
CPU profiling for Unity

The Unity profiler is a powerful tool. It is useful when developing games, but requires the use of a development build. This type of build can introduce too much overhead in the app to obtain accurate performance data on the final game. For this reason, the Unity Profiler may not be suitable for precise CPU performance profiling of release builds. So this post explores other ways to profile release builds with minimal overhead

https://gpuopen.com/learn/unity-cpu-profiling-guide/

#profiling
Gpuopen CPU profiling for Unity - AMD GPUOpen This is a general guide focusing on CPU profiling for Unity, including which tools are useful for profiling and how to use these tools to find hotspots in your code.
  • 👍 8
  • 🔥 3
Post #2348 800
Arch: A high-performance C# based Archetype & Chunks Entity Component System (ECS) with optional multithreading

It's a type of repo that can be definitely recommended to read the source code and pick up some good practices. The ecs implementation is similar to Unity. Entities, but the codebase is easier to navigate and read in my opinion. It also contains source generation and can be used as a sample for your own implementation.

https://github.com/genaray/Arch

Source generation: https://github.com/genaray/Arch/tree/master/src/Arch.SourceGen

#ecs #sourcegen
  • 👍 6
  • 🔥 1
Post #2346 773
BurstLinq: Extremely fast LINQ aggregation operations implementation optimized by Burst Compiler

I've run performance tests provided by the author and not in all cases BurstLinq was faster than regular for loop, but still in all cases a lot faster than Linq and in most cases faster than for. It was pretty interesting to check the source to see how these results were achieved.

https://github.com/AnnulusGames/BurstLinq

#burst #linq
GitHub GitHub - annulusgames/BurstLinq: Extremely fast LINQ aggregation operations implementation optimized by Burst Compiler Extremely fast LINQ aggregation operations implementation optimized by Burst Compiler - annulusgames/BurstLinq
  • 🔥 11
  • 👍 4
Post #2345 703
How To Use Loops Inside Unity's Update Methods

An example of how not to use loops inside Update, along with a simple example of offloading calculations to a background thread using Awaitable, which is supported from 2023.1. However, it is not recommended for shorter-lived operations, such as parallelizing computationally-intensive algorithms. To maximize the use of multi-core CPUs and parallelize your algorithms, the C# Job System is recommended.

https://giannisakritidis.com/blog/Looping-Inside-Update/

Read more about Awaitable: https://docs.unity3d.com/2023.2/Documentation/Manual/AwaitSupport.html

#awaitable #async
C# and Unity development How To Use Loops Inside Unity's Update Methods Different ways to use C# loops inside Unity's game loop update methods. Why Unity can freeze with certain loops and how some loops can make a single frame really slow.
  • 👍 3
  • 🔥 1
Post #2344 655
Everyday Unity Render Hell – Book I | Simon schreibt. https://simonschreibt.de/gat/renderhell-book1/ #render #hell #pipeline
Use the GPU, Luke!

A highly detailed post about compute shaders, where the author delves into the intricacies of how GPUs work and provides a higher-level overview of the pipeline compared to Render Hell. I definitely recommend reading it, as well as Render Hell, if you are interested in more details on how GPUs operate.

https://arnaud-carre.github.io/2023-12-10-gpgpu/

#computeshader #rendering #gpgpu
Leonard's Blog Use the GPU, Luke! You don't have to be a graphics programmer to need a GPU, by Arnaud Carré
  • 👍 5
  • 🔥 2
Post #2343 664
String Interning - To Use or Not to Use? A Performance Question

- String interning in non-native AOT is very slow and can drastically affect your application performance.
- If you call string.Intern in your code you probably should think if you really should.
- A very naive custom string cache based on ConcurrentDictionary<string, string> is drastically faster then the string interning cache and gives you an opportunity to clean-up the cache.
- If your app runs as a Native AOT app, then the performance is good, and the only drawback of the bulit-in string interning is an inability to clean it.

https://sergeyteplyakov.github.io/Blog/benchmarking/2023/12/10/Intern_or_Not_Intern.html

#interning
Dissecting the Code String Interning - To Use or Not to Use? A Performance Question I recently join a new team and one of the projects was having a high memory footprint issues. There are a few mitigations put in place and one of them was to de-duplicate strings by using string interning.
  • 👍 6
  • 🔥 1
Post #2342 686
Intro to Shader Graph in Unity 2022 (Your first graph, Textures & UVs, Transparency and Alpha)

For a long time, I was quite skeptical of Shader Graph due to the suboptimal performance of generated shaders. Consequently, I focused on learning HLSL. However, given the abundance of learning resources on Shader Graph, I decided to use it in my prototypes. It allows for the quick and easy addition of test shaders for my VFX. Now, I can confidently recommend trying it to save time during prototyping, especially if you are not highly proficient in HLSL. And as always, don't believe anyone about performance, profile yourself your particular game. Probably shader graph would be ok for you even in production.

https://danielilett.com/2023-09-26-tut7-3-intro-to-shader-graph/

https://danielilett.com/2023-12-04-tut7-4-intro-to-shader-graph-part-2/

https://danielilett.com/2023-12-11-tut7-5-intro-to-shader-graph-part-3/

#shadergraph
Daniel Ilett: Games | Shaders | Tutorials Unity Shader Graph Basics (Part 1 - Your First Graph) Big Beginnings
  • 👍 5
  • 🔥 1
Older posts →
Threads Profile ViewerView any public Threads profile without an account.Open ThreadLook →Writing with AI? Make it sound human.Metric37 rewrites AI drafts so they read naturally. Free AI detector, 1,500 words free.Try Metric37 →