Here is what I saw on GPU GEMS - Chapter 8. Simulating Diffraction:
One can see the code part is a mess from my side.
Here is what I saw on GPU GEMS - Chapter 8. Simulating Diffraction:
One can see the code part is a mess from my side.
Hi @ziyuang,
I am not sure how this should look. I have no way to verify without seeing the book’s content that was initially published in 2004.
I would expect something at least as above, i.e., one newline after each ;
or }
, also one newline after each {
or the )
right before each {
, depending on the style.
I have access to a scanned version and these are the relevant pages, which seem even better, as the function parameters have their own lines:
Cool! I will pass this on to the team that manages that page.
Thanks,
Tom
Thanks. I think it happens on every page with code, from GPU Gems 1 to GPU Gems 3.
Can confirm the broken code snippets are still present in all the GPU Gems book. It’s weird that this is the only thread talking about it. I thought I had something wrong with my web layout.
Have you found any fix apart from downloading the scanned version ?
Same here, I’m reading gpu gems lately and the problem still exist.
I have bumped this issue to the team that manages the site.
Thanks for your patience,
Tom
Yes, unfortunately this is all of the code in all three books. One of NVIDIA’s most classic resources, in disarray and rendered hard to use.
The following Python works to at least make most of the code readable, by detecting the inlined space indents (apply to contents of <pre></pre>
tags):
re.sub(r'([^ ])[ ][ ]', "\\1\n[ ][ ]", code_block)
edit: I had to put the pair of spaces in brackets because the NVIDIA forum software is truncating them :p
Anyway, it’d be awesome if you guys could fix this-
I just noticed GPU Gems 3 has its chapter subsections ordered lexically instead of numerically, which is problematic in ch. 9,13,19.
For example chapter 9:
9.1 Introduction
9.10 Conclusion
9.11 References
9.2 An Overview of the Algorithm
…
The 100’s of broken code samples are more critical though.
C formatters fail because the code is inlined into the comments, besides the non-C uses of ‘:’…
Thanks for your time
Hi @jrodatus,
Thanks for visiting the forums. There is an internal ticket open to look at this. Unfortunately, I do not have an ETA at this time.
Best regards,
Tom
@TomNVIDIA,
Thanks for the reply- understandable.
To others- I’m guessing the edit to the formatting hack didn’t transfer through the email notifs–see edit due to forum software not respecting code tags.
This topic was automatically closed 60 minutes after the last reply. New replies are no longer allowed.