60 Second Binary Options - How and Where to Trade

Selling your Covered Call - Thoughts on How to Select Your Strike and Expiration

Congratulations! You are a bag holder of company XYZ which was thought to be the best penny stock ever. Instead of feeling sorry, you consider selling covered calls to help reduce your cost basis - and eventually get out of your bags with minimal loss or even a profit!
First - let's review the call option contract. The holder of the call option contract has the right but not the obligation to purchase 100 shares of XYZ at the strike price per share. This contract has an expiration date. We assume American style option contracts which means that the option can be exercised at any point prior to expiration. Thus, there are three parameters to the option contract - the strike price, the expiration date and the premium - which represents the price per share of the contract.
The holder of the call option contract is the person that buys the option. The writer of the contract is the seller. The buyer (or holder) pays the premium. The seller (or writer) collects the premium.
As an XYZ bag holder, the covered call may help. By writing a call contract against your XYZ shares, you can collect premium to reduce your investment cost in XYZ - reducing your average cost per share. For every 100 shares of XYZ, you can write 1 call contract. Notice that that by selling the contract, you do not control if the call is exercised - only the holder of the contract can exercise it.
There are several online descriptions about the covered call strategy. Here is an example that might be useful to review Covered Call Description
The general guidance is to select the call strike at the price in which you would be happy selling your shares. However, the context of most online resources on the covered call strategy assume that you either just purchased the shares at market value or your average cost is below the market price. In the case as a bag holder, your average cost is most likely over - if not significantly over - the current market price. This situation simply means that you have a little work to reduce your average before you are ready to have your bags called away. For example, you would not want to have your strike set at $2.50 when your average is above that value as this would guarantee a net loss. (However, if you are simply trying to rid your bags and your average is slightly above the strike, then you might consider it as the strike price).
One more abstract concept before getting to what you want to know. The following link shows the Profit/Loss Diagram for Covered Call Conceptually, the blue line shows the profit/loss value of your long stock position. The line crosses the x-axis at your average cost, i.e the break-even point for the long stock position. The green/red hockey stick is the profit (green) or loss (red) of the covered call position (100 long stock + 1 short call option). The profit has a maximum value at the strike price. This plateau is due to the fact that you only receive the agreed upon strike price per share when the call option is exercised. Below the strike, the profit decreases along the unit slope line until the value becomes negative. It is a misnomer to say that the covered call is at 'loss' since it is really the long stock that has decreased in value - but it is not loss (yet). Note that the break-even point marked in the plot is simply the reduced averaged cost from the collected premium selling the covered call.
As a bag holder, it will be a two-stage process: (1) reduce the average cost (2) get rid of bags.
Okay let's talk selecting strike and expiration. You must jointly select these two parameters. Far OTM strikes will collect less premium where the premium will increase as you move the strike closer to the share price. Shorter DTE will also collect less premium where the premium will increase as you increase the DTE.
It is easier to describe stage 2 "get rid of bags" first. Let us pretend that our hypothetical bag of 100 XYZ shares cost us $5.15/share. The current XYZ market price is $3/share - our hole is $2.15/share that we need to dig out. Finally, assume the following option chain (all hypothetical):
DTE Strike Premium Intrinsic Value Time Value
20 $2.5 $0.60 $0.50 $0.10
20 $5.0 $0.25 $0 $0.25
20 $7.5 $0.05 $0 $0.05
50 $2.5 $0.80 $0.50 $0.30
50 $5.0 $0.40 $0 $0.40
50 $7.5 $0.20 $0 $0.20
110 $2.5 $0.95 $0.50 $0.45
110 $5.0 $0.50 $0 $0.50
110 $7.5 $0.25 $0 $0.25
Purely made up the numbers, but the table illustrates the notional behavior of an option chain. The option value (premium) is the intrinsic value plus the time value. Only the $2.5 strike has intrinsic value since the share price is $3 (which is greater than $2.5). Notice that intrinsic value cannot be negative. The rest of the premium is the time value of the option which is essentially the monetary bet associated with the probability that the share price will exceed the strike at expiration.
According to the table, we could collect the most premium by selling the 110 DTE $2.5 call for $0.95. However, there is a couple problems with that option contract. We are sitting with bags at $5.15/share and receiving $0.95 will only reduce our average to $4.20/share. On expiration, if still above $2.5, then we are assigned, shares called away and we receive $2.50/share or a loss of $170 - not good.
Well, then how about the $5 strike at 110 DTE for $0.50? This reduces us to $4.65/share which is under the $5 strike so we would make a profit of $35! This is true - however 110 days is a long time to make $35. You might say that is fine you just want to get the bags gone don't care. Well maybe consider a shorter DTE - even the 20 DTE or 50 DTE would collect premium that reduces your average below $5. This would allow you to react to any stock movement that occurs in the near-term.
Consider person A sells the 110 DTE $5 call and person B sells the 50 DTE $5 call. Suppose that the XYZ stock increases to $4.95/share in 50 days then goes to $8 in the next 30 days then drops to $3 after another 30 days. This timeline goes 110 days and person A had to watch the price go up and fall back to the same spot with XYZ stock at $3/share. Granted the premium collected reduced the average but stilling hold the bags. Person B on the other hand has the call expire worthless when XYZ is at $4.95/share. A decision can be made - sell immediately, sell another $5 call or sell a $7.5 call. Suppose the $7.5 call is sold with 30 DTE collecting some premium, then - jackpot - the shares are called away when XYZ is trading at $8/share! Of course, no one can predict the future, but the shorter DTE enables more decision points.
The takeaway for the second step in the 2-stage approach is that you need to select your profit target to help guide your strike selection. In this example, are you happy with the XYZ shares called away at $5/share or do you want $7.5/share? What is your opinion on the stock price trajectory? When do you foresee decision points? This will help determine the strike/expiration that matches your thoughts. Note: studies have shown that actively managing your position results in better performance than simply waiting for expiration, so you can adjust the position if your assessment on the movement is incorrect.
Let's circle back to the first step "reduce the average cost". What if your average cost of your 100 shares of XYZ is $8/share? Clearly, all of the strikes in our example option chain above is "bad" to a certain extent since we would stand to lose a lot of money if the option contract is exercised. However, by describing the second step, we know the objective for this first step is to reduce our average such that we can profit from the strikes. How do we achieve this objective?
It is somewhat the same process as previously described, but you need to do your homework a little more diligently. What is your forecast on the stock movement? Since $7.5 is the closest strike to your average, when do you expect XYZ to rise from $3/share to $7.5/share? Without PR, you might say never. With some PR then maybe 50/50 chance - if so, then what is the outlook for PR? What do you think the chances of going to $5/share where you could collect more premium?
Suppose that a few XYZ bag holders (all with a $8/share cost) discuss there outlook of the XYZ stock price in the next 120 days:
Person 10 days 20 days 30 days 40 days 50 days 100 days 120 days
A $3 $3 $3 $3 $3 $4 $4
B $4 $4 $5 $6 $7 $12 $14
C $7 $7 $7 $7 $7 $7 $7
Person A does not seem to think much price movement will occur. This person might sell the $5 call with either 20 DTE or 50 DTE. Then upon expiration, sell another $5 call for another 20-50 DTE. Person A could keep repeating this until the average is reduced enough to move onto step-2. Of course, this approach is risky if the Person A price forecast is incorrect and the stock price goes up - which might result in assignment too soon.
Person B appears to be the most bullish of the group. This person might sell the $5 call with 20 DTE then upon expiration sell the $7.5 call. After expiration, Person B might decide to leave the shares uncovered because her homework says XYZ is going to explode and she wants to capture those gains!
Person C believes that there will be a step increase in 10 days maybe due to major PR event. This person will not have the chance to reduce the average in time to sell quickly, so first he sells a $7.5 call with 20 DTE to chip at the average. At expiration, Person C would continue to sell $7.5 calls until the average at the point where he can move onto the "get rid of bags" step.
In all causes, each person must form an opinion on the XYZ price movement. Of course, the prediction will be wrong at some level (otherwise they wouldn't be bag holders!).
The takeaway for the first step in the 2-stage approach is that you need to do your homework to better forecast the price movement to identify the correct strikes to bring down your average. The quality of the homework and the risk that you are willing to take will dedicate the speed at which you can reduce your average.
Note that if you are unfortunate to have an extremely high average per share, then you might need to consider doing the good old buy-more-shares-to-average-down. This will be the fastest way to reduce your average. If you cannot invest more money, then the approach above will still work, but it will require much more patience. Remember there is no free lunch!
Advanced note: there is another method to reduce your (high) average per share - selling cash secured puts. It is the "put version" of a cover call. Suppose that you sell a XYZ $2.5 put contract for $0.50 with 60 DTE. You collect $50 from the premium of the contract. This money is immediately in your bank and reduces your investment cost. But what did you sell? If XYZ is trading below $2.50, then you will be assigned 100 shares of XYZ at $2.50/share or $250. You own more shares, but at a price which will reduce your average further. Being cash secured, your brokerage will reserve $250 from your account when you sell the contract. In essence, you reduce your buying power by $250 and conditionally purchase the shares - you do not have them until assignment. If XYZ is greater than the strike at expiration, then your broker gives back $250 cash / buying power and you keep the premium.

Early assignment - one concern is the chance of early assignment. The American style option contract allows the holder the opportunity to exercise the contract at any time prior to expiration. Early assignment almost never occurs. There are special cases that typically deal with dividends but most penny stocks are not in the position to hand out dividends. Aside from that, the holder would be throwing away option time value by early exercise. It possibly can handle - probably won't - it actually would be a benefit when selling covered calls as you would receive your profit more quickly!


This post has probably gone too long! I will stop and let's discuss this matter. I will add follow-on material with some of the following topics which factors into this discussion:
Open to other suggestions. I'm sure there are some typos and unclear statements - I will edit as needed!
\I'm not a financial advisor. Simply helping to 'coach' people through the process. You are responsible for your decisions. Do not execute a trade that you do not understand. Ask questions if needed!**
submitted by x05595113 to pennystockoptions [link] [comments]

The Sun Rises as Usual: My thoughts on the enactment of the national security law in Hong Kong (Author: Simon Shen 沈旭暉)

The below essay by Simon Shen (沈旭暉), a Hong Kong-based political scientist and columnist.
Link to original essay: Facebook
YouTube channel (Cantonese)
His videos and articles has been on this sub a few times (See https://redd.it/hmttfa https://redd.it/gn5j83), so I thought this one is also worth a read and discuss, whether we agree or not.

The Sun Rises as Usual: My thoughts on the enactment of the national security law in Hong Kong

July 1st, 2020 shall be remembered as the day Hong Kong completed its second Handover to China. A strong sense of despair clouds over the city as Beijing nuked us with the National Security Law (NSL). The thought of losing the authenticity of Hong Kong forever is ingrained in many of us.
The same day, the sun rises in the east as usual.The rule of thumb to survive this era of turmoil is to maintain control of your mental state. Remain unflappable by the ongoing absurdity. You live your life at your own pace with no restrictions. And that is how you win in society, at the workplace, on campus, and in marriage.
As to how we could achieve that, I hope my two-cents would give you some ideas.
The officials expected us to be overwhelmed, terrified, and occupied by NSL. Nevertheless, the clauses of the law have never been the main course of this extravagant meal. What truly awaits for us is the complete makeover of the Hong Kong ruling. Abolishing the standard procedure inherited from British Hong Kong, rationality and logical decision-making are soon replaced by the ambiguity of the authoritarian “rule of law” of China. Hong Kong has lost its place in the globe at the mercy of NSL; that is, to show a lucid message: Beijing could withdraw the “One Country, Two Systems” principle however it sees fit. Moreover, it is the re-education training CCP set up for Hongkongers to make them know their place and accept the “Mainland ideology,” which includes tolerating laws and regulations that are more “lenient” to serve the Chinese political agenda. Placing the national interests in heart, it is farewell to “Rule of Law,” and the common understanding of right and wrong and dos and don’ts.
This is the textbook example of authoritarian ruling. Perhaps people would be seeing some form of democracy and freedom; however, those were merely decoys in which the supreme power vested afar.
23 years after the Handover, pro-Beijing population remains small by default. The young generation rebukes Chinese identity even more than before. The enactment of NSL indicates the failure of CCP’s strategic approaches to entice Hongkongers. If the regular and United Front approaches failed through, they might as well execute eradication instead. It may appear as China is calling for enticement, but the underlying measures/gimmicks are showing something else. The grand Unity of Mainland and Hong Kong is nothing more than a hoax.
In this new Hong Kong, measurements taken to appease public backlash or allow people to express their frustration toward politicians or policies are stored in the past. Furthermore, the Hong Kong government has adopted more extreme approaches—severing Hong Kong into the pro-democracy camp and the pro-Beijing camp; bringing back Cultural Revolution tactics to effectively counteract dissentance; and activating 24/7 monitorization of the population. The propaganda of the CCP regime is to increasingly disintegrate the mutual trust between people by ratting and spying. Building the new norm where the civil society crumbles and espionage is normalized. People with malicious intent may find this new world rather exciting. Without the checks and balances or supervision in the system, the escalating waves of purging the “impure” in the next 2 years are anticipated.
The hostile public opinion of Hong Kong toward Beijing’s decisions have always been a throne in the flesh for the ruling party which led to it prioritizing the disunification of the Hong Kong civil society in the following 2 years—gathering the elites from all professions, alternating the policies of media regulations, reforming education to be more CCP-interests-oriented, and emphasizing the governmental compliance of all departments for effective executions of the new laws. The small population that is most affected by NSL would be those who are in the “Four Black Categories,” including the influencers and KOLs. The two major key points for Hong Kong government’s guidelines are “rule by law” and “always have the national interests at heart.” Regardless of NSL, Public Order Ordinance(POO) per se or any other laws could be used to incriminate the dissidents. Even a world-renowned Chinese artist such as Ai Weiwei was accused of Tax Evasion. Apolitical celebrities with millions of fans and could also be targeted; e.g. Fan Bingbing. Over time, people would adapt to self-censorship. As their minds slowly die of a thousand cuts to circumvent trespassing the political “bottom-line”, it includes avoiding dissenting the propaganda and minimizing exposure that may attract unwanted attention.
Oddly enough, if you were to be a tourist, you probably would not be able to capture the post-NSL nuances of this hollow Hong Kong. You would see all business continue, stock market arises, and the real estate market thrives as usual. It is as if the script written for the second Handover would play out successfully, as long as the basic needs of Hongkongers are satisfied.
Amidst of this turmoil, Hongkongers wouldn’t need me to elaborate more; however, we should ask ourselves if there is something else that we could do. Do you still remember how we were like before all of these occur? What are the options we have aside from obeying to the laws, immigrating out of our homeland, or starting riots? How should we live in the middle of this mess?
From the anti-extradition law protest to the ongoing movement we have today—disregarding the variations in the slogans—we are a part of the global transformation which is beyond politics and may very well be a segment of the fourth industrial revolution. Moving forward from now, with AI replacing brain-power taxing positions, it would be unlikely for anyone to have a stable job and their retirement secured. With that being said, we are facing a tomorrow where people could no longer rely on a singular path for career planning. The younglings are determined and flexible about making chances. They are independent individuals who seek for autonomy in life without relying on governmental entities, pro-establishment units, and consortiums, for their survival which tie into a global trend. The “ultrastable system” of the good old times Hong Kong is in the past. The young generation is calling for “Laam Chau.” (self-destruction to counterbalance Hong Kong government) Acknowledging the fact that enduring injustice would not secure any job positions, the young generation tends to take on entrepreneurship and minimizing their political dependency.
Many friends started talking about immigration. A decade ago, the media were hyping the topic regarding whether or not I would be immigrating to Singapore. I have been repeating myself—the concept of immigration is obsolete. Over the past year, would you say that the overseas Hongkongers contributed more to the movement or the apolitical Hongkongers? Even if we hold multiple citizenships, travel around the world, send our children to study abroad, or hold investments in another country, what would it matter? Any of those would not affect our Hongkonger identity. When online classes are given remotely on Zoom, would it matter if you are in Hong Kong or in Congo? The physical location of Hong Kong shouldn’t tie us down. We should sever ourselves from the idea of leaving or staying and make the world our home. By stitching the virtual world to the real world, we are undefeated by constant change. To me, that is what Hong Kong really is.
All censorship from the authoritarian regime have one in common; that is, the oppressions could never be reasoned with the Common Law. If the pro-democracy anthem, “Glory to Hong Kong,” is prohibited to be sung on campuses, what about the 80’s Cantopop hit, “Boundless Oceans, Vast Skies” or “Blowing in the Wind” which both hint liberation in the lyrics? As the movement slogan, “Five Demands, Not One Less,” was banned, could the protesters express their dissent by raising their hands to point out 5 and 1 or having the number 5 and 1 written over their tops? Does everything related to the number 5 and 1 need to be a politically sensitive topic? Could we still talk about the Labor Day that falls on May 1st? The rebellious ideology is embedded in the mind of Hong Kong protesters, as people have witnessed the incompetence of our government on a daily basis. This movement has been embodying innovation in various ways. No extra commentaries are needed. This is the true essence of “be water.”
Similarly, Poland and the Czech Republic in the 60s were under greater oppression than what we have been seeing in recent Hong Kong; however, “life always finds a way.” We now live in a globalized world where “colluding foreign forces” is unnecessary, with the help of our overseas brothers and sisters to amplify the pro-democracy messages to the international community. We shall acknowledge the fact that dwelling on the past does no one any good for sustaining this movement.
You could be someone who lacks the courage to venture out of the comfort zone, refuses to adapt to having multiple careers, resists leaving the physical location of Hong Kong, fears to put on a yellow helmet (a pro-democracy symbol), and chooses to be enslaved by the ruling party. Even if you are a Blue Ribbon ( pro-established or pro-Beijing person), as long as you are not a part of the most extreme 20% of the deep Blue Ribbon community, I say you are still a very valuable asset to Hong Kong. In this NSL-enacted Hong Kong, you should give it some thoughts about what advantages you hold that the “new Hongkongers” cannot offer. If you cannot answer this question, then no matter how patriotic you are, you will be eliminated in the next wave of selection. “Survival the fittest.” Even in Chinese companies, they still need Hongkongers to do the due diligence for them. In bureaucratic institutions, the Chinese would still need someone with a creative spirit and an international perspective while putting on a nationalist front.
Many have expressed their concerns toward the implementation of “Indoctrination” in Hong Kong, including some of the pro-Beijing parents. By sending their children to non-state-owned schools, their actions speak louder than their words. The new trend of education has confirmed that the traditional classroom model inherited from the 19th century Prussian teaching is outdated. Through big data, the teaching materials are personalized for individuals; moreover, students may build up their unique libraries of knowledge via their personal experience and curiosity. Regretfully, the new Hong Kong under authoritarian ruling embraces a rigid education system where syllabi and marking scheme is key to grooming the next generation of nationalists. The instructors would be under surveillance, school principals would bend to state-interests policies, and households would monitor each other for anti-government speeches or actions. Apparently, CCP would not succeed in brainwashing anyone with these educational reformations. Perhaps, Tik Tok may be more effective. Personalized education is an irreversible global trend. The authoritarian Hong Kong could butcher education but it could not prevent people from adapting to other alternatives. I would like to believe that the younger generations would harness the power of the internet and seize the opportunities given by an international community that has become more amiable to Hong Kong.
NSL’s main target is those who are “in collusion with foreign forces. How ironic is it to see how the strong connections between Hong Kong and the global community came back to bite per se? I recall reading from a research report, stating that on average every 1 out of 3 to 4 Hongkongers have connections overseas—overseas relatives, holding foreign qualifications or degrees, overseas working experience, having international investments, or having work contacts with foreign employees. Hongkongers have been colluding with the foreign forces before NSL made it a crime. The 2020 Hong Kong is suffering from cultural discontinuity created by the conflicts between the Chinese authoritarian system and the Western democracy system. Soon enough, “mass surveillance enabled by Big Data” vs. “A.I. regulated by privacy concerns” could be a multiple choice question for all Hongkongers. As long as Hongkongers are connected to the global network, we shall not lose our resilience against oppression.
To sum it up, Hongkongers have incorporated the world into “the revolution of our time.” March on and be water. The world we are facing is no longer black and white or binary of any sort. We may not reap what we sow. This is a long-term fight that requires us to be resourceful, as well as being mentally and physically prepared.
You may ask if I have ever wanted to leave Hong Kong. Ironically, since my 18th birthday, I have never stayed in Hong Kong for so long. The past 6 months, aside from pandemic, I have been sentimental toward this land. My profession and residences require me to travel a lot of places. I hardly stayed in Hong Kong for long as I made that decision deliberately 10 years ago. Now you may understand where I am coming from. Thus, I would not change for this NSL-enacted Hong Kong. I would not stay to make a statement, nor would I leave this land to make a stance. To my dear friends out there, my piece of advice has been the same—live like a digital nomad and have your footstep stamped locally and globally. No need to start from scratch. You may join a community that is well-established.
Should I self-censor for my safety? I’ve never been an editorial writer. My rationally words and videos are merely personal expressions of a Hongkonger. I honestly can’t get any more cautious. I am the same Simon Shen, now and always. We should not take any form of harassment or attacks personally.
Before the extradition law and the NSL, CCP had been effectively silencing dissents by sending them on one-way trips to Mainland China (i.e. Causeway Bay Books disappearances). The regime needed no bills to aid its attempt of kidnapping those who dare to voice up. Hong Kong has fallen too fast that no one bothers to attack or criticize the kidnaps. There is no such thing as making something less absurd by talking about it more. The systematic oppression of Hong Kong’s civil freedom does not only come from the without but also the within; especially when nowadays all we could talk about is “safety” and “survival.” It is exactly what CCP wanted for us to believe—we are trapped and our lives depends on our compliance. Hongkongers are being tested for our resilience. If we couldn’t pass this challenge together, how could we stand up tall as proud Hongkongers?
As to making ends meet, I’ve always believed that the global Hongkonger network is a large enough of encomany to support, expand, and give back to Hong Kong. We are all at its mercy, including me becoming a KOL. Within the Hongkonger community, I wish to be more practical and strategic; especially, in terms of elevating our quality of living. CCP is extremely calculative and different from us. It is my deepest belief that when the world sees how irreplaceable Hongkongers are that is the day when we can anticipate change. Before then, we will keep a low profile and prepare for this long battle.
Do expect the next two years to be a long rollercoaster ride with plenty of ups and downs. Hongkongers will only thrive through the hardships. Buckle up, winter is coming.
submitted by baylearn to HongKong [link] [comments]

CRTPi-RCA NTSC+PAL v3.0F - America & Europe Unite!

CRTPi Project Presents:

CRTPi-RCA v3.0F

A CRTPi image for running 240p via 3.5mm Composite
Other Releases:
Changelog: v3.0F for RCA 5/11/2020
Changelog: v2.0F for RCA 4/1/2020
Changelog: v1.1FX 12/20/2019
Changelog: v1.0F Hotfix 10/31/2019
Changelog: v1.0F 10/29/2019
Changelog: v0.4 10/22/2019
Changelog: v0.3 10/2/2019
What Does That Look Like?
Here are some examples of games being played in beautiful 240p on CRT sets using the RCA Image!.
What is Different?
  • Retropie 4.6 (build 72132587 commit 05/07/20 Buster 10)
  • Retroarch 1.8.5
  • 4GB (3872256 KB Uncompressed Image) (Compressed via WinRAR to 886769NTSC/868059PAL KB)
  • SSH, Samba Share, and USB Rom Service enabled by default
  • Heavily modified Sakitoshi CRT-TVout script for switching between 480i and 240p
  • Optional overclock values in /boot/config.txt for Pi2 & Pi3B (disabled by default)
  • NTSC @ 60hz 720/640x480 480i Resolution for Emulationstation & Kodi
  • PAL @ 50hz 720/640x576 576i Resolution for Emulationstation & Kodi
  • NTSC @ 60hz 640x480 Progressive (240 lines) for Retroarch
  • PAL @ 50hz 640x576 Progressive (288 lines) for Retroarch
  • Per-system custom refresh rates for Retroarch
  • Single-frame Run Ahead enabled for many 8-bit & 16-bit consoles and handhelds for Retroarch
  • Optional 480i mode for PSX and Arcade games
  • Preloaded with free 240p test suites for multiple consoles (PAL SNES & Mega-CD)
  • Preloaded with additional stable (opt) Retroarch emulators
  • Preloaded with DOSBox and ScummVM
  • Preloaded with Kodi 18.2 w/ Convergence Theme @ 480i
  • Preloaded with various 4:3 splashscreens from the RPiF download
  • Preloaded with 4:3 Ruckage's runcommand launching screens for supported systems
  • Custom 4:3 Arcade DOJ "Winners DO Use Drugs" splash screen.
  • Preloaded with MUNT Roland MT-32 MIDI emulation for DOSBox/ScummVM
  • Retroarch FCEUmm (NES) Emulator preconfigured for 4:3 horiz/vert overscan crop enabled w/ composite-direct-fbx pallete
  • Retroarch Picodrive (SMS/32X) Emulator preconfigured for 4:3 with 2.5X Sega Mastersystem & 1X Sega 32X resolution
  • Retroarch Gambatte (GB/GBC) emulator preset to Super Game Boy (Special 1 Pallete) mode with 2x integer scale SGB Overlay
  • Retroarch mGBA (GBA) emulator preset to Game Boy Player mode with 2x integer scale GBP Overlay
  • Other Retroarch handheld emulators preset for optimized wide display with overlay
  • Emulationstation preloaded with KALEL1981's Super-Retroboy theme (default)
  • Emulationstation preloaded with Ruckage's RetroPie menu icons
  • Emulationstation preloaded with Ruckage's snes-mini and nes-mini themes configured for 4:3
  • Emulationstation preloaded with PietDAmore's 240p Honey and Bubblegum themes
  • Custom ScummVM system artwork for snes-mini theme
  • Emulationstation systems ordered chronologically instead of alphabetically
  • Emulationstation preconfigured with best settings for analog A/V including best settings for video preview screensavers
What is Run-Ahead?
The Run Ahead feature calculates the frames as fast as possible in the background to "rollback" the action as close as possible to the input command requested.
I've enabled run-ahead on most of the 8 & 16-bit consoles and handhelds. A single frame (and using the second instance) is saved here, which dramatically improves input lag without affecting performance on a Pi3B+. More frames would require more hardware power, and may be achievable via overclocking.
lr-snes9x2010 consistent 60.0-60.2 FPS @ 60.098801hz lr-fceumm consistent 60.0-60.2 FPS @ 60.098801hz lr-beetle-pce-fast consistent 60.1-60.2 @ 60.000000hz lr-genesis-gx-plus consistent 59.9-60.2 FPS @ 59.922741hz (both genesis and sega cd) lr-picodrive consistent 59.9-60.2 FPS @ 59.922741hz (master system, game gear, and 32X) lr-gambatte consistent 60.0-60.2 FPS @ 60.098801hz (SGB2 framerate) lr-mgba consistent 59.8-60.4 FPS @ 60.002220hz (Gamecube framerate) 
Runahead Tested ~60FPS Stable:
  • Game Gear
  • Game Boy
  • Game Boy Color
  • Game Boy Advance
  • Master System
  • Megadrive
  • NES
  • PC Engine
  • PCE-CD
  • Sega 32X
  • Sega CD
  • SNES
Runahead Tested < 50FPS Unstable:
  • FB Neo
  • FB Alpha
  • Mame
  • N64
  • PlayStation
  • PSP
Runahead Untested:
  • Atari 800
  • Atari 2600
  • Atari 5200
  • Atari 7800
  • Atari Lynx
  • Coleco
  • Intellivision
  • MSX
What Does This NOT Have?
This doesn't have any ROMs (other than freeware test suites), BIOS files, music, screenshots, metadata, or videos concerning copywritten games. Other than the configurations and overlays, it has nothing that can't be downloaded through the repository or freeware.
Where Can I Get It?
You can download a premade image from Drive:
NOTE: Please expand your file system via Raspi-Config after your first boot, and reboot!
CRTPi-RCA NTSC v3.0F: For Raspberry Pi3B Composite-Out @ 60hz
MD5: 438d69a38b6085d2c5be30fbd43e2b43 
CRTPi-RCA PAL v3.0F: For Raspberry Pi3B Composite-Out @ 50hz
MD5: 5f76241b4ba75e95b597642cea8eb242 
How do I install the Arcade Configuration Pack?
These are the resolution-correct preset arcade configs for MAME/FBA including vertical games. There is roughly 38K files in there, spread out across several systems (arcade, fba, mame-libretro, and neogeo). Having these pre-installed would not allow either image to fit on the SD card used, and may not be needed for everyone. It's a fairly simple process that won't take more than a few minutes of your time.
  • Drop to shell or connect via SSH, and navigate to root (cd /)
  • Download the CRTPi-RCA_ArcadePack.zip with the command:
    sudo wget https://github.com/crtpi/CRTPi-Project/raw/masteCRTPi-RCA_ArcadePack.zip
  • Unzip and overwrite files with the command:
    sudo unzip -o -q CRTPi-RCA_ArcadePack.zip
  • Remove the zip with the command
    sudo rm CRTPi-RCA_ArcadePack.zip
  • Restore read/write access to the files you have overwritten with the command:
    sudo chmod a+rw -R /opt/retropie/configs/
How can I take full advantage of the 480i/240p Switching?
To force 480i for a system or game, you can create a '480i.txt' file inside the configuration folder of the system with a list of the file names (case insensitive, extension optional but recommended) you want to force.
If you wish to force 480i for a whole system, you can write "all" inside the '480i.txt' file.
Alternatively you can create a "240p.txt" file to force 480i to all games except for the ones inside the list.
You can read more about the script functionality here.
Example:
/opt/retropie/configs/psx/480i.txt containing "Bloody Roar 2.PBP" to force 480i for the file "Bloody Roar 2.PBP" /opt/retropie/configs/psx/480i.txt containing "all" to force 480i for all the PlayStation games. /opt/retropie/configs/ports/kodi/480i.txt containing "all" to force 480i on Kodi. 
I have X Issue! Help?
I only have like 500mb of free space on my XXgb SD card!
You need to expand your file system via Raspi-Config. Follow these steps.
I want to switch back to lr-mupen64plus!
  • When launching an n64 game, mash buttons on the controller until the runcommand window comes up.
  • Select on "1 Set default emulator for n64" and choose "lr-mupen64plus"
  • Then "Q Exit (without launching)"
  • Launch the game again -- it will launch in the chosen emulator at the proper resolution
What A/V cable should I use for 3.5mm Composite?
I recommend the Zune A/V cable or XBOX 360E cable, you can find them on eBay and Amazon.
Samba Share won't work after I set up Wi-Fi!
Samba share service starts on boot, pending that a network is available. Configure your Wi-Fi then reboot first, and if that doesn't fix it then go into Retropie Setup > Configuration/Tools > Samba > Install Samba. Once it's complete, reboot and it should be golden.
USB-Romservice and/or Retropie-Mount don't work!
Follow this guide, but follow these steps before plugging in your thumb drive:
  • Go to Retropie-Setup
  • Update retropie install script
  • Go to Manage Packages -> Optional Packages
  • Scroll all the way down to usbromservice
  • Uninstall usbromservice
  • Install it again from Binary
  • Once finished, choose Configuration, then Enable USB Romservice
  • Reboot, and wait for it to fully boot in to ES
  • Plug in USB stick (has to be FAT32) and WAIT A LONG TIME (if your stick has a light, wait for it to stop flashing)
submitted by ErantyInt to u/ErantyInt [link] [comments]

CRTPi-480p v3.0X - An unholy bastard for Pi3 && Pi4!

CRTPi Project Presents:

CRTPi-480p v3.0X && v3.4X

A CRTPi image for running 480p via HDMI or VGA!
Other Releases:
Changelog: v3.0X && v3.4X for HDMI&VGA666 05/25/2020
Required Hardware:
What is this?
I finally did something for people who don't want to use expensive video hats and SDTV's! This image boots in your choise of CEA 480p or various 640x480p VGA modes. Using Snap-Shader and Simple-Bilinear-Scanlines, I've given a way to upscale 240p content to 480p, while still looking and performing console-fresh! The perfect image for EDTV, HiScan sets, mulit-scan monitors, GSB arcade boards -- this even works on HDTV's that don't upscale 480p content!!
That said, I hate it and it should burn in hell... Enjoy!
What Does That Look Like?
Here's a bunch of pics I took, some better than others!
What is Different?
See the current changelog and the v3.0 thread for a complete list.
What is Run-Ahead?
The Run Ahead feature calculates the frames as fast as possible in the background to "rollback" the action as close as possible to the input command requested.
I've enabled run-ahead on most of the 8 & 16-bit consoles and handhelds. A single frame (and using the second instance) is saved here, which dramatically improves input lag without affecting performance on a Pi3B+. More frames would require more hardware power, and may be achievable via overclocking.
lr-snes9x2010 consistent 60.0-60.2 FPS @ 60.098801hz lr-fceumm consistent 60.0-60.2 FPS @ 60.098801hz lr-beetle-pce-fast consistent 60.1-60.2 @ 60.000000hz lr-genesis-gx-plus consistent 59.9-60.2 FPS @ 59.922741hz (both genesis and sega cd) lr-picodrive consistent 59.9-60.2 FPS @ 59.922741hz (master system, game gear, and 32X) lr-gambatte consistent 60.0-60.2 FPS @ 60.098801hz (SGB2 framerate) lr-mgba consistent 59.8-60.4 FPS @ 60.002220hz (Gamecube framerate) 
To disable runahead for a game (or emulator):
Quick Menu > Latency > Run-Ahead to Reduce Latency > OFF 
What is Snap-Shader?
It's a Retroarch GSL shader that ensures games on CRT will look as good as on original hardware. It Makes games crisp vertically, and not shimmer horizontally. It correctly aligns the games for you regardless of console. Virtually eliminates the need for separate configurations per core (console).
https://github.com/ektgit/snap-shader-240p
Snap Shader (especially the snap-basic) is super useful on consoles where you may have a mix of horizontal resolutions within the core that you don't necessarily want to set individual game configs for, which for this build, is basically everything but Megadrive, GBA, GBC, Doom, and Quake.
What Does This NOT Have?
This doesn't have any ROMs (other than freeware test suites), BIOS files, music, screenshots, metadata, or videos concerning copy-written games. Other than the configurations and overlays, it has nothing that can't be downloaded through the repository or freeware.
Where Can I Get It?
You can download a premade image from Google Drive:
NOTE: Please expand your file system via Raspi-Config after your first boot, and reboot!
CRTPi-480p v3.0X: For Pi3B/B+ with HDMI or VGA666 LIVE @ NOW
MD5: 9ad75efe8516ab0e7f2df3b084e93dcd 
CRTPi-480p v3.4X: For Pi4B with HDMI or VGA666 LIVE @ 16:40PST
MD5: 7272a6ac24fa5004a1f6c961264b2d7d 
How do I set this up?
Edit the /boot/config.txt before first boot.
If you're using an HDMI to converter, select one HDMI block of your preference by uncommenting it and commenting out the rest. The default is HDMI CEA 480p.
If you're using a VGA666, uncomment this block, and then one VGA666 block of your choice.
\## VGA666 - DPI Settings \#dtoverlay=vga666 \#enable_dpi_lcd=1 \#display_default_lcd=1 
Default Retroarch Keyboard Hotkeys
*SPACE: Enable Hotkey* F1 Menu F2 FF Toggle F3 Reset F4 Cheat Toggle F5 Save State F6 Load State F7 Change State - F8 Change State + F9 Screenshot F10 Mute ENTER: Exit 
The GBA/GBC/GB overlay is cropped on my !!!
Go into the Retroarch menu in game and navigate to "Quick Menu > On-Screen Overlay". Click "Overlay Preset" and choose the VGA version instead of the 480p version -- "crt_gbaplayer..." is for GBA and "crt_supergameboy..." is for GB/GBC.
I have X Issue! Help?
Chrono Cross (or Bloody Roar II) or some other PSX game has weird thick-as-fuck scanlines!
Disable the scanline shader, leaving Snap-Basic in place. Chances are you're playing a 480i game that wasn't intended to have scanlines, and the shader can't clamp to the right frames.
I only have like 500mb of free space on my XXgb SD card!
You need to expand your file system via Raspi-Config. Follow these steps.
GBA, PSX, Neo-Geo, Sega-CD, PCE-CD, etc. games don't work!
I haven't included any bios's that didn't come with the retropie stock image, so you'll need to install the appropriate files in the BIOS folder. For Neo-Geo, I highly recommend the UniBios (renamed to neogeo.zip).
Samba Share won't work after I set up Wi-Fi!
Samba share service starts on boot, pending that a network is available. Configure your Wi-Fi then reboot first, and if that doesn't fix it then go into Retropie Setup > Configuration/Tools > Samba > Install Samba. Once it's complete, reboot and it should be golden.
USB-Romservice and/or Retropie-Mount don't work!
Follow this guide, but follow these steps before plugging in your thumb drive:
  • Go to Retropie-Setup
  • Update retropie install script
  • Go to Manage Packages -> Optional Packages
  • Scroll all the way down to usbromservice
  • Uninstall usbromservice
  • Install it again from Binary
  • Once finished, choose Configuration, then Enable USB Romservice
  • Reboot, and wait for it to fully boot in to ES
  • Plug in USB stick (has to be FAT32) and WAIT A LONG TIME (if your stick has a light, wait for it to stop flashing)
submitted by ErantyInt to u/ErantyInt [link] [comments]

CRTPi-VGA v3.0V - Find that VGA Monitor Yet?!

CRTPi Project Presents:

CRTPi-VGA v3.0V

A CRTPi image for running 240p on VGA CRT monitors
Other Releases:
Changelog: v3.0V for VGA-666 05/12/2020
Changelog: v2.5V for VGA-666 05/05/2020
Changelog: v2.0VX for VGA-666 03/21/2020
Required Hardware:
What is this?
Since I've been relegated to working from home for the next forever, I needed something to pass the time. Lots of users have asked for, and worked with me to create a solution for what we'll call the "Poor Man's BVM." A $5 Gert VGA666 adapter, cheap/free 31khz VGA Monitor, and a Pi packed with roms. What could be a better way to pass the quarantine?
For a long time, there were several stumbling blocks:
I finally stumbled upon some old threads with people listing out some 640x480 hdmi_timings, and that cracked the whole case wide open. I finally had the missing piece that could be slotted into my existing images. The end result is Emulationstation and other non-libretro emulators launching in 640x480p @ 65hz (great for PSP, DOSbox, ScummVM, and Kodi!) and all Retroarch emulators launching in 2048x240p or 1920x240p @ 120hz.
I opted to steer away from Black Frame Insertion and instead change the VSync Swap interval to 2 (running the framerate at half of 120hz). This solves the intermittent flicker and also the reduced gamma from BFI. Overall, it's a much more pleasing experience IMO. You can always change VSync Interval back to 1, and enable BFI in Retroarch if you the other way is better.
What Does That Look Like?
Here's a bunch of pics I took, some better than others!
What is Different?
See the current changelog and the v3.0 thread for a complete list.
What is Run-Ahead?
The Run Ahead feature calculates the frames as fast as possible in the background to "rollback" the action as close as possible to the input command requested.
I've enabled run-ahead on most of the 8 & 16-bit consoles and handhelds. A single frame (and using the second instance) is saved here, which dramatically improves input lag without affecting performance on a Pi3B+. More frames would require more hardware power, and may be achievable via overclocking.
lr-snes9x2010 consistent 60.0-60.2 FPS @ 60.098801hz lr-fceumm consistent 60.0-60.2 FPS @ 60.098801hz lr-beetle-pce-fast consistent 60.1-60.2 @ 60.000000hz lr-genesis-gx-plus consistent 59.9-60.2 FPS @ 59.922741hz (both genesis and sega cd) lr-picodrive consistent 59.9-60.2 FPS @ 59.922741hz (master system, game gear, and 32X) lr-gambatte consistent 60.0-60.2 FPS @ 60.098801hz (SGB2 framerate) lr-mgba consistent 59.8-60.4 FPS @ 60.002220hz (Gamecube framerate) 
To disable runahead for a game (or emulator):
Quick Menu > Latency > Run-Ahead to Reduce Latency > OFF 
What is Snap-Shader?
It's a Retroarch GSL shader that ensures games on CRT will look as good as on original hardware. It Makes games crisp vertically, and not shimmer horizontally. It correctly aligns the games for you regardless of console. Virtually eliminates the need for separate configurations per core (console).
https://github.com/ektgit/snap-shader-240p
Snap Shader (especially the snap-basic) is super useful on consoles where you may have a mix of horizontal resolutions within the core that you don't necessarily want to set individual game configs for. This is especially useful in PSX, FDS, PCE/PCE-CD, 32X, and MAME.
So far, the image is only set up for Snap-Basic (Pass: 1, Filter: Nearest, Scale: Don't Care) on lr-PCSX-ReARMed. If you care to, I would definitely try it out on other emulators. Here's the enable process:
  • Quick Menu > Shaders
  • Video Shaders > On
  • Shader Passes > 1
  • Shader #0 > snap-basic.glsl
  • Shader #0 Filter > Nearest
  • Shader #0 Scale > Don't Care
  • Save > Save Core Preset
What Does This NOT Have?
This doesn't have any ROMs (other than freeware test suites), BIOS files, music, screenshots, metadata, or videos concerning copy-written games. Other than the configurations and overlays, it has nothing that can't be downloaded through the repository or freeware.
Where Can I Get It?
You can download a premade image from Google Drive:
NOTE: Please expand your file system via Raspi-Config after your first boot, and reboot!
CRTPi-VGA v3.0V: For Pi3B/B+ with VGA666
MD5: 828cf4e5b67f67e8b5bd1e4fb8477332 
Default Retroarch Keyboard Hotkeys
*SPACE: Enable Hotkey* F1 Menu F2 FF Toggle F3 Reset F4 Cheat Toggle F5 Save State F6 Load State F7 Change State - F8 Change State + F9 Screenshot F10 Mute ENTER: Exit 
I have X Issue! Help?
I only have like 500mb of free space on my XXgb SD card!
You need to expand your file system via Raspi-Config. Follow these steps.
GBA, PSX, Neo-Geo, Sega-CD, PCE-CD, etc. games don't work!
I haven't included any bios's that didn't come with the retropie stock image, so you'll need to install the appropriate files in the BIOS folder. For Neo-Geo, I highly recommend the UniBios (renamed to neogeo.zip).
Samba Share won't work after I set up Wi-Fi!
Samba share service starts on boot, pending that a network is available. Configure your Wi-Fi then reboot first, and if that doesn't fix it then go into Retropie Setup > Configuration/Tools > Samba > Install Samba. Once it's complete, reboot and it should be golden.
USB-Romservice and/or Retropie-Mount don't work!
Follow this guide, but follow these steps before plugging in your thumb drive:
  • Go to Retropie-Setup
  • Update retropie install script
  • Go to Manage Packages -> Optional Packages
  • Scroll all the way down to usbromservice
  • Uninstall usbromservice
  • Install it again from Binary
  • Once finished, choose Configuration, then Enable USB Romservice
  • Reboot, and wait for it to fully boot in to ES
  • Plug in USB stick (has to be FAT32) and WAIT A LONG TIME (if your stick has a light, wait for it to stop flashing)
Timings for Boot and Runcommand
640 x 480p @ 65hz Timings: Emulationstation, DOSBox, ScummVM, etc.
640 1 56 56 80 480 0 1 3 25 0 0 0 65 0 36000000 1 #640x480 VGA666 
1280 x 720p @ 60hz Timings: Kodi
1280 1 80 72 216 720 1 5 3 22 0 0 0 60 0 74239049 1 #1280x720p 
Integer Scale Super-Resolution 240p @ 120hz Timings: All Retroarch Emulators
2048 1 180 202 300 240 1 3 5 14 0 0 0 120 0 85909090 1 #256x240/224p 1920 1 167 247 265 240 1 3 7 12 0 0 0 120 0 81720000‬ 1 #320x240/224p 1600 1 95 157 182 240 1 4 3 15 0 0 0 120 0 64000000‬ 1 #320x240/224p Alternate 
Integer Scale Super-Resolution 480p @ 60hz Timings: Dreamcast and PSP Retroarch Emulators
2048 1 180 202 300 480 1 6 10 28 0 0 0 60 0 85909090 1 #320/256x480/448p 
submitted by ErantyInt to u/ErantyInt [link] [comments]

[Table] Asteroid Day AMA – We’re engineers and scientists working on a mission that could, one day, help save humankind from asteroid extinction. Ask us anything!

Source
There are several people answering: Paolo Martino is PM, Marco Micheli is MM, Heli Greus is HG, Detlef Koschny is DVK, and Aidan Cowley is AC.
Questions Answers
Can we really detect any asteroids in space with accuracy and do we have any real means of destroying it? Yes, we can detect new asteroids when they are still in space. Every night dozens of new asteroids are found, including a few that can come close to the Earth.
Regarding the second part of the question, the goal would be to deflect them more than destroy them, and it is technologically possible. The Hera/DART mission currently being developed by ESA and NASA will demonstrate exactly this capability.
MM
I always wanted to ask: what is worse for life on Earth - to be hit by a single coalesced asteroid chunk, or to be hit by a multiple smaller pieces of exploded asteroid, aka disrupted rubble pile scenario? DVK: This is difficult to answer. If the rubble is small (centimetres to meters) it is better to have lots of small ones – they’d create nice bright meteors. If the rubble pieces are tens of meters it doesn’t help.
Let’s say that hypothetically, an asteroid the size of Rhode Island is coming at us, it will be a direct hit - you’ve had the resources and funding you need, your plan is fully in place, everything you’ve wanted you got. The asteroid will hit in 10 years, what do you do? DVK: I had to look up how big Rhode Island is – a bit larger than the German Bundesland ‘Saarland’. Ok – this would correspond to an object about 60 km in diameter, right? That’s quite big – we would need a lot of rocket launches, this would be extremely difficult. I would pray. The good news is that we are quite convinced that we know all objects larger than just a few kilometers which come close to our planet. None of them is on a collision course, so we are safe.
the below is a reply to the above
Why are you quite convinced that you know all object of that size? And what is your approach in finding new celestial bodies? DVK: There was a scientific study done over a few years (published in Icarus 2018, search for Granvik) where they modelled how many objects there are out there. They compared this to the observations we have with the telescopic surveys. This gives us the expected numbers shown here on our infographic: https://www.esa.int/ESA_Multimedia/Images/2018/06/Asteroid_danger_explained
There are additional studies to estimate the ‘completeness’ – and we think that we know everything above roughly a few km in size.
To find new objects, we use survey telescopes that scan the night sky every night. The two major ones are Catalina and Pan-STARRS, funded by NASA. ESA is developing the so-called Flyeye telescope to add to this effort https://www.esa.int/ESA_Multimedia/Images/2017/02/Flyeye_telescope.
the below is a reply to the above
Thanks for the answer, that's really interesting! It's also funny that the fist Flyeye deployed is in Sicily, at less than 100km from me, I really had no idea DVK: Indeed, that's cool. Maybe you can go and visit it one day.
the below is a reply to the original answer
What about Interstellar objects however, like Oumuamua? DVK: The two that we have seen - 'Oumuamua and comet Borisov - were much smaller than the Saarland (or Rhode Island ;-) - not sure about Borisov, but 'Oumuamua was a few hundred meters in size. So while they could indeed come as a complete surprise, they are so rare that I wouldn't worry.
Would the public be informed if an impending asteroid event were to happen? And, how would the extinction play out? Bunch of people crushed to death, knocked off our orbit, dust clouds forever? DVK: We do not keep things secret – all our info is at the web page http://neo.ssa.esa.int. The ‘risky’ objects are in the ‘risk page’. We also put info on really close approaches there. It would also be very difficult to keep things ‘under cover’ – there are many high-quality amateur astronomers out there that would notice.
In 2029 asteroid Apophis will fly really close to Earth, even closer than geostationary satellites. Can we use some of those satellites to observe the asteroid? Is it possible to launch very cheap cube sats to flyby Apophis in 2029? DVK: Yes an Apophis mission during the flyby in 2029 would be really nice. We even had a special session on that topic at the last Planetary Defense Conference in 2019, and indeed CubeSats were mentioned. This would be a nice university project – get me a close-up of the asteroid with the Earth in the background!
the below is a reply to the above
So you’re saying it was discussed and shelved? In the conference we just presented ideas. To make them happen needs funding - in the case of ESA the support of our member countries. But having something presented at a conference is the first step. One of the results of the conference was a statement to space agencies to consider embarking on such a mission. See here: https://www.cosmos.esa.int/documents/336356/336472/PDC_2019_Summary_Report_FINAL_FINAL.pdf/341b9451-0ce8-f338-5d68-714a0aada29b?t=1569333739470
Go to the section 'resolutions'. This is now a statement that scientists can use to present to their funding agencies, demonstrating that it's not just their own idea.
Thanks for doing this AMA! Did we know the Chelyabinsk meteor in 2013 (the one which had some great videos on social media) was coming? Ig not, how comes? Also, as a little side one, have there been any fatalities from impact events in the past 20 years? Unfortunately, the Chelyabinsk object was not seen in advance, because it came from the direction of the Sun where ground-based telescopes cannot look.
No known fatalities from impacts have happened in the past 20 years, although the Chelyabinsk event did cause many injuries, fortunately mostly minor.
MM
the below is a reply to the above
How often do impacts from that direction happen, compared to impacts from visible trajectories? In terms of fraction of the sky, the area that cannot be easily scanned from the ground is roughly a circle with a radius of 40°-50° around the current position of the Sun, corresponding to ~15% of the total sky. However, there is a slight enhancement of objects coming from that direction, therefore the fraction of objects that may be missed when heading towards us is a bit higher.
However, this applies only when detecting an asteroid in its "final plunge" towards the Earth. Larger asteroids can be spotted many orbits earlier, when they are farther away and visible in the night side of the sky. Their orbits can then be determined and their possible impacts predicted even years or decades in advance.
MM
There must be a trade-off when targeting asteroids as they get closer to Earth, is there a rule of thumb at what the best time is to reach them, in terms of launch time versus time to reach the asteroid and then distance from Earth? DVK: Take e.g. a ‘kinetic impactor’ mission, like what DART and Hera are testing. Since we only change the velocity of the asteroid slightly, we need to hit the object early enough so that the object has time to move away from it’s collision course. Finding out when it is possible to launch requires simulations done by our mission analysis team. They take the strength of the launcher into account, also the available fuel for course corrections, and other things. Normally each asteroid has its own best scenario.
Do you also look at protecting the moon from asteroids? Would an impact of a large enough scale potentially have major impacts on the earth? DVK: There are programmes that monitor the Moon and look for flashes from impacting small asteroids (or meteoroids) - https://neliota.astro.noa.g or the Spanish MIDAS project. We use the data to improve our knowledge about these objects. These programmes just look at what is happening now.
For now we would not do anything if we predicted a lunar impact. I guess this will change once we have a lunar base in place.
Why aren't there an international organisation comprised of countries focused on the asteroid defence? Imagine like the organisation with multi-billion $ budget and program of action on funding new telescopes, asteroid exploration mission, plans for detection of potentially dangerous NEA, protocols on action after the detection - all international, with heads of states discussing these problems? DVK: There are international entities in place, mandated by the UN: The International Asteroid Warning Network (http://www.iawn.net) and the Space Mission Planning Advisory Group (http://www.smpag.net). These groups advise the United Nations. That is exactly where we come up with plans and protocols on action. But: They don’t have budget – that needs to come from elsewhere. I am expecting that if we have a real threat, we would get the budget. Right now, we don’t have a multi-billion budget.
the below is a reply to someone else's answer
There is no actual risk of any sizable asteroids hitting earth in the foreseeable future. Any preparation for it would just be a waste of money. DVK: Indeed, as mentioned earlier, we do not expect a large object to hit is in the near future. We are mainly worried about those in the size range of 20 m to 40 m, which happen on average every few tens of years to hundreds of years. And where we only know a percent of them or even less.
President Obama wanted to send a crewed spacecraft to an asteroid - in your opinion is this something that should still be done in the future, would there be any usefulness in having a human being walk/float on an asteroid's surface? DVK: It would definitely be cool. I would maybe even volunteer to go. Our current missions to asteroids are all robotic, the main reason is that it is much cheaper (but still expensive) to get the same science. But humans will expand further into space, I am sure. If we want to test human exploration activities, doing this at an asteroid would be easier than landing on a planet.
this is another reply Yes, but I am slightly biased by the fact that I work at the European astronaut centre ;) There exist many similarities to what we currently do for EVA (extra vehicular activities) operations on the International Space Station versus how we would 'float' around an asteroid. Slightly biased again, but using such a mission to test exploration technologies would definitely still have value. Thanks Obama! - AC
I've heard that some asteroids contains large amounts of iron. Is there a possibility that we might have "space mines" in the far away future, if our own supply if iron runs out? Yes, this is a topic in the field known as space mining, part of what we call Space Resources. In fact, learning how we can process material we might find on asteroids or other planetary bodies is increasingly important, as it opens up the opportunities for sustainable exploration and commercialization. Its a technology we need to master, and asteroids can be a great target for testing how we can create space mines :) - AC
By how much is DART expected to deflect Didymos? Do we have any indication of the largest size of an asteroid we could potentially deflect? PM: Didymos is a binary asteroid, consisting of a main asteroid Didymos A (~700m) and a smaller asteroid Didymos B (~150m) orbiting around A with a ~12 hours period. DART is expected to impact Didymos B and change its orbital period w.r.t. Didymos A of ~1%. (8 mins)
The size of Didymos B is the most representative of a potential threat to Earth (the highest combination of probability and consequence of impacts), meaning smaller asteroids hit the Earth more often but have less severe consequences, larger asteroids can have catastrophic consequences but their probability of hitting the earth is very very low.
the below is a reply to the above
Why is there less probability of larger asteroids hitting earth? DVK: There are less large objects out there. The smaller they are, the more there are.
the below is a reply to the original answer
Is there any chance that your experiment will backfire and send the asteroid towards earth? PM: Not at all, or we would not do that :) Actually Dimorphos (the Didymos "moon") will not even leave its orbit around Didymos. It will just slightly change its speed.
I'm sure you've been asked this many times but how realistic is the plot of Armageddon? How likely is it that our fate as a species will rely on (either) Bruce Willis / deep sea oil drillers? Taking into consideration that Bruce Willis is now 65 and by the time HERA is launched he will be 69, I do not think that we can rely on him this time (although I liked the movie).
HERA will investigate what method we could use to deflect asteroid and maybe the results will show that we indeed need to call the deep sea oil drillers.
HG
the below is a reply to the above
So then would it be easier to train oil drillers to become astronauts, or to train astronauts to be oil drillers? I do not know which one would be easier since I have no training/experience of deep see oil drilling nor becoming an astronaut, but as long as the ones that would go to asteroid have the sufficient skills and training (even Bruce Willis), I would be happy.
HG
If budget was no object, which asteroid would you most like to send a mission to? Nice question! For me, I'd be looking at an asteroid we know something about, since I would be interested in using it for testing how we could extract resources from it. So for me, I would choose Itokawa (https://en.wikipedia.org/wiki/25143_Itokawa), which was visited by Hayabusa spacecraft. So we already have some solid prospecting carried out for this 'roid! - AC
this is another reply Not sure if it counts as an asteroid, but Detlef and myself would probably choose ʻOumuamua, the first discovered interstellar object.
MM
the below is a reply to the above
Do we even have the capability to catch up to something like that screaming through our solar system? That thing has to have a heck of a velocity to just barrel almost straight through like that. DVK: Correct, that would be a real challenge. We are preparing for a mission called 'Comet Interceptor' that is meant to fly to an interstellar object or at least a fresh comet - but it will not catch up with it, it will only perform a short flyby.
https://www.esa.int/Science_Exploration/Space_Science/ESA_s_new_mission_to_intercept_a_comet
After proving to be able to land on one, could an asteroid serve as a viable means to transport goods and or humans throughout the solar system when the orbit of said asteroid proves beneficial. While it is probably quite problematic to land the payload, it could save fuel or am I mistaken? Neat idea! Wonder if anyone has done the maths on the amount of fuel you would need/save vs certain targets. - AC
PM: To further complement, the saving is quite marginal indeed because in order to land (softly) on the asteroid you actually need to get into the very same orbit of that asteroid . At that point your orbit remains the same whether you are on the asteroid or not..
can the current anti-ballistic missiles systems intercept a terminal phase earth strike asteroid? or it is better to know beforehand and launch an impacting vehicle into space? DVK: While I do see presentations on nuclear explosions to deflect asteroids at our professional meetings, I have not seen anybody yet studying how we could use existing missile systems. So it's hard to judge whether existing missiles would do the job. But in general, it is better to know as early as possible about a possible impact and deflect it as early as possible. This will minimize the needed effort.
How much are we prepared against asteroid impacts at this moment? DVK: 42… :-) Seriously – I am not sure how to quantify ‘preparedness’. We have international working groups in place, mentioned earlier (search for IAWN, SMPAG). We have a Planetary Defence Office at ESA, a Planetary Defense Office at NASA (who spots the difference?), search the sky for asteroids, build space missions… Still we could be doing more. More telescopes to find the object, a space-based telescope to discover those that come from the direction of the Sun. Different test missions would be useful, … So there is always more we could do.
Have you got any data on the NEO coverage? Is there estimations on the percentage of NEOs we have detected and are tracking? How can we improve the coverage? How many times have asteroids been able to enter earths atmosphere without being detected beforehand? Here’s our recently updated infographics with the fraction of undiscovered NEOs for each size range: https://www.esa.int/ESA_Multimedia/Images/2018/06/Asteroid_danger_explained
As expected, we are now nearly complete for the large ones, while many of the smaller ones are still unknown.
In order to improve coverage, we need both to continue the current approach, centered on ground-based telescopes, and probably also launch dedicated telescopes to space, to look at the fraction of the sky that cannot be easily observed from the ground (e.g., towards the Sun).
Regarding the last part of your question, small asteroids enter the Earth atmosphere very often (the infographics above gives you some numbers), while larger ones are much rarer.
In the recent past, the largest one to enter our atmosphere was about 20 meters in diameter, and it caused the Chelyabinsk event in 2013. It could not be detected in advance because it came from the direction of the Sun.
We have however detected a few small ones before impact. The first happened in 2008, when a ~4-meter asteroid was found to be on a collision course less than a day before impact, it was predicted to fall in Northern Sudan, and then actually observed falling precisely where (and when) expected.
MM
this is another reply >After
DVK: And to add what MM said - Check out http://neo.ssa.esa.int. There is a ‘discovery statistics’ section which provides some of the info you asked about. NASA is providing similar information here https://cneos.jpl.nasa.gov/stats/. To see the sky which is currently covered by the survey telescopes, you need to service of the Minor Planet Center which we all work together with: http://www.minorplanetcenter.org, ‘observers’, ‘sky coverage’. That is a tool we use to plan where we look with our telescopes, so it is a more technical page.
Are there any automatic systems for checking large numbers of asteroids orbits, to see if the asteroid's orbit is coming dangerously close to Earth, or is it done by people individually for every asteroid? I ask it because LSST Rubin is coming online soon and you know it will discover a lot of new asteroids. Yes, such systems exist, and monitor all known and newly discovered asteroids in order to predict possible future impacts.
The end result of the process is what we call "risk list": http://neo.ssa.esa.int/risk-page
It is automatically updated every day once new observational data is processed.
MM
What are your favourite sci-fi series? DVK: My favorites are ‘The Expanse’, I also liked watching ‘Salvation’. For the first one I even got my family to give me a new subscription to a known internet streaming service so that I can see the latest episodes. I also loved ‘The Jetsons’ and ‘The Flintstones’ as a kid. Not sure the last one counts as sci-fi though. My long-time favorite was ‘Dark Star’.
this is another reply Big fan of The Expanse at the moment. Nice, hard sci-fi that has a good impression of being grounded in reality - AC
this is another reply When I was a kid I liked The Jetsons, when growing up Star Trek, Star wars and I also used to watch with my sister the 'V'.
HG
When determining the potential threat of a NEA, is the mass of an object a bigger factor or size? I'm asking because I'm curious if a small but massive object (say, with the density of Psyche) could survive atmospheric entry better than a comparatively larger but less massive object. The mass is indeed what really matters, since it’s directly related with the impact energy.
And as you said composition also matters, a metal object would survive atmospheric entry better, not just because it’s heavier, but also because of its internal strength.
MM
What are your thoughts on asteroid mining as portrayed in sci-fi movies? Is it feasible? If so would governments or private space programs be the first to do so?What type of minerals can be found on asteroids that would merit the costs of extraction? Certainly there is valuable stuff you can find on asteroids. For example, the likely easiest material you can harvest from an asteroid would be volatiles such as H2O. Then you have industrial metals, things like Iron, Nickel, and Platinum group metals. Going further, you can break apart many of the oxide minerals you would find to get oxygen (getting you closer to producing rocket fuel in-situ!). Its feasible, but still needs alot of testing both here on Earth and eventually needs to be tested on a target. It may be that governments, via agencies like ESA or NASA, may do it first, to prove the principles somewhat, but I know many commercial entities are also aggresively working towards space mining. To show you that its definitely possible, I'd like to plug the work of colleagues who have processed lunar regolith (which is similar to what you may find on asteroids) to extract both oxygen and metals. Check it out here: http://www.esa.int/ESA_Multimedia/Images/2019/10/Oxygen_and_metal_from_lunar_regolith
AC
Will 2020's climax be a really big rock? DVK: Let's hope not...
Considering NASA, ESA, IAU etc. is working hard to track Earth-grazing asteroids, how come the Chelyabinsk object that airburst over Russia in 2013 came as a total surprise? The Chelyabinsk object came from the direction of the Sun, where unfortunately ground-based telescopes cannot look at. Therefore, it would not have been possible to discover it in advance with current telescopes. Dedicated space telescopes are needed to detect objects coming from this direction in advance.
MM
the below is a reply to the above
Is this to say that it was within specific solid angles for the entire time that we could have observed it given its size and speed? Yes, precisely that. We got unlucky in this case.
MM
Have any of you read Lucifer's Hammer by Larry Niven? In your opinion, how realistic is his depiction of an asteroid strike on Earth? DVK: I have – but really long ago, so I don’t remember the details. But I do remember that I really liked the book, and I remember I always wanted to have a Hot Fudge Sundae when reading it.
I was thinking about the asteroid threat as a teen and came up with this ideas (Hint: they are not equally serious, the level of craziness goes up real quick). Could you please comment on their feasibility? 1. Attaching a rocket engine to an asteroid to make it gradually change trajectory, do that long in advance and it will miss Earth by thousands of km 2. Transporting acid onto asteroid (which are mainly metal), attaching a dome-shaped reaction chamber to it, using heat and pressure to then carry out the chemical reaction to disintegrate asteroids 3. This one is even more terrible than a previous one and totally Dan Brown inspired — transporting antimatter on asteroid, impacting and causing annihilation. Thank you for this AMA and your time! DVK: Well the first one is not so crazy, I have seen it presented... the difficulty is that all asteroids are rotating in one way or another. So if you continuously fire the engine it would not really help. You'd need to switch the engine on and off. Very complex. And landing on an asteroid is challenging too. Just using the 'kinetic impactor' which we will test with DART/Hera (described elsewhere in this chat) is simpler. Another seriously proposed concept is to put a spacecraft next to an asteroid and use an ion engine (like we have on our Mercury mission BepiColombo) to 'push' the asteroid away.
As for 2 and 3 I think I will not live to see that happening ;-)
What is the process to determine the orbit of a newly discovered asteroid? The process is mathematically quite complex, but here's a short summary.
Everything starts with observations, in particular with measurements of the position of an asteroid in the sky, what we call "astrometry". Discovery telescopes extract this information from their discovery images, and make it available to everybody.
These datapoints are then used to calculate possible trajectories ("orbits") that pass through them. At first, with very few points, many orbits will be possible.
Using these orbits we can extrapolate where the asteroid will be located during the following nights, use a telescope to observe that part of the sky, and locate the object again.
From these new observations we can extract new "astrometry", add it to the orbit determination, and see that now only some of the possible orbits will be compatible with the new data. As a result, we now know the trajectory better than before, because a few of the possible orbits are not confirmed by the new data.
The cycle can then continue, with new predictions, new observations, and a more accurate determination of the object's orbit, until it can be determined with an extremely high level of accuracy.
MM
What are some asteroids that are on your "watchlist"? We have exactly that list on our web portal: http://neo.ssa.esa.int/risk-page
It's called "risk list", and it includes all known asteroids for which we cannot exclude a possible impact over the next century. It is updated every day to include newly discovered asteroids, and remove those that have been excluded as possible impactors thanks to new observations.
MM
the below is a reply to the above
That's quite a list!! Do you guys ever feel stressed or afraid when you have to add another dangerous candidate (and by dangerous I mean those above 200m) is added to this Risk List? Yes, when new dangerous ones are added it's important that we immediately do our best to gather more data on them, observing them with telescopes in order to get the information we need to improve our knowledge of their orbit.
And then the satisfaction of getting the data needed to remove one from the list is even greater!
MM
What inspired you to go into this field of study? I was fascinated by astronomy in general since I was a kid, but the actual "trigger" that sparked my interest in NEOs was a wonderful summer course on asteroids organized by a local amateur astronomers association. I immediately decided that I would do my best to turn this passion into my job, and I'm so happy to have been able to make that dream come true.
MM
this is another reply DVK: I started observing meteors when I was 14, just by going outside and looking at the night sky. Since then, small bodies in the solar system were always my passion.
As a layperson, I still think using nuclear weapons against asteroids is the coolest method despite better methods generally being available. Do you still consider the nuclear option the cool option, or has your expertise in the field combined with the real-life impracticalities made it into a laughable/silly/cliche option? DVK: We indeed still study the nuclear option. There are legal aspects though, the ‘outer space treaty’ forbids nuclear explosions in space. But for a large object or one we discover very late it could be useful. That’s why we have to focus on discovering all the objects out there as early as possible – then we have time enough to use more conventional deflection methods, like the kinetic impactor (the DART/Hera scenario).
It seems like doing this well would require international cooperation, particularly with Russia. Have you ever reached out to Russia in your work? Do you have a counterpart organization there that has a similar mission? DVK: Indeed international cooperation is important - asteroids don't know about our borders! We work with a Russian team to perform follow-up observations of recently discovered NEOs. Russia is also involved in the UN-endorsed working groups that we have, IAWN and SMPAG (explained in another answer).
how much can experts tell from a video of a fireball or meteor? Can you work out what it's made of and where it came from? https://www.reddit.com/space/comments/hdf3xe/footage_of_a_meteor_at_barrow_island_australia/?utm_source=share&utm_medium=web2x If multiple videos or pictures, taken from different locations, are available, then it's possible to reconstruct the trajectory, and extrapolate where the object came from.
Regarding the composition, it's a bit more difficult if nothing survives to the ground, but some information can be obtained indirectly from the fireball's color, or its fragmentation behavior. If a spectral analysis of the light can be made, it's then possible to infer the chemical composition in much greater detail.
MM
I've always wanted to know what the best meteorite buying site is and what their average price is?? DVK: Serious dealers will be registered with the 'International Meteorite Collectors Association (IMCA)' - https://www.imca.cc/. They should provide a 'certificate of authenticity' where it says that they are member there. If you are in doubt, you can contact the association and check. Normally there are rough prices for different meteorite types per gram. Rare meteorites will of course be much more expensive than more common ones. Check the IMCA web page to find a dealer close to you.
Just read through Aidans link to the basaltic rock being used as a printing material for lunar habitation. There is a company called Roxul that does stone woven insulation that may be able to shed some light on the research they have done to minimize their similarity to asbestos as potentially carcinogenic materials deemed safe for use in commercial and residential applications. As the interior surfaces will essentially be 3D printed lunar regolith what are the current plans to coat or dampen the affinity for the structure to essentially be death traps for respiratory illness? At least initially, many of these 3d printed regolith structures would not be facing into pressurised sections, but would rather be elements placed outside and around our pressure vessels. Such structures would be things like radiation shields, landing pads or roadways, etc. In the future, if we move towards forming hermetically sealed structures, then your point is a good one. Looking into terrestrial solutions to this problem would be a great start! - AC
What kind of career path does it take to work in the asteroid hunting field? It's probably different for each of us, but here's a short summary of my own path.
I became interested in asteroids, and near-Earth objects in particular, thanks to a wonderful summer course organized by a local amateur astronomers association. Amateur astronomers play a great role in introducing people, and young kids in particular, to these topics.
Then I took physics as my undergrad degree (in Italy), followed by a Ph.D. in astronomy in the US (Hawaii in particular, a great place for astronomers thanks to the exceptional telescopes hosted there).
After finishing the Ph.D. I started my current job at ESA's NEO Coordination Centre, which allowed me to realize my dream of working in this field.
MM
this is another reply DVK: Almost all of us have a Master's degree either in aerospace engineering, mathematics, physics/astronomy/planetary science, or computer science. Some of us - as MM - have a Ph.D. too. But that's not really a requirement. This is true for our team at ESA, but also for other teams in other countries.
What is the likelihood of an asteroid hitting the Earth In the next 200 years? It depends on the size, large ones are rare, while small ones are much more common. You can check this infographics to get the numbers for each size class: https://www.esa.int/ESA_Multimedia/Images/2018/06/Asteroid_danger_explained
MM
Have you played the Earth Defence Force games and if you have, which one is your favourite? No I have not played the Earth Defence Force games, but I just looked it up and I think I would liked it. Which one would you recommend?
HG
How close is too close to earth? Space is a SUPER vast void so is 1,000,000 miles close, 10,000,000? And if an asteroid is big enough can it throw earth off its orbit? DVK: Too close for my taste is when we compute an impact probability > 0 for the object. That means the flyby distance is zero :-) Those are the objects on our risk page http://neo.ssa.esa.int/risk-page.
If an object can alter the orbit of another one, we would call it planet. So unless we have a rogue planet coming from another solar system (verrry unlikely) we are safe from that.
How can I join you when I'm older? DVK: Somebody was asking about our career paths... Study aerospace engineering or math or physics or computer science, get a Masters. Possibly a Ph.D. Then apply for my position when I retire. Check here for how to apply at ESA: https://www.esa.int/About_Us/Careers_at_ESA/Frequently_asked_questions2#HR1
How much is too much? DVK: 42 again
Are you aware of any asteroids that are theoretically within our reach, or will be within our reach at some point, that are carrying a large quantity of shungite? If you're not aware, shungite is like a 2 billion year old like, rock stone that protects against frequencies and unwanted frequencies that may be traveling in the air. I bought a whole bunch of the stuff. Put them around the la casa. Little pyramids, stuff like that. DVK: If I remember my geology properly, Shungite forms in water sedimental deposits. This requires liquid water, i.e. a larger planet. So I don't think there is a high chance to see that on asteroids.
submitted by 500scnds to tabled [link] [comments]

CRTPi4-RCA v3.4FX - Composite TV-Out for your Pi4!

CRTPi Project Presents:

CRTPi4-RCA v3.4FX

A CRTPi image for running 240p via 3.5mm Composite on the Raspberry Pi4
Other Releases:
Changelog: v3.4FX for RCA (PAL Only) 5/18/2020
Changelog: v3.4FX for RCA (NTSC&&PAL) 5/17/2020
Changelog: v3.0F for RCA 5/11/2020
Changelog: v2.0F for RCA 4/1/2020
Changelog: v1.1FX 12/20/2019
Changelog: v1.0F Hotfix 10/31/2019
Changelog: v1.0F 10/29/2019
Changelog: v0.4 10/22/2019
Changelog: v0.3 10/2/2019
How does this even work!?
The amazing u/b0xspread has found a way to enforce modeswitching by watching the logs and processes, and continuing to enforce our desired mode long after the system wants to revert back. We're both expanding this scripting further to hopefully solve the same issues on the RGB and VGA forks -- but progress is slow due to the complex and varied nature of available resolution modes on those builds. But for now, let's just call this "black magic."
What Does That Look Like?
Here are some examples of games being played in beautiful 240p on CRT sets using the RCA Image!.
What is Different?
  • Retropie 4.6 (build 72132587 commit 05/07/20 Buster 10)
  • Retroarch 1.8.5
  • Full Apt-Upgrade for newest firmware and app dependancies (Recommended to repeat this function on your own Pi4)
  • 4GB (3872256 KB Uncompressed Image) (Compressed via WinRAR to 1043540KB)
  • SSH, Samba Share, and USB Rom Service enabled by default
  • Heavily modified Sakitoshi CRT-TVout script for switching between 480i and 240p
  • Further modified Sakitoshi script by u/b0xspread to allow video resolution switching on Pi4 Architecture
  • Optional overclock values in /boot/config.txt for Pi4 (disabled by default) [RECOMMENDED!]
  • NTSC @ 60hz 720/640x480 480i Resolution for Emulationstation & Kodi
  • PAL @ 50hz 720/640x576 576i Resolution for Emulationstation & Kodi
  • NTSC @ 60hz 640x480 Progressive (240 lines) for Retroarch
  • PAL @ 50hz 640x576 Progressive (288 lines) for Retroarch
  • Per-system custom refresh rates for Retroarch
  • Single-frame Run Ahead enabled for many 8-bit & 16-bit consoles and handhelds for Retroarch
  • Optional 480i mode for PSX and Arcade games
  • Preloaded with free 240p test suites for multiple consoles
  • Preloaded with additional stable (opt) Retroarch emulators
  • Preloaded with DOSBox and ScummVM
  • Preloaded with various 4:3 splashscreens from the RPiF download
  • Preloaded with 4:3 Ruckage's runcommand launching screens for supported systems
  • Custom 4:3 Arcade DOJ "Winners DO Use Drugs" splash screen.
  • Preloaded with MUNT Roland MT-32 MIDI emulation for DOSBox/ScummVM
  • Retroarch FCEUmm (NES) Emulator preconfigured for 4:3 horiz/vert overscan crop enabled w/ composite-direct-fbx pallete
  • Retroarch Picodrive (SMS/32X) Emulator preconfigured for 4:3 with 1X Sega Mastersystem & 1X Sega 32X resolution
  • Retroarch Gambatte (GB/GBC) emulator preset to Super Game Boy (Special 1 Pallete) mode with 2x integer scale SGB Overlay
  • Retroarch mGBA (GBA) emulator preset to Game Boy Player mode with 2x integer scale GBP Overlay
  • Other Retroarch handheld emulators preset for optimized wide display with overlay
  • Emulationstation preloaded with Ruckage's RetroPie menu icons
  • Emulationstation preloaded with Ruckage's snes-mini theme configured for 4:3
  • Custom ScummVM system artwork for snes-mini theme
  • Emulationstation systems ordered chronologically instead of alphabetically
  • Emulationstation preconfigured with best settings for analog A/V including best settings for video preview screensavers
What is Run-Ahead?
The Run Ahead feature calculates the frames as fast as possible in the background to "rollback" the action as close as possible to the input command requested.
I've enabled run-ahead on most of the 8 & 16-bit consoles and handhelds. A single frame (and using the second instance) is saved here, which dramatically improves input lag without affecting performance on a Pi3B+. More frames would require more hardware power, and may be achievable via overclocking.
lr-snes9x2010 consistent 60.0-60.2 FPS @ 60.098801hz lr-fceumm consistent 60.0-60.2 FPS @ 60.098801hz lr-beetle-pce-fast consistent 60.1-60.2 @ 60.000000hz lr-genesis-gx-plus consistent 59.9-60.2 FPS @ 59.922741hz (both genesis and sega cd) lr-picodrive consistent 59.9-60.2 FPS @ 59.922741hz (master system, game gear, and 32X) lr-gambatte consistent 60.0-60.2 FPS @ 60.098801hz (SGB2 framerate) lr-mgba consistent 59.8-60.4 FPS @ 60.002220hz (Gamecube framerate) 
Runahead Tested ~60FPS Stable:
  • Game Gear
  • Game Boy
  • Game Boy Color
  • Game Boy Advance
  • Master System
  • Megadrive
  • NES
  • PC Engine
  • PCE-CD
  • Sega 32X
  • Sega CD
  • SNES
Runahead Tested < 50FPS Unstable:
  • FB Neo
  • FB Alpha
  • Mame
  • N64
  • PlayStation
  • PSP
Runahead Untested:
  • Atari 800
  • Atari 2600
  • Atari 5200
  • Atari 7800
  • Atari Lynx
  • Coleco
  • Intellivision
  • MSX
What Does This NOT Have?
This doesn't have any ROMs (other than freeware test suites), BIOS files, music, screenshots, metadata, or videos concerning copywritten games. Other than the configurations and overlays, it has nothing that can't be downloaded through the repository or freeware.
Where Can I Get It?
You can download a premade image from Drive:
NOTE: Please expand your file system via Raspi-Config after your first boot, and reboot!
CRTPi4-RCA NTSC v3.4F: For Raspberry Pi4 Composite-Out @ 60hz
MD5: 7df8453c2e8029b06def7864351ec768 
CRTPi4-RCA PAL-D v3.4F: For Raspberry Pi4 Composite-Out @ 50hz
MD5: ab2bd6ab228bd6f58a22de15044fb46a 
How do I install the Arcade Configuration Pack?
These are the resolution-correct preset arcade configs for MAME/FBA including vertical games. There is roughly 38K files in there, spread out across several systems (arcade, fba, mame-libretro, and neogeo). Having these pre-installed would not allow either image to fit on the SD card used, and may not be needed for everyone. It's a fairly simple process that won't take more than a few minutes of your time.
  • Drop to shell or connect via SSH, and navigate to root (cd /)
  • Download the CRTPi-RCA_ArcadePack.zip with the command:
    sudo wget https://github.com/crtpi/CRTPi-Project/raw/masteCRTPi-RCA_ArcadePack.zip
  • Unzip and overwrite files with the command:
    sudo unzip -o -q CRTPi-RCA_ArcadePack.zip
  • Remove the zip with the command
    sudo rm CRTPi-RCA_ArcadePack.zip
  • Restore read/write access to the files you have overwritten with the command:
    sudo chmod a+rw -R /opt/retropie/configs/
How can I take full advantage of the 480i/240p Switching?
To force 480i for a system or game, you can create a '480i.txt' file inside the configuration folder of the system with a list of the file names (case insensitive, extension optional but recommended) you want to force.
If you wish to force 480i for a whole system, you can write "all" inside the '480i.txt' file.
Alternatively you can create a "240p.txt" file to force 480i to all games except for the ones inside the list.
You can read more about the script functionality here.
Example:
/opt/retropie/configs/psx/480i.txt containing "Bloody Roar 2.PBP" to force 480i for the file "Bloody Roar 2.PBP" /opt/retropie/configs/psx/480i.txt containing "all" to force 480i for all the PlayStation games. /opt/retropie/configs/ports/kodi/480i.txt containing "all" to force 480i on Kodi. 
I have X Issue! Help?
Why isn't there a Pi4 PAL version?
Try as I might, I have been unable to get a PAL signal out of the SDTV port on a Pi4. My BVM displays PAL-S and PAL-D fine, but neither will get anything but static. I don't even get a rolling B&W image, just horrible static. If you figure out a way, let me know!
I only have like 500mb of free space on my XXgb SD card!
You need to expand your file system via Raspi-Config. Follow these steps.
I want to switch back to lr-mupen64plus!
  • When launching an n64 game, mash buttons on the controller until the runcommand window comes up.
  • Select on "1 Set default emulator for n64" and choose "lr-mupen64plus"
  • Then "Q Exit (without launching)"
  • Launch the game again -- it will launch in the chosen emulator at the proper resolution
What A/V cable should I use for 3.5mm Composite?
I recommend the Zune A/V cable or XBOX 360E cable, you can find them on eBay and Amazon.
Samba Share won't work after I set up Wi-Fi!
Samba share service starts on boot, pending that a network is available. Configure your Wi-Fi then reboot first, and if that doesn't fix it then go into Retropie Setup > Configuration/Tools > Samba > Install Samba. Once it's complete, reboot and it should be golden.
USB-Romservice and/or Retropie-Mount don't work!
Follow this guide, but follow these steps before plugging in your thumb drive:
  • Go to Retropie-Setup
  • Update retropie install script
  • Go to Manage Packages -> Optional Packages
  • Scroll all the way down to usbromservice
  • Uninstall usbromservice
  • Install it again from Binary
  • Once finished, choose Configuration, then Enable USB Romservice
  • Reboot, and wait for it to fully boot in to ES
  • Plug in USB stick (has to be FAT32) and WAIT A LONG TIME (if your stick has a light, wait for it to stop flashing)
submitted by ErantyInt to u/ErantyInt [link] [comments]

CRTPi4-RCA v3.4FX - Composite TV-Out for your Pi4!

CRTPi Project Presents:

CRTPi4-RCA v3.4FX

A CRTPi image for running 240p via 3.5mm Composite on the Raspberry Pi4
Other Releases:
Changelog: v3.4FX for RCA (PAL Only) 5/18/2020
Changelog: v3.4FX for RCA (NTSC&&PAL) 5/17/2020
Changelog: v3.0F for RCA 5/11/2020
Changelog: v2.0F for RCA 4/1/2020
Changelog: v1.1FX 12/20/2019
Changelog: v1.0F Hotfix 10/31/2019
Changelog: v1.0F 10/29/2019
Changelog: v0.4 10/22/2019
Changelog: v0.3 10/2/2019
How does this even work!?
The amazing u/b0xspread has found a way to enforce modeswitching by watching the logs and processes, and continuing to enforce our desired mode long after the system wants to revert back. We're both expanding this scripting further to hopefully solve the same issues on the RGB and VGA forks -- but progress is slow due to the complex and varied nature of available resolution modes on those builds. But for now, let's just call this "black magic."
What Does That Look Like?
Here are some examples of games being played in beautiful 240p on CRT sets using the RCA Image!.
What is Different?
  • Retropie 4.6 (build 72132587 commit 05/07/20 Buster 10)
  • Retroarch 1.8.5
  • Full Apt-Upgrade for newest firmware and app dependancies (Recommended to repeat this function on your own Pi4)
  • 4GB (3872256 KB Uncompressed Image) (Compressed via WinRAR to 1043540KB)
  • SSH, Samba Share, and USB Rom Service enabled by default
  • Heavily modified Sakitoshi CRT-TVout script for switching between 480i and 240p
  • Further modified Sakitoshi script by u/b0xspread to allow video resolution switching on Pi4 Architecture
  • Optional overclock values in /boot/config.txt for Pi4 (disabled by default) [RECOMMENDED!]
  • NTSC @ 60hz 720/640x480 480i Resolution for Emulationstation & Kodi
  • PAL @ 50hz 720/640x576 576i Resolution for Emulationstation & Kodi
  • NTSC @ 60hz 640x480 Progressive (240 lines) for Retroarch
  • PAL @ 50hz 640x576 Progressive (288 lines) for Retroarch
  • Per-system custom refresh rates for Retroarch
  • Single-frame Run Ahead enabled for many 8-bit & 16-bit consoles and handhelds for Retroarch
  • Optional 480i mode for PSX and Arcade games
  • Preloaded with free 240p test suites for multiple consoles
  • Preloaded with additional stable (opt) Retroarch emulators
  • Preloaded with DOSBox and ScummVM
  • Preloaded with various 4:3 splashscreens from the RPiF download
  • Preloaded with 4:3 Ruckage's runcommand launching screens for supported systems
  • Custom 4:3 Arcade DOJ "Winners DO Use Drugs" splash screen.
  • Preloaded with MUNT Roland MT-32 MIDI emulation for DOSBox/ScummVM
  • Retroarch FCEUmm (NES) Emulator preconfigured for 4:3 horiz/vert overscan crop enabled w/ composite-direct-fbx pallete
  • Retroarch Picodrive (SMS/32X) Emulator preconfigured for 4:3 with 1X Sega Mastersystem & 1X Sega 32X resolution
  • Retroarch Gambatte (GB/GBC) emulator preset to Super Game Boy (Special 1 Pallete) mode with 2x integer scale SGB Overlay
  • Retroarch mGBA (GBA) emulator preset to Game Boy Player mode with 2x integer scale GBP Overlay
  • Other Retroarch handheld emulators preset for optimized wide display with overlay
  • Emulationstation preloaded with Ruckage's RetroPie menu icons
  • Emulationstation preloaded with Ruckage's snes-mini theme configured for 4:3
  • Custom ScummVM system artwork for snes-mini theme
  • Emulationstation systems ordered chronologically instead of alphabetically
  • Emulationstation preconfigured with best settings for analog A/V including best settings for video preview screensavers
What is Run-Ahead?
The Run Ahead feature calculates the frames as fast as possible in the background to "rollback" the action as close as possible to the input command requested.
I've enabled run-ahead on most of the 8 & 16-bit consoles and handhelds. A single frame (and using the second instance) is saved here, which dramatically improves input lag without affecting performance on a Pi3B+. More frames would require more hardware power, and may be achievable via overclocking.
lr-snes9x2010 consistent 60.0-60.2 FPS @ 60.098801hz lr-fceumm consistent 60.0-60.2 FPS @ 60.098801hz lr-beetle-pce-fast consistent 60.1-60.2 @ 60.000000hz lr-genesis-gx-plus consistent 59.9-60.2 FPS @ 59.922741hz (both genesis and sega cd) lr-picodrive consistent 59.9-60.2 FPS @ 59.922741hz (master system, game gear, and 32X) lr-gambatte consistent 60.0-60.2 FPS @ 60.098801hz (SGB2 framerate) lr-mgba consistent 59.8-60.4 FPS @ 60.002220hz (Gamecube framerate) 
Runahead Tested ~60FPS Stable:
  • Game Gear
  • Game Boy
  • Game Boy Color
  • Game Boy Advance
  • Master System
  • Megadrive
  • NES
  • PC Engine
  • PCE-CD
  • Sega 32X
  • Sega CD
  • SNES
Runahead Tested < 50FPS Unstable:
  • FB Neo
  • FB Alpha
  • Mame
  • N64
  • PlayStation
  • PSP
Runahead Untested:
  • Atari 800
  • Atari 2600
  • Atari 5200
  • Atari 7800
  • Atari Lynx
  • Coleco
  • Intellivision
  • MSX
What Does This NOT Have?
This doesn't have any ROMs (other than freeware test suites), BIOS files, music, screenshots, metadata, or videos concerning copywritten games. Other than the configurations and overlays, it has nothing that can't be downloaded through the repository or freeware.
Where Can I Get It?
You can download a premade image from Drive:
NOTE: Please expand your file system via Raspi-Config after your first boot, and reboot!
CRTPi4-RCA NTSC v3.4F: For Raspberry Pi4 Composite-Out @ 60hz
MD5: 7df8453c2e8029b06def7864351ec768 
CRTPi4-RCA PAL-D v3.4F: For Raspberry Pi4 Composite-Out @ 50hz
MD5: ab2bd6ab228bd6f58a22de15044fb46a 
How do I install the Arcade Configuration Pack?
These are the resolution-correct preset arcade configs for MAME/FBA including vertical games. There is roughly 38K files in there, spread out across several systems (arcade, fba, mame-libretro, and neogeo). Having these pre-installed would not allow either image to fit on the SD card used, and may not be needed for everyone. It's a fairly simple process that won't take more than a few minutes of your time.
  • Drop to shell or connect via SSH, and navigate to root (cd /)
  • Download the CRTPi-RCA_ArcadePack.zip with the command:
    sudo wget https://github.com/crtpi/CRTPi-Project/raw/masteCRTPi-RCA_ArcadePack.zip
  • Unzip and overwrite files with the command:
    sudo unzip -o -q CRTPi-RCA_ArcadePack.zip
  • Remove the zip with the command
    sudo rm CRTPi-RCA_ArcadePack.zip
  • Restore read/write access to the files you have overwritten with the command:
    sudo chmod a+rw -R /opt/retropie/configs/
How can I take full advantage of the 480i/240p Switching?
To force 480i for a system or game, you can create a '480i.txt' file inside the configuration folder of the system with a list of the file names (case insensitive, extension optional but recommended) you want to force.
If you wish to force 480i for a whole system, you can write "all" inside the '480i.txt' file.
Alternatively you can create a "240p.txt" file to force 480i to all games except for the ones inside the list.
You can read more about the script functionality here.
Example:
/opt/retropie/configs/psx/480i.txt containing "Bloody Roar 2.PBP" to force 480i for the file "Bloody Roar 2.PBP" /opt/retropie/configs/psx/480i.txt containing "all" to force 480i for all the PlayStation games. /opt/retropie/configs/ports/kodi/480i.txt containing "all" to force 480i on Kodi. 
I have X Issue! Help?
Why isn't there a Pi4 PAL version?
Try as I might, I have been unable to get a PAL signal out of the SDTV port on a Pi4. My BVM displays PAL-S and PAL-D fine, but neither will get anything but static. I don't even get a rolling B&W image, just horrible static. If you figure out a way, let me know!
I only have like 500mb of free space on my XXgb SD card!
You need to expand your file system via Raspi-Config. Follow these steps.
I want to switch back to lr-mupen64plus!
  • When launching an n64 game, mash buttons on the controller until the runcommand window comes up.
  • Select on "1 Set default emulator for n64" and choose "lr-mupen64plus"
  • Then "Q Exit (without launching)"
  • Launch the game again -- it will launch in the chosen emulator at the proper resolution
What A/V cable should I use for 3.5mm Composite?
I recommend the Zune A/V cable or XBOX 360E cable, you can find them on eBay and Amazon.
Samba Share won't work after I set up Wi-Fi!
Samba share service starts on boot, pending that a network is available. Configure your Wi-Fi then reboot first, and if that doesn't fix it then go into Retropie Setup > Configuration/Tools > Samba > Install Samba. Once it's complete, reboot and it should be golden.
USB-Romservice and/or Retropie-Mount don't work!
Follow this guide, but follow these steps before plugging in your thumb drive:
  • Go to Retropie-Setup
  • Update retropie install script
  • Go to Manage Packages -> Optional Packages
  • Scroll all the way down to usbromservice
  • Uninstall usbromservice
  • Install it again from Binary
  • Once finished, choose Configuration, then Enable USB Romservice
  • Reboot, and wait for it to fully boot in to ES
  • Plug in USB stick (has to be FAT32) and WAIT A LONG TIME (if your stick has a light, wait for it to stop flashing)
submitted by ErantyInt to crtgaming [link] [comments]

Invisible Object Culling In Quake Related Engines (REVISED)

Prologue
Despite all these great achievements in video cards development and the sworn assurances of developers about drawing 2 to 3 million polygons on screen without a significant FPS drop, it’s not all that rosy in reality. It depends on methods of rendering, on the number of involved textures and on the complexity and number of involved shaders. So even if all this really does ultimately lead to high performance, it only happens in the demos that developerss themselves kindly offer. In these demos, some "spherical dragons in vacuum" made of a good hundred thousand polygons are drawn very quickly indeed. However, the real ingame situation for some reason never looks like this funny dragon from a demo, and as a result many comrades abandon the development of their "Crysis killer" as soon as they can render a single room with a couple of light sources, because for some reason FPS in this room fluctuate around 40-60 even on their 8800GTS and upon creating second room it drops to a whopping 20. Of course with problems like this, it would be incorrect to say how things aren’t that bad and how the trouble of such developers are purely in their absence of correctly implemented culling, and how it is time for them to read this article. But for those who have already overcome “the first room syndrome" and tried to draw – inferior though, but, anyway - the world, this problem really is relevant.
However, it should be borne in mind that QUAKE, written in ancient times, was designed for levels of a “corridor" kind exclusively; therefore methods of clipping discussed in this article are not applicable to landscapes, such as ones from STALKER or Crysis, since completely different methods work there, whose analysis is beyond the scope of this article. Meanwhile we’ll talk about the classic corridor approach to mapping and the effective clipping of invisible surfaces, as well as clipping of entire objects.

The paper tree of baloon leaves

As you probably know, QUAKE uses BSP, Binary Spacing Partition tree. This is a space indexing algorithm, and BSP itself doesn’t care if the space is open or closed, it doesn’t even care if the map is sealed, it can be anything. BSP implies the division of a three-dimensional object into a certain number of secant planes called "the branches" or "the nodes" and volumetric areas or rooms called "the leaves". The names are confusing as you can see. In QUAKE / QUAKE2 the branches usually contain information about the surfaces that this branch contain, and the leaves are an empty space, not filled with nothing. Although sometimes leaves may contain water for example (in a form of a variable that indicates, specifically, that we’ve got water in this leaf). Also, the leaf contains a pointer to the data of potential visibility (Potentially Visible Set, PVS) and a list of all surfaces that are marked as being visible from this leaf. Actually the approach itself implies that we are able to draw our world however we prefer, either using leaves only or using branches only. This is especially noticeable in different versions of QUAKE: for example, in QUAKE1 in a leaf we just mark our surfaces as visible and then we also sequentially go through all the surfaces visible from a particular branch, assembling chains of surfaces to draw them later. But in QUAKE3, we can accumulate visible surfaces no sooner than we’ll get into the leaf itself.
In QUAKE and QUAKE2, all surfaces must lie on the node, which is why the BSP tree grows rather quickly, but in exchange this makes it possible to trace these surfaces by simply moving around the tree, not wasting time to check each surface separately, which affects the speed of the tracer positively. Because of this, unique surface is linked to each node (the original surface is divided into several if necessary) so in the nodes we always have what is known to be visible beforehand, and therefore we can perform a recursive search on the tree using the BBox pyramid of frustum as a direction of our movement along the BSP tree (SV_RecursiveWorldNode function).
In QUAKE3, the tree was simplified and it tries to avoid geometry cuts as much as possible (a BSP tree is not even obliged to cut geometry, such cuts are but a matter of optimality of such a tree). And surfaces in QUAKE3 do not lie on the node because patches and triangle models lie there instead. But what happens would they be put on the node nevertheless, you can see on the example of "The Edge Of Forever" map that I compiled recently for an experimental version of Xash. Turns out, in places that had a couple thousand visible nodes and leaves in the original, there are almost 170 thousand of them with a new tree. And this is the result after all the preliminary optimizations, otherwise it could have been even more, he-he. Yeah, so... For this reason, the tree in QUAKE3 does not put anything on the node and we certainly do need to get into the leaf, mark visible surfaces in it and add them to the rendering list. On the contrary, in QUAKE / QUAKE2 going deep down to the leaf itself is not necessary.
Invisible polygon cutoff (we are talking about world polys, separate game objects will be discussed a bit later) is based on two methods:
The first method is to use bit-vectors of visibility (so-called PVS - Potential Visible Set). The second method is regular frustum culling which actually got nothing to do with BSP but works just as efficiently, for a certain number of conditions of course. Bottom line: together these two methods provide almost perfect clipping of invisible polygons, drawing a very small visible piece out of the vast world. Let's take a closer look at PVS and how it works.

When FIDO users get drunk

Underlying idea of PVS is to expose the fact that one leaf is visible from another. For BSP alone it’s basically impossible because leaves from completely different branches can be visible at the same time and you will never find a way to identify the pattern for leafs from different branches seeing each other - it simply doesn’t exist. Therefore, the compiler has to puff for us, manually checking the visibility of all leaves from all leaves. Information about visibility in this case is scanty: one Boolean variable with possible values 0 and 1. 0 means that leaf is not visible and 1 means that leaf is visible. It is easy to guess that for each leaf there is a unique set of such Boolean variables the size of the total number of leaves on the map. So a set like this but for all the leaves will take an order of magnitude more space: the number of leaves multiplied by the number of leaves and multiplied by the size of our variable in which we will store information of visibility (0 \ 1).
And the number of leaves, as you can easily guess, is determined by map size map and by the compiler, which upon reaching a certain map size, cease to divide the world into leaves and treat resulting node as a leaf. Leaf size vary for different QUAKE. For example, in QUAKE1 leaves are very small. For example I can tell you that the compiler divide standard boxmap in QUAKE1 into as many as four leaves meanwhile in QUAKE3 similar boxmap takes only one leaf. But we digress.
Let's estimate the size of our future PVS file. Suppose we have an average map and it has a couple thousand leaves. Would we imagine that the information about the leaf visibility is stored in a variable of char type (1 byte) then the size of visdata for this level would be, no more no less, almost 4 megabytes. That is, much AF. Of course an average modern developer would shrug and pack the final result into zip archive but back in 1995 end users had modest machines, their memory was low and therefore visdata was packed in “more different” ways. The first step in optimizing is about storing data not in bytes, but in bits. It is easy to guess that such approach reduce final result as much as 8 times and what's typical AF – does it without any resource-intensive algorithms like Huffman trees. Although in exchange, such approach somewhat worsened code usability and readability. Why am I writing this? Due to many developers’ lack of understanding for conditions in code like this:
if ( pvs [ leafnum >> 3 ] & ( 1 << ( leafnum & 7 ) ) ) { } 
Actually, this condition implement simple, beautiful and elegant access to the desired bit in the array (as one can recall, addressing less than one byte is impossible and you can only work with them via bit operations)

Titans that keep the globe spinning

The visible part of the world is cut off in the same fashion: we find the current leaf where the player is located (in QUAKE this is implemented by the Mod_PointInLeaf function) then we get a pointer to visdata for the current leaf (for our convenience, it is linked directly to the leaf in the form of "compressed_vis" pointer) and then stupidly go through all the leaves and branches of the map and check them for being visible from our leaf (this can be seen in the R_MarkLeaves function). As long as some leaves turn out to be visible from the current leaf we assign them a unique number from "r_visframecount" sequence which increases by one every frame. Thus, we emphasize that this leaf is visible when we build the current frame. In the next frame, "r_framecount" is incremented by one and all the leaves are considered invisible again. As one can understand, this is much more convenient and much faster than revisiting all the leaves at the end of each frame and zeroing their "visible" variable. I drew attention to this feature because this mechanism also bothers some and they don’t understand how it works.
The R_RecursiveWorldNode function “walk” along leaves and branches marked this way. It cuts off obviously invisible leaves and accumulate a list of surfaces from visible ones. Of course the first check is done for the equivalence of r_visframecount and visframe for the node in question. Then the branch undergoes frustum pyramid check and if this check fails then we don’t climb further along this branch. Having stumbled upon a leaf, we mark all its surfaces visible the same way, assigning the current r_framecount value to the visframe variable (in the future this will help us to determine quickly whether a certain surface is visible in the current frame). Then, using a simple function, we determine which side we are from the plane of our branch (each branch has its own plane, literally called “plane” in the code) and, again, for now, we just take all surfaces linked to this branch and add them to the drawing chain (so-called “texturechain”), although nobody can actually stop us from drawing them immediately, right there, (in QUAKE1 source code one can see both options) having previously checked these surfaces for clipping with the frustum pyramid, or at least having made sure that the surface faces us.
In QUAKE, each surface has a special flag SURF_PLANEBACK which help us determine the orientation of the surface. But in QUAKE3 there is no such flag anymore, and clipping of invisible surfaces is not as efficient, sending twice as many surfaces for rendering. However, their total number after performing all the checks is not that great. However, whatever one may say, adding this check to Xash3D raised average FPS almost one and half times in comparison to original Half-Life. This is on the matter whether it is beneficial. But we digress.
So after chaining and drawing visible surfaces, we call R_RecursiveWorldNode again but now - for the second of two root branches of BSP tree. Just in case. Because the visible surfaces, too, may well be there. When the recursion ends, the result will either be a whole rendered world, or chains of visible surfaces at least. This is what can actually be sent for rendering with OpenGL or Direct3D, well, if we did not draw our world right in the R_RecursiveWorldNode function of course. Actually this method with minor upgrades successfully used in all three QUAKEs.

A naked man is in a wardrobe because he's waiting for a tram

One of the upgrades is utilization of the so-called areaportals. This is another optimization method coming straight out of QUAKE2. The point of using areaportals is about game logic being able to turn the visibility of an entire sectors on and off at its discretion. Technically, this is achieved as follows: the world is divided into zones similar to the usual partitioning along the BSP tree, however, there can’t be more than 256 of them (later I will explain why) and they are not connected in any way.
Regular visibility is determined just like in QUAKE; however, by installing a special “func_areaportal” entity we can force the compiler to split an area in two. This mechanism operates on approximately the same principle as the algorithm of searching for holes in the map, so you won’t deceive the compiler by putting func_areaportal in a bare field - the compiler will simply ignore it. Although if you make areaportal the size of the cross-section of this field (to the skybox in all directions) in spite of everything the zones will be divided. We can observe this technique in Half-Life 2 where an attempt to return to old places (with cheats for example) shows us disconnected areaportals and a brief transition through the void from one zone to another. Actually, this mechanism helped Half-Life 2 simulate large spaces successfully and still use BSP level structure (I have already said that BSP, its visibility check algorithm to be precise, is not very suitable for open spaces).
So installed areaportal forcibly breaks one zone into two, and the rest of the zoneization is at the discretion of the compiler, which at the same time makes sure not to exceed 256 zones limit, so their sizes can be completely different. Well, I repeat, it depends on the overall size of the map. Our areaportal is connected to some door dividing these two zones. When the door is closed - it turns areaportal off and the zones are separated from each other. Therefore, if the player is not in the cut off zone, then rendering it is not worth it. In QUAKE, we’d have to do a bunch of checks and it’s possible that we could only cut off a fraction of the number of polygons (after all, the door itself is not an obstacle for either visibility check, or even more so, nor it is for frustum). Compare to case in point: one command is issued - and the whole room is excluded from visibility. “Not bad,” you’d say, “but how would the renderer find out? After all, we performed all our operations on the server and the client does not know anything about it.” And here we go back to the question why there can’t be more than 256 zones.
The point is, information about all of zone visibility is, likewise, packaged in bit flags (like PVS) and transmitted to the client in a network message. Dividing 256 bits by 8 makes 32 bytes, which generally isn’t that much. In addition, the tail of this information can be cut off at ease if it contains zeroes only. Though the payback for such an optimization would appear as an extra byte that will have to be transmitted over the network to indicate the actual size of the message about the visibility of our zones. But, in general, this approach justified.

Light_environment traces enter from the back

Source Engine turned out to have a terrible bug which makes the whole areaportal thing nearly meaningless. Numerous problems arise because of it: water breaks down into segments that pop in, well, you should be familiar with all this by now. Areaportal cuts the geometry unpredictably, like an ordinary secant plane, but its whole point is being predictable! Whereas areaportal brushes in Source Engine have absolutely no priority in splitting the map. It should be like this: first, the tree is cut the regular way. And when no suitable planes left, the final secant plane of areaportal is used. This is the only way to cut the sectors correctly.

Modern problems

The second optimization method, as I said, is increased size of the final leaf akin to QUAKE3. It is believed that a video card would draw a certain amount of polygons much faster than the CPU would check whether they are visible. This come from the very concept of visibility check: if visibility check takes longer than direct rendering, then well, to hell with this check. The controversy of this approach is determined by a wide range of video cards present at the hands of the end users, and it is strongly determined by the surging fashion for laptops and netbooks in which a video card is a very conditional and very weak concept (don’t even consider its claimed Shader Model 3 support). Therefore, for desktop gaming machines it would be more efficient to draw more at a time, but for weak video cards of laptops traditional culling will remain more reliable. Even if it is such a simple culling as I described earlier.

Decompression sickness simulator

Although I should also mention the principles of frustum culling, perhaps they are incomprehensible to some. Cutoff by frustum pyramid is actually pure mathematics without any compiler calculations. From the current direction of the player’s gaze, a clipping pyramid is built (the tip of the pyramid – in case someone can’t understand - is oriented towards the player’s point of view and its base is oriented in the direction of player’s view). The angle between the walls of the pyramid can be sharp or blunt - as you probably guessed already, it depends on the player's FOV. In addition, the player can forcefully pull the far wall of the pyramid closer to himself (yes, this is the notorious “MaxRange” parameter in the “worldspawn” menu of the map editor). Of course, OpenGL also builds a similar pyramid for its internal needs when it takes information from the projection matrix but we’re talking local pyramid now. The finished pyramid consists of 4-6 planes (QUAKE uses only 4 planes and trusts OpenGL to independently cut far and near polygons, but if you write your own renderer and intend to support mirrors and portals you will definitely need all six planes). Well, the frustum test itself is an elementary check for a presence of AA-box (AABB, Axis Aligned Bounding Box) in the frustum pyramid. Or speaking more correctly, this is a check for their intersection. Let me remind you that each branch has its own dimensions (a fragment of secant plane bound by neighboring perpendicular secant planes) which are checked for intersection. But unfortunately the frustum test has one fundamental drawback - it cannot cut what is directly in the player’s view. We can adjust the cutoff distance, we can even make that “ear feint” like they do in QFusion where final zFar value is calculated in each frame before rendering and then taken into account in entity clipping, but after all, whatever they say, the value itself was obtained from PVS-information. Therefore, neither of two methods can replace the other but they just complement each other. This should be remembered.

I gotta lay off the pills I'm taking

It seems that we figured out the rendering of the world and now we are moving on smoothly to cutting off moving objects... which are all the visible objects in the world! Even ones that, at te first glance, stand still and aren’t planning to move anywhere. Cause the player moves! From one point he still sees a certain static object, and from another point, of course, he no longer does. This detail should also be considered.
Actually, at the beginning of this article I already spoke in detail about an algorithm of objects’ visibility check: first we find the visible leaf for the player, then we find the visible leaf for the entity and then we check by visdata whether they see each other. I, too, would like to clarify (if someone suddenly does not understand) how each moving entity is given the number of its current visible leaf, i.e. directly for entity’s its own current position, and the leaves themselves are of course static and always in the same place.

Ostrich is such an OP problem solver

So the method described above has two potential problems:
The first problem is that even if A equals B, then, oddly enough, B is far from being always equal A. In other words, entity A can see entity B, but this does not mean that entity B see entity A, and, no, it’s not about one of them “looking” away. So why is this happening? Most often for two reasons:
The first reason is that one of the entities’ ORIGIN sit tight inside the wall and the Mod_PointInLeaf function for it points to the outer “zero” leaf from which EVERYTHING is visible (haven’t any of you ever flown around the map?). Meanwhile, no leaf inside the map can see outer leaf - these two features actually explain an interesting fact of an entire world geometry becoming visible and on the contrary, all objects disappearing when you fly outside the map. In regular mode, similar problems can occur for objects attached to the wall or recessed into the wall. For example, sometimes the sounds of a pressed button or opening door disappear because its current position went beyond the world borders. This phenomenon is fought by interchanging objects A and B or by obtaining alternative points for the position of an object, but all the same, it’s all not very reliable.

But lawyer said that you don't exist

In addition, as I said, there is another problem. It come from the fact that not every entity fits a single leaf. Only the player is so small that he can always be found in one leaf only (well, in the most extreme case - in two leaves on the border of water and air. This phenomenon is fought with various hacks btw), but some giant hentacle or on the contrary, an elevator made as a door entity, can easily occupy 30-40 leaves at a time. An attempt to check one leaf (for example, one where the center of the model is) will inevitably lead to a deplorable result: as soon as the center of an object will be out of the player’s visibility range, the entire object will disappear completely. The most common case is the notorious func_door used as an elevator. There is one in QUAKE on the E1M1. Observe: it travels halfway and then its ORIGIN is outside the map and therefore it must disappear from the player’s field of view. However, it does not go anywhere, right? Let us see in greater detail how this is done.
The simplest idea that comes to one’s mind: since the object occupies several leaves, we have to save them all somewhere in the structure of an object in the code and check them one by one. If at least one of these leaves is visible, then the whole object is visible (for example, it’s very tip). This is exactly what was implemented in QUAKE: a static array for 16 leaves and a simple recursive function SV_FindTouchedLeafs that looks for all the leaves in range hardcoded in "pev->absmins" and "pev->absmax" variables (pev i.e. a Pointer to EntVars_t table). absmins and absmax are recalculated each time SV_LinkEdict (or its more specific case of UTIL_SetOrigin) is called. Hence the quite logical conclusion that a simple change of ORIGIN without recalculating its visible leaf will take the object out of visibility sooner or later even if, surprisingly enough, it’s right in front of the player and the player should technically still be able to see it. Inb4 why one have to call UTIL_SetOrigin and wouldn’t it be easier to just assign new value to the "pev->origin" vector without calling this function. It wouldn’t.
With this method we can solve both former problems perfectly: we can fight the loss of visibility if the object's ORIGIN went beyond the world borders and level the difference of visibility for A->B versus visibility for B->A.

A secret life of monster_tripmine

Actually we’ve yet to encounter another problem, but it does not occur immediately. Remember, we’ve got an array of 16 leaves. But what if it won’t be enough? Thank God there are no beams in QUAKE and no very long elevators made as func_door either. For this exact reason. Because when the array is filled to capacity, the SV_FindTouchedLeafs function just stop and we can only hope that there won’t be that many cases when an object disappear right before our eyes. But in the original QUAKE, such cases may well be. In Half-Life, the situation is even worse - as you can remember there are rays that can reach for half the map, tripmine rays for example. In this case, a situation may occur when we see just the very tip of the ray. For most of these rays, 16 leaves are clearly not enough. Valve tried to remedy the situation by increasing the array to 48 leaves. That helped. On early maps. If you remember, at the very beginning of the game when the player has already got off the trailer, he enters that epic elevator that takes him down. The elevator is made as a door entity and it occupies 48 leaves exactly. Apparently, the final expansion of the array was based after its dimensions. Then the programmers realized that this isn’t really a solution, because no matter how much one would expand the array, it can still be lacking for something. So then they screwed up an alternative method for visibility check: a head branch (headnode) check. In short, this is still the same SV_FindTouchedLeafs but now it is called directly from the place of visibility check and with a subsequent transfer of visdata in there. In general, it is not used very often because it is slower than checking pre-accumulated leaves, that is, it is intended just for such non-standard cases like this one.
Well, and since, I hope, general picture of the clipping mechanism already beginning to take shape in your mind, I will finish the article in just a few words.
On the server, all objects that have already passed the visibility check are added to the network message containing information about visible objects. Thus, on the client, the list of visible entities is already cut off by PVS and we do not have to do this again and therefore a simple frustum check is enough. You ask, "why did we have to cut off invisible objects on the server when we could do this later when we are on the client already?" I reply: yes, we could, but now the objects cut off on the server didn’t get into the network message and saved us some traffic. And since the player still does not see them, what is the point of transferring them to the client just to check them for visibility after? This is a kind of double optimizing :)
© Uncle Mike 2012
submitted by crystallize1 to hammer [link] [comments]

Income From Home With 60 Second Binary Options Binary Options Trading Home Business Live trading with Bollinger Band & RSI  IQ Option  Options Trading Plans What is binary options! The 60 Second Cash App Scam - Does 60 Second Cash App Work ... Vince Stanzione Trades Binary Options on Binary com

The 60 Second binary option strategy is a trading algorithm or a set of rules allowing binary options traders to make profitable decisions on the very squeezed period of trading. Thee system is based on 1-minute charts, and it applies to any kind of asset class including single shares, stock indices, commodities, fiat currency pairs and even Australia binary options 60 second binary options does it work best, Videos tagged sharebuilder binary options. El bitcoin va como un tiro. El pasado jueves 11 de mayo su tipo de cambio superaba por primera vez los 1.600 euros. Llegó a los 1.685 cuando. May 9, 2017 If you want to feel the adrenaline you should try 60 Second Binary Options. The 60 seconds starts the second you place the trade. So if you place a trade at 9:45:15 AM, your binary option expires at 9:46:15 AM, 60 seconds later. Figure 1. 60 Second Binary Options. Source: EasyXP. Figure 1 shows a screenshot of some 60 second binary options. The payout is 67% in this case, and the Target Price is the current price. How To Trade 60 Second Binary Options Like A Professional! In an era of fast paced communication, where time is the only asset we are no longer able to gain, we employ best forex trading course in singapore the most modern property how to trade 60 second binary options like a professional marketing. Does it work when there is a special directional movement?. 1) Online binary trading is safe: in the past binary options brokers could operate even without a regular license, because binary options trading was not regulated by any body or authority.In those days the scams were therefore greater; but for years now, the European Union has expressed its opinion on the legality of binary options: all binary options brokers must have a regular license in

[index] [26204] [6675] [23822] [8327] [23103] [27163] [14375] [3906] [10971] [21112]

Income From Home With 60 Second Binary Options Binary Options Trading Home Business

Hi viewers, In today's video we will be doing live trading on 60 seconds binary options trading on IQ Option platform. Trading was done with the help of following indicators: 1. Income From Home With 60 Second Binary Options Binary Options Trading Home Business ... different windows of time work for different people. If options trading is a "hobby" or a second profession ... My Sundays Otc Trades With 30 Second Options ... Free Option Signals For Binary Trading - Duration: ... It just didn't work" British GQ - Duration: 1:42:14. The 60 Second Cash App Scam - Does 60 Second Cash App Work? See An Alternative Strategy Here. http://thegermanbankersecret.com/Free I can't believe I just sa... how binary options work, how does binary options work, redwood binary options withdrawal, ... top 5 binary options strategies, binary options 60 second trading strategy, https://www.youtube.com ...

Flag Counter