Drawing Sprites To The Screen
We update out display functionality in this lecture to give it the ability to draw sprites to the screen which is a requirement of emulating the Chip-8 Lesson locked purchase
Description
This course is great for anyone who has programming experience and would love to create an emulator but just does not know where to start or has attempted to do it but ran into problems
You are taken through every step of emulator creation, throughout this course we start by setting up our project, then we start writing code to emulate the display and keyboard from the era. We soon move to simulating the entire Chip-8 instruction set.
After you complete this course you will have a fully functioning Chip-8 emulator that can run space invaders, pong and many other classic games.
Requirements
-
You must be confident in the C programming language
-
You must understand hexadecimal
-
You must understand bitwise operators and bit shifting
Who This Course is For
People interested in how to create an emulator
What You Will be Learn
How to create an emulator for the Chip-8 machine
Knowledge of how instruction sets work
Understanding of how machines work
Dragon Zap Instructor
Daniel McCarthy is a seasoned software engineer, boasting an impressive career spanning over 14 years in the industry. Holding a Master's Degree in Advanced Computer Science from Cardiff Metropolitan University, his broad spectrum of experience encompasses everything from web development to complex compiler and interpreter development. Daniel has honed his skills in bootloader and kernel development. In testament to his proficiency in the field, he has designed two proprietary programming languages: Craft, a general-purpose language, and Marble, a web-focused language akin to PHP. Moreover, he has successfully developed compilers for the C programming language. A testament to his versatility, Daniel demonstrates proficiency in an extensive list of programming languages that includes C, C++, Java, x86 Assembly language, PIC assembly, SQL, PHP, HTML5, JavaScript, CSS, and of course, his own creations, Craft and Marble. His professional portfolio also includes the development of Linux kernel modules, a task he has executed with proficiency in a professional context. Currently, Daniel is channeling his wealth of experience and expertise into the education sector, with the aim of nurturing the next generation of professional software engineers.
Ask a question
Questions (1)
Thomas Treffry
2 years ago
Please may you provide more information regarding the `const char* sprite` argument in `chip8_screen_draw_sprite`? I am a little confused by this. When we call `chip8_screen_draw_sprite` from `main.c`, we are passing in a pointer to the first element of the memory array, `&chip8.memory.memory[0x00]`. Due to the `memcpy` call in `chip8_init`, the first element of the chip8.memory.memory array should be the same as the first element of the `chip8_default_character_set`. Does that make sense? If so, the value of the `sprite` argument would be `0xf0`. However, I don't think that is accurate because we then do an index lookup `char c = sprite[ly]`. How does this work and where am I going wrong with my logic?
Daniel McCarthy
2 years ago
Hi, I don't quite understand what your asking me can you break down a little further your problem
Thomas Treffry
1 year ago
Hi Daniel, I dug into this over Christmas and identified a knowledge gap with C pointers. Now that I understand pointers, the code makes sense. Thanks for a great course, I am enjoying it!
Daniel McCarthy
1 year ago
Your very welcome Thomas all the best please reach out if theirs anything else