Replies: 1 comment 5 replies
-
if I set the virtual machine to have 8 cores I have this |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I've replaced
gavare.c
from the default demos that are installed. While it worked well I wasn't able to figure out how to make it run in parallel. I think it was due to all of the global variables being modified during runtime. I found another ray tracer written by Andrew Kensler and was able to get it running on BareMetal. I was also able to get it running in parallel! Each available core will render a line until the image is finished.https://github.com/ReturnInfinity/BareMetal-Demo/blob/master/src/raytrace.c
Note the lines at the bottom of the image as each core renders a line. This was on the 4-core VirtualBox system
![Screenshot 2024-08-31 at 2 27 06 PM](https://private-user-images.githubusercontent.com/800906/363432854-26302326-bbb9-43e3-90e0-d09c19c56aa8.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkzNDM1NjksIm5iZiI6MTczOTM0MzI2OSwicGF0aCI6Ii84MDA5MDYvMzYzNDMyODU0LTI2MzAyMzI2LWJiYjktNDNlMy05MGUwLWQwOWMxOWM1NmFhOC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjUwMjEyJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI1MDIxMlQwNjU0MjlaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0wMTEzNTE5MDQwMjkwODA3YmNiNTRiMTJhMTZhZTI1ZDI0NGNhMzY1YjY3MzQ4ZDdlOWU5M2M1ZmNiNjU3NTZjJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.Eji67rn2TGO_PS7aNWINlU84mtD-3-NT5kE-BfT0KJw)
I've also tested this on a 6-core physical system.
gavare.c
will remain inBareMetal-Demo
for reference.Beta Was this translation helpful? Give feedback.
All reactions