Everyday Unity – Telegram
Everyday Unity
1.1K subscribers
157 photos
59 videos
42 files
2.36K links
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
Download Telegram
Here’s a pattern to easily access information that should be calculated only once per frame

https://blog.beardphantom.com/post/190886958254/heres-a-pattern-to-easily-access-information-that?is_related_post=1

#optimization #dataaccess
An interesting benchmark on Json Parsing using Newtonsoft Json Serializer
I wanted to see the difference in parsing speeds between this custom method
https://www.newtonsoft.com/json/help/html/ReadingWritingJSON.htm
And the regular
JsonConvert.DeserializeObject<>() method Result

Manual deserialization is 50.03% faster then the regular method. However  - The Manual deserialization is 196 lines of code compared to just 1.

I also tested if running the parsers in Multithreading was helpful and it wasn’t, just they synchronization between threads took longer then the whole job. So for most Jsons we experience I did not find any speed benefit in multithreading.

#deserialization #json
Deep C# - Casting the Escape from Strong Typing

This ability to accept a bigger object i.e. you can safely downcast the parameter, is often referred to as contravariance. That is the return parameter can be safely upcast to a smaller object and this in turn is refered to as covariance.

https://www.i-programmer.info/ebooks/47-deep-c/493-deep-c-c4.html

#cast #csharp
Shader Tutorial: Pulsing to Audio

A very detailed guide how to make shader that reacts to audio input

https://www.patreon.com/posts/shader-tutorial-38679948

#shader #audioinput #pulse