weird issue with vertex shader

The Partridge Family were neither partridges nor a family. Discuss.
Post Reply
hello3d
Posts: 3
Joined: January 14th, 2020, 3:57 am

weird issue with vertex shader

Post by hello3d » January 14th, 2020, 6:13 am

Hi everyone,
I'm following Direct3D hardware series. I was trying to draw plane with hills and box in the same scene. I does work. However if I try to draw box only doesn't draw. However, I can draw plane with hills alone and with box. Strange thing is I don't change anything just comment out draw call function if I don't want to draw. When I need to draw just uncomment the code. I checked vertex shader with graphics debugger when I draw it alone its vertices 0,0,0 but without changing anything if I draw both of them it works fine.Any help appreciated. Thanks.
Attachments
png2pdf.pdf
(593.76 KiB) Downloaded 150 times

User avatar
chili
Site Admin
Posts: 3948
Joined: December 31st, 2011, 4:53 pm
Location: Japan
Contact:

Re: weird issue with vertex shader

Post by chili » January 14th, 2020, 12:39 pm

It sounds to me like you're missing some crucial bindable with your box. When you draw with other entities those entities bind it and then it carries over to your box draw.

Sharing code over a pdf filled with screencaps is weird. Post a link to your repo on github.
Chili

hello3d
Posts: 3
Joined: January 14th, 2020, 3:57 am

Re: weird issue with vertex shader

Post by hello3d » January 14th, 2020, 7:06 pm

Sorry for inconvenience about pdf thing. Here is my https://github.com/Caalp/Direct3D/tree/BufferProblems github repo. I was also suspecting that what you said however, I couldn't figure out.

hello3d
Posts: 3
Joined: January 14th, 2020, 3:57 am

Re: weird issue with vertex shader

Post by hello3d » January 15th, 2020, 5:19 pm

Thanks Chili I looked at more closer. As you mentioned before something was missing in box shape. Problem fixed.

albinopapa
Posts: 4373
Joined: February 28th, 2013, 3:23 am
Location: Oklahoma, United States

Re: weird issue with vertex shader

Post by albinopapa » January 15th, 2020, 6:48 pm

Whew, glad you figured it out.
If you think paging some data from disk into RAM is slow, try paging it into a simian cerebrum over a pair of optical nerves. - gameprogrammingpatterns.com

User avatar
chili
Site Admin
Posts: 3948
Joined: December 31st, 2011, 4:53 pm
Location: Japan
Contact:

Re: weird issue with vertex shader

Post by chili » January 16th, 2020, 7:55 am

Saves me the trouble of cloning :D

Eventually I'd like to have some kind of analysis in place that checks for missing bindables like this.
Chili

Post Reply