爱的感觉

是平静的 像永恒的感觉

像摘取一些简单纯粹的果实

于是

坚持一件事情

像爱人一样

守护永恒的感觉

GLSL: Two Shader Programs in Three Viewports

119 013- 0 039

Steps to render the above sunrise rendering from one viewport to three viewports, to compare three elements of sunrise – Rayleigh, Mie, Rayleigh and Mie:

  • In fragment shaders of the skydome and the area light, set three outputs
  • In CPU, configure three textures for a framebuffer, each of which is rendered from a color attachment [1]. The three color attachments take values of the three outputs from the fragment shaders [2]
  • In the framebuffer, render the two fragment shaders of the skydome and area light to the three textures
  • Render the three textures to three viewports on the screen [2]
image from ios

References

[1] Fragment Shader Output Buffers. https://www.khronos.org/opengl/wiki/Fragment_Shader#Output_buffers

[2] Render To Texture. http://www.opengl-tutorial.org/intermediate-tutorials/tutorial-14-render-to-texture

GLSL Debugging Trick: Version Control

Small mistakes could be time-consuming to find out in GLSL shaders. But found a good way to figure out:

If the shader is not working after some change, check the code change in version control tools, compare line by line change, from which figure out what change broke the shader.

In this example, I deleted the left parenthesis, then the shader broke. But figured out immediately with the help of version control comparison:

capture

Boston

I am getting too comfortable in Boston

Like melting..

Unlike jumping and leaving in the past life

This time, I can stay

After all, it’s the people that matters

Salt Lake City is lover

Her beauty is not comparable, though

Thoughts on Short Production and Research

While I’ve been struggling and deciding whether to reinvent the wheel for the production of the short film, or to use existing techniques, Christmas and New Year break helped me clear my mind, realizing that re-inventing the wheel would be time-consuming, even it’s what I really want to do. I have the responsibility to deliver the film one time 😉

I could do the two things simultaneously, by focusing on important things and delegating unnecessary works. Luckily the important things are what I love – research! Yay!

MacBook Audio Routing with Loopback

MacBook Configuration of:

Feature 1: Safari and Built-in Microphone to Zoom:

  • Loopback:
    • [Sources] Safari -> [Output Channels] Channels 3 & 4
    • [Sources] Built-in Microphone -> [Output Channels] Channels 1 & 2
  • System Sound: Input: Loopback Audio
  • Zoom Settings: Audio: Microphone: Same as System, or Loopback Audio

Feature 2: Safari to Built-in Output:

  • Loopback: [Output Channels] Channels 3 & 4 -> [Monitors] Built-in Output

How it looks on Loopback:

Screen Shot 2018-12-13 at 11.25.54 AM

How to Delete an Elements on Loopback:

Step 1: Select the element

Step 2: MacBook Tool Bar > Edit > Delete, or command + delete

Pros and Cons of PhD for Expressive Graphics Techniques of Animated Short

Via PhD or a startup, the focus is to take Expressive Graphics techniques to create animated short films.

Here is a list of pros and cons of choosing PhD or directly work on it alongside a full-time Software Engineer job:

Pros of PhD:

  • Resource in the industry of Expressive Graphics
  • Credibility of the capability for turning the research idea into product of the startup. Because investors like to see such training

Cons of PhD:

  • Challenging to find good match in research interests in the USA. (except for University of Cambridge, where it is possible to propose a whole new area. As long as there is a match with advisors, the student could get admitted)
  • Give up the startup in Boston due to visa conflict
  • Challenging to get funding

Pros of working on the startup alongside full-time software engineer job:

  • Access to business / investment resources in Cambridge Innovation Center
  • Finish the ongoing projects
  • Get the startup run in the right direction
  • Don’t have to worry about funding

Cons of working on the startup alongside full-time software engineer job:

  • Challenging to get equal credibility as via a PhD program. How to complement: do the same level of intensity in mentality training as PhD programs
  • Challenging to keep up the productivity before getting green card
  • Challenging to get funding
  • Challenging to acquire a creative team

The Meaning of Deep Understanding

The nature of invention is expressing the same thing in a different manner. This requires deep understanding of the subject. Some people invent purely from their own understanding, other expand their knowledge to gain deep understanding to facilitate the invention.

The better the understanding, the more likely the transformative impact of the invention.