C++ Pointers: The Definitive Guide

Описание к видео C++ Pointers: The Definitive Guide

👉 GET THE AUDIO PLUGIN DEVELOPER CHECKLIST: https://thewolfsound.com/checklist/
✅ Check out the full article on TheWolfSound.com: https://thewolfsound.com/c-plus-plus-...
✅ Sign up for WolfSound's newsletter: https://thewolfsound.com/newsletter/
✅ Please subscribe to WolfSound to let the little Wolf 🐺 grow:
https://www.youtube.com/c/WolfSoundAu...
🎧 Listen to my music: https://thewolfofficial.com/
✅ Article on data alignment in vectors: https://thewolfsound.com/data-alignme...

Hi, my name is Jan Wilczek. I am an audio programmer and a researcher. Welcome to WolfSound!

WolfSound's mission is to provide high-quality, informative, and entertaining videos, articles, and courses on how to process sound by exploring mathematics, applying algorithms, and creating code in various programming languages. Topics include sound synthesis, digital signal processing, programming languages for audio (C, C++, Python, Rust), and audio effects. I am also sharing tips on how to learn fast and effectively. Make sure to visit https://www.thewolfsound.com/.

WolfSound enables everybody to learn about audio programming!

ABOUT THE VIDEO

Pointers in C and C++ is a confusing topic for all programmers new to this language. In this video, I am thoroughly explaining all concepts related to pointers that are relevant for audio programming. If you are new to C++ and audio programming this is your go-to guide.

From the video you will learn:
✅ what are C++ pointers and how to use them,
✅ why do you need pointers in your audio code,
✅ 1 crucial error that most programmers make when using pointers,
✅ how C++ 20 makes it possible to handle heap and stack arrays in a unified way,
✅ 2 things that instantly confuse programmers new to C++ (float** and void*),
✅ how const and pointer types interact,
✅ why assigning a float** to a const float** is a bad idea (it is!),
✅ where does JUCE C++ framework use pointers.

ABOUT ME

My name is Jan Wilczek. I am an audio programmer, a researcher in the field of music technology, and a musician. Through articles and videos from WolfSound, you will easily understand the main concepts of sound processing using software. My full story:    • How I Got Started With Audio Programm...  

FOLLOW WOLFSOUND ONLINE

✅ Blog: https://www.thewolfsound.com/
✅ LinkedIn:   / jan-wilczek-audio-programmer  
✅ Twitter:   / wilczek_jan  
✅ Facebook:   / janwilczekwolfsound  
✅ Instagram:   / janwolfwilczek  
✅ Pinterest:   / jawitrle  

TIME CODES

00:00 Introduction
01:54 What is a pointer?
03:59 Static arrays (=size known at compile time)
11:06 Dynamic arrays (=size known at run time)
17:54 Dynamic objects (=allocated on the heap)
19:28 When to use dynamically allocated objects?
23:14 In audio programming: dynamically allocated objects and pointers to arrays
24:39 How to point nowhere: nullptr
29:13 What is void*?
37:18 Bonus
37:56 Double pointer? float**
42:23 When memory allocation fails: std::bad_alloc
43:03 Audio callbacks and samples as float**
45:50 Pointers and the const keyword
49:40 Extra tip
49:58 Why cannot we cast from float** to const float**?
53:47 Why passing a raw pointer to an array and its size to a function is problematic and how to fix it with std::span
01:02:20 Summary

#cpp #pointers

Комментарии

Информация по комментариям в разработке