Standard building codes require that bedrooms and even some basements have exit options like doors and windows in the event of fire. These exits fall within egress codes and provide minimum sizing for windows so people can fit through them and exit the home. Window and door sizes in the International Residential Code (IRC) ensure that these minimum requirements are met.
Placement and usability of windows is very important in green building, as wind, light and heat are used to their best advantage depending on the position of the house, but ensuring that the windows are the right size for providing escape routes in an emergency is one code "gray area" that isn't really gray. Having smaller than recommended upper-level windows to reduce heat in an upper bedroom, for example, will be flagged by most any standard, as would building in the cool sub-ground without an adequate way out.
Building with salvaged or recycled materials also can cause issues. For decades building code agencies in the United States have set guidelines for window materials and strength, and these are part of the International Energy Conservation Code (IECC). Using approved materials increases both energy efficiency and solar capabilities, and many older windows simply don't measure up.
There are rules for the actual placement of windows, too. Standard building codes set forth heights and spacing, but local requirements will determine the code-worthiness of where you put your windows in order to maintain the load-bearing balances of the roof weight, for example.