## Search found 40 matches

June 16th, 2021, 2:42 am
Forum: Everything
Topic: Question about typedef template
Replies: 2
Views: 72

### Re: Question about typedef template

Double quotes qualify a variable with it's scope. In this case, it's requesting the Pipeline from the global scope ie the Pipeline<> template class which is aliased as Pipeline. The other alias is LightIndicatorPipeline made from Pipeline<SolidColorEffect>. The compiler might get confused and try u...
June 8th, 2021, 11:00 am
Forum: Everything
Topic: Question about typedef template
Replies: 2
Views: 72

### Question about typedef template

Hi all, I'm at 3D Programming Fundamentals Tutorial 16. At video 9:08 why we need double-colon before typedef Pipeline template? What does it do? typedef ::Pipeline<GouraudPointEffect> Pipeline; typedef ::Pipeline<SolidColorEffect> LightIndicatorPipeline; This is my first time to read statement like...
September 28th, 2020, 4:08 am
Forum: Everything
Topic: 3D Fundamentals Texture Mapping Geometry Question
Replies: 5
Views: 873

### Re: 3D Fundamentals Texture Mapping Geometry Question

I finally figure out how this work by drawing texture on the cube face by face using my own texture! Please ignore my previous post. Here is how I work: Say we have a stickman texture with green head, white body, blue right hand, and red left hand Stickman.png We also have a unfold cube with numbere...
September 26th, 2020, 4:33 am
Forum: Everything
Topic: 3D Fundamentals Texture Mapping Geometry Question
Replies: 5
Views: 873

### Re: 3D Fundamentals Texture Mapping Geometry Question

Vertex positions are based on the distance from some origin of the model. For the cube it's the origin is the center and the vertices' positions are some distance from the center. The order in which you put those vertices depends on what API you are using and how it calculates whether a triangle is...
September 25th, 2020, 11:12 am
Forum: Everything
Topic: 3D Fundamentals Texture Mapping Geometry Question
Replies: 5
Views: 873

### 3D Fundamentals Texture Mapping Geometry Question

I'm at 3D Fundamentals Texture Mapping series. I don't understand "unfolding the geometry of the cube" part video . Chili gives following code: CubeFolded( float size ) { const float side = size / 2.0f; vertices.emplace_back( -side,-side,-side ); // 0 tc.emplace_back( 1.0f,0.0f ); vertices.emplace_b...
August 13th, 2020, 1:15 am
Forum: Everything
Topic: Advanced C++ Tutorial 2 HW star overlapped question
Replies: 3
Views: 648

### Re: Advanced C++ Tutorial 2 HW star overlapped question

Luckily you uploaded your solution, because the problem isn't in the function at all. std::uniform_real_distribution<float> distOuter(10.0f, 100.0f); std::uniform_real_distribution<float> distInner(5.0f, 50.0f); I originally thought that this was the problem, since there is overlap between the larg...
August 12th, 2020, 4:01 pm
Forum: Everything
Topic: Advanced C++ Tutorial 2 HW star overlapped question
Replies: 3
Views: 648

### Advanced C++ Tutorial 2 HW star overlapped question

I'm doing Advanced C++ Tutorial 2 homework. One of tasks is that generating the stars which do not overlapped each other. I wrote following code to check overlapped stars, but it's not working (the star still overlapped). What's wrong with my code? bool Game::IsOverlapped(Vec2 position, float radius...
May 14th, 2020, 2:50 am
Forum: Everything
Topic: What's the right way to calculate time? Counting by time or counting by frame?
Replies: 2
Views: 1155

### Re: What's the right way to calculate time? Counting by time or counting by frame?

Considering you are wanting time elapsed since last check, you should use time. Time is constant whereas frame rate is not. For instance, let's say you have a 140Hz monitor. Your frame rate is capped at 140 frames per second if v-sync is enabled whereas my monitor is 60Hz, so I'm capped at 60 frame...
May 10th, 2020, 11:06 pm
Forum: Everything
Topic: What's the right way to calculate time? Counting by time or counting by frame?
Replies: 2
Views: 1155

### What's the right way to calculate time? Counting by time or counting by frame?

Hi, guys, I found out there's two ways to calculate time. One is counting by time another counting by frame. Let's say we need to move a character in a period of time. One way we could count by time Like this: dt = ft.GetFrameTime(); gameTime += dt; if (gameTime >= 1.0f) { gameTime -= 1.0f; characte...
April 24th, 2020, 1:25 am
Forum: Everything
Topic: My first release!
Replies: 9
Views: 2418

### Re: My first release!

Hi, Aleksiy
I play your game, and it was amazing!!
I wonder how long did you take when you start to learn until you finish the game?