New beginner challenges
-
- Posts: 5
- Joined: Mon Feb 20, 2017 3:25 am
- My devices: IPad mini, Windows laptop
- Flag:
New beginner challenges
Hello. My first question. I am 67 and would like to try to learn programming. Smart Basic suits me. I hope this page is relevant for my question. As an experiment I will try for a simple flight simulator. Cockpit with scenery rotating behind windscreen. I tried cockpit as main graphics window with scenery as a Sprite through windscreen. However the document states sprites are placed 'above' the main graphic window and I need that Sprite to be 'below' as if through windscreen (then scenery can be rotated etc). Am I attempting this the wrong way ? Thankyou.
- Mr. Kibernetik
- Site Admin
- Posts: 4786
- Joined: Mon Nov 19, 2012 10:16 pm
- My devices: iPhone, iPad, MacBook
- Location: Russia
- Flag:
Re: New beginner challenges
This means that your windscreen needs to be a sprite to have something "below" it.
-
- Posts: 5
- Joined: Mon Feb 20, 2017 3:25 am
- My devices: IPad mini, Windows laptop
- Flag:
Re: New beginner challenges
Thankyou for helping with my question re sprites. I am starting to understand. Meanwhile my Smart Basic editing screen has gone black with green font. At the bottom of that screen is a slider which seems to scale the text. I can't put the screen colour back to the default text or the blue screen. Can you advise me why the screen has turned black with a green font please?
Also when I 'begin' and 'end' a new Sprite e.g. Draw a line, I can't make it visible even with 'show Sprite'. If I simply draw the line it appears immediately.
Any help is much appreciated while I am learning the beginning commands.
Thankyou.
Also when I 'begin' and 'end' a new Sprite e.g. Draw a line, I can't make it visible even with 'show Sprite'. If I simply draw the line it appears immediately.
Any help is much appreciated while I am learning the beginning commands.
Thankyou.
- Mr. Kibernetik
- Site Admin
- Posts: 4786
- Joined: Mon Nov 19, 2012 10:16 pm
- My devices: iPhone, iPad, MacBook
- Location: Russia
- Flag:
Re: New beginner challenges
Please check samples in "Examples > Editor Settings" folder.Zimboguitar wrote: ↑Mon Feb 20, 2017 2:28 pmThankyou for helping with my question re sprites. I am starting to understand. Meanwhile my Smart Basic editing screen has gone black with green font. At the bottom of that screen is a slider which seems to scale the text. I can't put the screen colour back to the default text or the blue screen. Can you advise me why the screen has turned black with a green font please?
Also when I 'begin' and 'end' a new Sprite e.g. Draw a line, I can't make it visible even with 'show Sprite'. If I simply draw the line it appears immediately.
Any help is much appreciated while I am learning the beginning commands.
Thankyou.
- Dutchman
- Posts: 851
- Joined: Mon May 06, 2013 9:21 am
- My devices: iMac, iPad Air, iPhone
- Location: Netherlands
- Flag:
Re: New beginner challenges
The recent post viewtopic.php?f=20&t=1779 gives another exampleMr. Kibernetik wrote: ↑Mon Feb 20, 2017 3:16 pmPlease check samples in "Examples > Editor Settings" folder.
Last edited by Dutchman on Fri Jan 20, 2023 12:12 pm, edited 1 time in total.
-
- Posts: 5
- Joined: Mon Feb 20, 2017 3:25 am
- My devices: IPad mini, Windows laptop
- Flag:
Re: New beginner challenges
Thankyou for helping with the Editor settings which has solved my problem (I like the black screen with green font - it reminds me of old computers in the eighties.) I still can't get to see my sprites (they are invisible, even with 'show Sprite') so I am going to try a different project. Artificial Intelligence music composing ! Looking at the examples I can understand them, but I don't see any formulae being used. Is it possible to manipulate 'note set' with formulae please?
-
- Posts: 5
- Joined: Mon Feb 20, 2017 3:25 am
- My devices: IPad mini, Windows laptop
- Flag:
Re: New beginner challenges
My question re using formulae to manipulate 'note set' data has brought no response. I need this functionality to explore 'artificial intelligence music composing'. Formulae seems only to work with numeral data - not alphabetical as in music note Names. None of the music examples show note manipulation by formulae. Would it be possible therefore to make a table of note name letters to numbers which will work with the 'note set' command. If this is not possible then sadly, I am attempting the wrong language.
- rbytes
- Posts: 1338
- Joined: Sun May 31, 2015 12:11 am
- My devices: iPhone 11 Pro Max
iPad Pro 11
MacBook
Dell Inspiron laptop
CHUWI Plus 10 convertible Windows/Android tablet - Location: Calgary, Canada
- Flag:
- Contact:
Re: New beginner challenges
If you look in Examples/Music and Sound/, you will see a file call Synthesizer.txt. Examining the code will answer most of your questions. Smart Basic supports MIDI, which is a mathematical way of defining and playing various instruments at different pitches, timings and volumes, using the sound chip in your iOS device. But if you are just getting started with smart Basic, you will not suddenly find yourself able to implement all of this information. You will need to start off slowly by coding a few lines, running the code and listening to the results. Then you can start to build on that knowledge.
When you are in the code editor, you can press the ? Button on the top toolbar and see the built-in manual. Two sections will be of interest. The MUSIC section contains two types of commands, those that contain the word MUSIC and those that contain the word NOTES. It is the second type - NOTES - that you will need to explore, in order to learn to generate sounds from within your device. The music commands are also useful, but they do not generate original sounds. They simply play back prerecorded audio files. The next section of the manual is called INSTRUMENTS. It lists all of the musical instruments available for use with NOTES commands. Following the list of instruments, there is a list of the pitches that are available for notes.
There are a few other programs that have been posted on this forum over the past few years that deal with music synthesis. Let me know if you are interested in checking them out.
When you are in the code editor, you can press the ? Button on the top toolbar and see the built-in manual. Two sections will be of interest. The MUSIC section contains two types of commands, those that contain the word MUSIC and those that contain the word NOTES. It is the second type - NOTES - that you will need to explore, in order to learn to generate sounds from within your device. The music commands are also useful, but they do not generate original sounds. They simply play back prerecorded audio files. The next section of the manual is called INSTRUMENTS. It lists all of the musical instruments available for use with NOTES commands. Following the list of instruments, there is a list of the pitches that are available for notes.
There are a few other programs that have been posted on this forum over the past few years that deal with music synthesis. Let me know if you are interested in checking them out.
The only thing that gets me down is gravity...
-
- Posts: 5
- Joined: Mon Feb 20, 2017 3:25 am
- My devices: IPad mini, Windows laptop
- Flag:
Re: New beginner challenges
Hi, and thanks so much for coming to my rescue with Smart Basic in particular the subject of music. I will certainly look closely at the references you mentioned. I use an IPad mini as my Apple device and use Garage Band which is an astonishingly well written piece of software. I see Smart Basic as an extension of the Ipad and hope to be able to explore original software to allow music composition by computer.
Since my last letter my step grandson (18 and studying programming) has pointed out that my need to convert the musical notes etc, A to G and other symbols can all be done using Arrays which will convert them to numberical values allowing formula to be applied. I will let you know my progress. Thanks again.
Since my last letter my step grandson (18 and studying programming) has pointed out that my need to convert the musical notes etc, A to G and other symbols can all be done using Arrays which will convert them to numberical values allowing formula to be applied. I will let you know my progress. Thanks again.
- rbytes
- Posts: 1338
- Joined: Sun May 31, 2015 12:11 am
- My devices: iPhone 11 Pro Max
iPad Pro 11
MacBook
Dell Inspiron laptop
CHUWI Plus 10 convertible Windows/Android tablet - Location: Calgary, Canada
- Flag:
- Contact:
Re: New beginner challenges
I enjoy Garage Band, too, and have quite a few other good music apps. For a lot of fun, check out VidRhythm. You and your friends/family can have endless fun with it. (No, I have no personal connection!)
Your grandson is correct - you can turn any number into a MIDI pitch, rest, duration, tempo, etc. by using arrays to convert it as needed to any letter/number combination. Good luck!
Your grandson is correct - you can turn any number into a MIDI pitch, rest, duration, tempo, etc. by using arrays to convert it as needed to any letter/number combination. Good luck!
The only thing that gets me down is gravity...